man-pages/man1/elfedit.1.html
2021-03-31 01:06:50 +01:00

207 lines
7.2 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of ELFEDIT</TITLE>
</HEAD><BODY>
<H1>ELFEDIT</H1>
Section: GNU Development Tools (1)<BR>Updated: 2021-01-21<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
elfedit - update ELF header and program property of ELF files
<A NAME="lbAC">&nbsp;</A>
<H2>SYNOPSIS</H2>
elfedit [<B>--input-mach=</B><I>machine</I>]
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[<B>--input-type=</B><I>type</I>]
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[<B>--input-osabi=</B><I>osabi</I>]
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>--output-mach=</B><I>machine</I>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>--output-type=</B><I>type</I>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>--output-osabi=</B><I>osabi</I>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>--enable-x86-feature=</B><I>feature</I>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>--disable-x86-feature=</B><I>feature</I>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[<B>-v</B>|<B>--version</B>]
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[<B>-h</B>|<B>--help</B>]
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<I>elffile</I>...
<A NAME="lbAD">&nbsp;</A>
<H2>DESCRIPTION</H2>
<B>elfedit</B> updates the <FONT SIZE="-1">ELF</FONT> header and program property of <FONT SIZE="-1">ELF</FONT>
files which have the matching <FONT SIZE="-1">ELF</FONT> machine and file types. The options
control how and which fields in the <FONT SIZE="-1">ELF</FONT> header and program property
should be updated.
<P>
<I>elffile</I>... are the <FONT SIZE="-1">ELF</FONT> files to be updated. 32-bit and
64-bit <FONT SIZE="-1">ELF</FONT> files are supported, as are archives containing <FONT SIZE="-1">ELF</FONT> files.
<A NAME="lbAE">&nbsp;</A>
<H2>OPTIONS</H2>
The long and short forms of options, shown here as alternatives, are
equivalent. At least one of the <B>--output-mach</B>,
<B>--output-type</B>, <B>--output-osabi</B>,
<B>--enable-x86-feature</B> and <B>--disable-x86-feature</B>
options must be given.
<DL COMPACT>
<DT id="1"><B>--input-mach=</B><I>machine</I><DD>
Set the matching input <FONT SIZE="-1">ELF</FONT> machine type to <I>machine</I>. If
<B>--input-mach</B> isn't specified, it will match any <FONT SIZE="-1">ELF</FONT>
machine types.
<P>
The supported <FONT SIZE="-1">ELF</FONT> machine types are, <I>i386</I>, <I></I><FONT SIZE="-1"><I>IAMCU</I></FONT><I></I>, <I>L1OM</I>,
<I>K1OM</I> and <I>x86-64</I>.
<DT id="2"><B>--output-mach=</B><I>machine</I><DD>
Change the <FONT SIZE="-1">ELF</FONT> machine type in the <FONT SIZE="-1">ELF</FONT> header to <I>machine</I>. The
supported <FONT SIZE="-1">ELF</FONT> machine types are the same as <B>--input-mach</B>.
<DT id="3"><B>--input-type=</B><I>type</I><DD>
Set the matching input <FONT SIZE="-1">ELF</FONT> file type to <I>type</I>. If
<B>--input-type</B> isn't specified, it will match any <FONT SIZE="-1">ELF</FONT> file types.
<P>
The supported <FONT SIZE="-1">ELF</FONT> file types are, <I>rel</I>, <I>exec</I> and <I>dyn</I>.
<DT id="4"><B>--output-type=</B><I>type</I><DD>
Change the <FONT SIZE="-1">ELF</FONT> file type in the <FONT SIZE="-1">ELF</FONT> header to <I>type</I>. The
supported <FONT SIZE="-1">ELF</FONT> types are the same as <B>--input-type</B>.
<DT id="5"><B>--input-osabi=</B><I>osabi</I><DD>
Set the matching input <FONT SIZE="-1">ELF</FONT> file <FONT SIZE="-1">OSABI</FONT> to <I>osabi</I>. If
<B>--input-osabi</B> isn't specified, it will match any <FONT SIZE="-1">ELF</FONT> OSABIs.
<P>
The supported <FONT SIZE="-1">ELF</FONT> OSABIs are, <I>none</I>, <I></I><FONT SIZE="-1"><I>HPUX</I></FONT><I></I>, <I>NetBSD</I>,
<I></I><FONT SIZE="-1"><I>GNU</I></FONT><I></I>, <I>Linux</I> (alias for <I></I><FONT SIZE="-1"><I>GNU</I></FONT><I></I>),
<I>Solaris</I>, <I></I><FONT SIZE="-1"><I>AIX</I></FONT><I></I>, <I>Irix</I>,
<I>FreeBSD</I>, <I></I><FONT SIZE="-1"><I>TRU64</I></FONT><I></I>, <I>Modesto</I>, <I>OpenBSD</I>, <I>OpenVMS</I>,
<I></I><FONT SIZE="-1"><I>NSK</I></FONT><I></I>, <I></I><FONT SIZE="-1"><I>AROS</I></FONT><I></I> and <I>FenixOS</I>.
<DT id="6"><B>--output-osabi=</B><I>osabi</I><DD>
Change the <FONT SIZE="-1">ELF OSABI</FONT> in the <FONT SIZE="-1">ELF</FONT> header to <I>osabi</I>. The
supported <FONT SIZE="-1">ELF OSABI</FONT> are the same as <B>--input-osabi</B>.
<DT id="7"><B>--enable-x86-feature=</B><I>feature</I><DD>
Set the <I>feature</I> bit in program property in <I>exec</I> or <I>dyn</I>
<FONT SIZE="-1">ELF</FONT> files with machine types of <I>i386</I> or <I>x86-64</I>. The
supported features are, <I>ibt</I> and <I>shstk</I>.
<DT id="8"><B>--disable-x86-feature=</B><I>feature</I><DD>
Clear the <I>feature</I> bit in program property in <I>exec</I> or
<I>dyn</I> <FONT SIZE="-1">ELF</FONT> files with machine types of <I>i386</I> or <I>x86-64</I>.
The supported features are the same as <B>--enable-x86-feature</B>.
<P>
Note: <B>--enable-x86-feature</B> and <B>--disable-x86-feature</B>
are available only on hosts with <B>mmap</B> support.
<DT id="9"><B>-v</B><DD>
<DT id="10"><B>--version</B><DD>
Display the version number of <B>elfedit</B>.
<DT id="11"><B>-h</B><DD>
<DT id="12"><B>--help</B><DD>
Display the command-line options understood by <B>elfedit</B>.
<DT id="13"><B>@</B><I>file</I><DD>
Read command-line options from <I>file</I>. The options read are
inserted in place of the original @<I>file</I> option. If <I>file</I>
does not exist, or cannot be read, then the option will be treated
literally, and not removed.
<P>
Options in <I>file</I> are separated by whitespace. A whitespace
character may be included in an option by surrounding the entire
option in either single or double quotes. Any character (including a
backslash) may be included by prefixing the character to be included
with a backslash. The <I>file</I> may itself contain additional
@<I>file</I> options; any such options will be processed recursively.
</DL>
<A NAME="lbAF">&nbsp;</A>
<H2>SEE ALSO</H2>
<B><A HREF="/cgi-bin/man/man2html?1+readelf">readelf</A></B>(1), and the Info entries for <I>binutils</I>.
<A NAME="lbAG">&nbsp;</A>
<H2>COPYRIGHT</H2>
Copyright (c) 1991-2020 Free Software Foundation, Inc.
<P>
Permission is granted to copy, distribute and/or modify this document
under the terms of the <FONT SIZE="-1">GNU</FONT> Free Documentation License, Version 1.3
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
section entitled ``<FONT SIZE="-1">GNU</FONT> Free Documentation License''.
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="14"><A HREF="#lbAB">NAME</A><DD>
<DT id="15"><A HREF="#lbAC">SYNOPSIS</A><DD>
<DT id="16"><A HREF="#lbAD">DESCRIPTION</A><DD>
<DT id="17"><A HREF="#lbAE">OPTIONS</A><DD>
<DT id="18"><A HREF="#lbAF">SEE ALSO</A><DD>
<DT id="19"><A HREF="#lbAG">COPYRIGHT</A><DD>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 00:05:11 GMT, March 31, 2021
</BODY>
</HTML>