xref: /onnv-gate/usr/src/cmd/sgs/elfedit/modules/common/ehdr.msg (revision 5088:26c540f30cd3)
1*5088Sab196087#
2*5088Sab196087# CDDL HEADER START
3*5088Sab196087#
4*5088Sab196087# The contents of this file are subject to the terms of the
5*5088Sab196087# Common Development and Distribution License (the "License").
6*5088Sab196087# You may not use this file except in compliance with the License.
7*5088Sab196087#
8*5088Sab196087# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*5088Sab196087# or http://www.opensolaris.org/os/licensing.
10*5088Sab196087# See the License for the specific language governing permissions
11*5088Sab196087# and limitations under the License.
12*5088Sab196087#
13*5088Sab196087# When distributing Covered Code, include this CDDL HEADER in each
14*5088Sab196087# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*5088Sab196087# If applicable, add the following below this CDDL HEADER, with the
16*5088Sab196087# fields enclosed by brackets "[]" replaced with your own identifying
17*5088Sab196087# information: Portions Copyright [yyyy] [name of copyright owner]
18*5088Sab196087#
19*5088Sab196087# CDDL HEADER END
20*5088Sab196087#
21*5088Sab196087
22*5088Sab196087#
23*5088Sab196087# Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
24*5088Sab196087# Use is subject to license terms.
25*5088Sab196087#
26*5088Sab196087# ident	"%Z%%M%	%I%	%E% SMI"
27*5088Sab196087
28*5088Sab196087@ _START_
29*5088Sab196087
30*5088Sab196087# Message file for elfedit 'ehdr' module
31*5088Sab196087
32*5088Sab196087@ MSG_ID_ELFEDIT_EHDR
33*5088Sab196087
34*5088Sab196087
35*5088Sab196087# Debug messages
36*5088Sab196087@ MSG_DEBUG_E_S_OK	"ehdr.%s: value unchanged: %s\n"
37*5088Sab196087@ MSG_DEBUG_E_S_CHG	"ehdr.%s: change from %s to %s\n"
38*5088Sab196087@ MSG_DEBUG_E_D_OK	"ehdr.%s: value unchanged: %d\n"
39*5088Sab196087@ MSG_DEBUG_E_D_CHG	"ehdr.%s: change from %d to %d\n"
40*5088Sab196087@ MSG_DEBUG_E_LLX_OK	"ehdr.%s: value unchanged: %#llx\n"
41*5088Sab196087@ MSG_DEBUG_E_LLX_CHG	"ehdr.%s: change from %#llx to %#llx\n"
42*5088Sab196087@ MSG_DEBUG_EI_S_S_OK	"ehdr.e_ident[%s]: value unchanged: %s\n";
43*5088Sab196087@ MSG_DEBUG_EI_S_S_CHG	"ehdr.e_ident[%s]: change from %s to %s\n"
44*5088Sab196087@ MSG_DEBUG_EI_S_X_OK	"ehdr.e_ident[%s]: value unchanged: %#x\n";
45*5088Sab196087@ MSG_DEBUG_EI_S_X_CHG	"ehdr.e_ident[%s]: change from %#x to %#x\n"
46*5088Sab196087@ MSG_DEBUG_EI_D_X_OK	"ehdr.e_ident[%d]: value unchanged: %#x\n"
47*5088Sab196087@ MSG_DEBUG_EI_D_X_CHG	"ehdr.e_ident[%d]: change from %#x to %#x\n"
48*5088Sab196087@ MSG_DEBUG_SHDR0_D_OK	"shdr[0].%s: value unchanged: %d\n"
49*5088Sab196087@ MSG_DEBUG_SHDR0_D_CHG	"shdr[0].%s: change from %d to %d\n"
50*5088Sab196087@ MSG_DEBUG_NOTSTRTAB	"ehdr.%s: ELF warning: section is not a \
51*5088Sab196087			 string table: %d\n"
52*5088Sab196087
53*5088Sab196087
54*5088Sab196087# Module description
55*5088Sab196087
56*5088Sab196087@ MSG_MOD_DESC		"ELF Header"
57*5088Sab196087
58*5088Sab196087
59*5088Sab196087# 1-line description strings
60*5088Sab196087
61*5088Sab196087@ MSG_DESC_DUMP			"Dump ELF Header"
62*5088Sab196087@ MSG_DESC_E_IDENT		"ELF Identification"
63*5088Sab196087@ MSG_DESC_E_TYPE		"Object File Type"
64*5088Sab196087@ MSG_DESC_E_MACHINE		"Machine Architecture"
65*5088Sab196087@ MSG_DESC_E_VERSION		"Object File Version"
66*5088Sab196087@ MSG_DESC_E_ENTRY		"Starting Virtual Address"
67*5088Sab196087@ MSG_DESC_E_PHOFF		"Program Header Table File Offset"
68*5088Sab196087@ MSG_DESC_E_SHOFF		"Section Header Table File Offset"
69*5088Sab196087@ MSG_DESC_E_FLAGS		"Processor-Specific Flags"
70*5088Sab196087@ MSG_DESC_E_EHSIZE		"ELF Header's Size"
71*5088Sab196087@ MSG_DESC_E_PHENTSIZE		"Program Header Table Entry Size"
72*5088Sab196087@ MSG_DESC_E_PHNUM		"Number Program Header Entries"
73*5088Sab196087@ MSG_DESC_E_SHENTSIZE		"Section Header Table Entry Size"
74*5088Sab196087@ MSG_DESC_E_SHNUM		"Number Section Header Entries"
75*5088Sab196087@ MSG_DESC_E_SHSTRNDX		"Section Name String Table Index"
76*5088Sab196087
77*5088Sab196087@ MSG_DESC_EI_MAG0		"File Identification Byte #1"
78*5088Sab196087@ MSG_DESC_EI_MAG1		"File Identification Byte #2"
79*5088Sab196087@ MSG_DESC_EI_MAG2		"File Identification Byte #3"
80*5088Sab196087@ MSG_DESC_EI_MAG3		"File Identification Byte #4"
81*5088Sab196087@ MSG_DESC_EI_CLASS		"File Class (System Word Size)"
82*5088Sab196087@ MSG_DESC_EI_DATA		"Data Encoding (Byte Order)"
83*5088Sab196087@ MSG_DESC_EI_VERSION		"File Version"
84*5088Sab196087@ MSG_DESC_EI_OSABI		"Operating System / ABI Identification"
85*5088Sab196087@ MSG_DESC_EI_ABIVERSION	"ABI version"
86*5088Sab196087
87*5088Sab196087# Command option description strings
88*5088Sab196087
89*5088Sab196087@ MSG_OPTDESC_SHNDX	"\
90*5088Sab196087   Interpret the sec argument as a section index rather than\n\
91*5088Sab196087   as a section name. section can be one of the well known SHN_\n\
92*5088Sab196087   symbolic constants, or any integer.\n"
93*5088Sab196087
94*5088Sab196087@ MSG_OPTDESC_SHTYP	"\
95*5088Sab196087   Interpret the sec argument as a section type rather than\n\
96*5088Sab196087   as a section name. section can be one of the well known SHT_\n\
97*5088Sab196087   symbolic constants, or any integer.\n"
98*5088Sab196087
99*5088Sab196087# Command argument description strings
100*5088Sab196087
101*5088Sab196087@ MSG_ARGDESC_E_IDENT_NDX	"\
102*5088Sab196087   Index of element of e_ident[] array. This can be\n\
103*5088Sab196087   an integer value, or any of the EI_ symbolic constants\n\
104*5088Sab196087   defined in /usr/include/sys/elf.h.\n"
105*5088Sab196087
106*5088Sab196087@ MSG_ARGDESC_E_IDENT_VALUE	"\
107*5088Sab196087   New value for element of e_ident[] array. This can be\n\
108*5088Sab196087   an integer value, or any symbolic constants defined in\n\
109*5088Sab196087   /usr/include/sys/elf.h that apply to the selected item.\n"
110*5088Sab196087
111*5088Sab196087@ MSG_ARGDESC_E_TYPE_VALUE	"\
112*5088Sab196087   New value for type of the ELF object. This can be\n\
113*5088Sab196087   an integer value, or any of the ET_ symbolic constants\n\
114*5088Sab196087   defined in /usr/include/sys/elf.h.\n"
115*5088Sab196087
116*5088Sab196087@ MSG_ARGDESC_E_MACHINE_VALUE	"\
117*5088Sab196087   New value for architecture of the ELF object. This can be\n\
118*5088Sab196087   an integer value, or any of the EM_ symbolic constants\n\
119*5088Sab196087   defined in /usr/include/sys/elf.h.\n"
120*5088Sab196087
121*5088Sab196087@ MSG_ARGDESC_E_VERSION_VALUE	"\
122*5088Sab196087   New value for version of the ELF object. This can be\n\
123*5088Sab196087   an integer value, or any of the EV_ symbolic constants\n\
124*5088Sab196087   defined in /usr/include/sys/elf.h.\n"
125*5088Sab196087
126*5088Sab196087@ MSG_ARGDESC_E_ENTRY_VALUE	"\
127*5088Sab196087   New value for virtual address to which the system first transfers control.\n"
128*5088Sab196087
129*5088Sab196087@ MSG_ARGDESC_E_PHOFF_VALUE	"\
130*5088Sab196087   New value for program header table's file offset.\n"
131*5088Sab196087
132*5088Sab196087@ MSG_ARGDESC_E_SHOFF_VALUE	"\
133*5088Sab196087   New value for section header table's file offset.\n"
134*5088Sab196087
135*5088Sab196087@ MSG_ARGDESC_E_FLAGS_VALUE	"\
136*5088Sab196087   New value for processor-specific flags. This can be an integer\n\
137*5088Sab196087   value, or any of the EF_ symbolic constants defined in the\n\
138*5088Sab196087   system header files\n"
139*5088Sab196087
140*5088Sab196087@ MSG_ARGDESC_E_EHSIZE_VALUE	"\
141*5088Sab196087   New value for size of ELF header, in bytes.\n"
142*5088Sab196087
143*5088Sab196087@ MSG_ARGDESC_E_PHENTSIZE_VALUE	"\
144*5088Sab196087   New value for size of one entry in the file's program header table,\n\
145*5088Sab196087   in bytes.\n"
146*5088Sab196087
147*5088Sab196087@ MSG_ARGDESC_E_PHNUM_VALUE	"\
148*5088Sab196087   New value for number of entries in the program header table.\n"
149*5088Sab196087
150*5088Sab196087@ MSG_ARGDESC_E_SHENTSIZE_VALUE	"\
151*5088Sab196087   New value for size of one entry in the file's section header table,\n\
152*5088Sab196087   in bytes.\n"
153*5088Sab196087
154*5088Sab196087@ MSG_ARGDESC_E_SHNUM_VALUE	"\
155*5088Sab196087   New value for number of entries in the section header table.\n"
156*5088Sab196087
157*5088Sab196087@ MSG_ARGDESC_E_SHSTRNDX_SEC	"\
158*5088Sab196087   String table section containing section name strings.\n\
159*5088Sab196087   By default, this argument is interpreted as the name\n\
160*5088Sab196087   of the desired section. The section index of the first\n\
161*5088Sab196087   section with the specified name is used.\n\
162*5088Sab196087   \n\
163*5088Sab196087   If -shndx is set, then sec is a section index, and is\n\
164*5088Sab196087   interpreted as an integer, or one of the well known SHN_\n\
165*5088Sab196087   symbolic constant names.\n\
166*5088Sab196087   \n\
167*5088Sab196087   If -shtyp is set, then sec is a section type, and is\n\
168*5088Sab196087   interpreted as an integer, or one of the well known SHT_\n\
169*5088Sab196087   symbolic constant names. The section index of the first\n\
170*5088Sab196087   section with the specified type is used.\n"
171*5088Sab196087
172*5088Sab196087@ MSG_ARGDESC_EI_MAG0_VALUE	"\
173*5088Sab196087   New value for first byte of file magic number.\n"
174*5088Sab196087
175*5088Sab196087@ MSG_ARGDESC_EI_MAG1_VALUE	"\
176*5088Sab196087   New value for second byte of file magic number.\n"
177*5088Sab196087
178*5088Sab196087@ MSG_ARGDESC_EI_MAG2_VALUE	"\
179*5088Sab196087   New value for third byte of file magic number.\n"
180*5088Sab196087
181*5088Sab196087@ MSG_ARGDESC_EI_MAG3_VALUE	"\
182*5088Sab196087   New value for fourth byte of file magic number.\n"
183*5088Sab196087
184*5088Sab196087@ MSG_ARGDESC_EI_CLASS_VALUE	"\
185*5088Sab196087   New value for file's class. This can be an integer value, or any of\n\
186*5088Sab196087   the ELFCLASS symbolic constants defined in /usr/include/sys/elf.h.\n"
187*5088Sab196087
188*5088Sab196087@ MSG_ARGDESC_EI_DATA_VALUE	"\
189*5088Sab196087   New value for file's data encoding. This can be an integer\n\
190*5088Sab196087   value, or any ELFDATA symbolic constants defined in\n\
191*5088Sab196087   /usr/include/sys/elf.h.\n"
192*5088Sab196087
193*5088Sab196087# Note: EI_VERSION uses the same string as E_VERSION, above
194*5088Sab196087
195*5088Sab196087@ MSG_ARGDESC_EI_OSABI_VALUE	"\
196*5088Sab196087   New value for ABI identification of the ELF object. This can be\n\
197*5088Sab196087   an integer value, or any of the ELFOSABI_ symbolic constants\n\
198*5088Sab196087   defined in /usr/include/sys/elf.h.\n"
199*5088Sab196087
200*5088Sab196087@ MSG_ARGDESC_EI_ABIVERSION_VALUE	"\
201*5088Sab196087   New value for version of the ABI to which the object is targeted.\n"
202*5088Sab196087
203*5088Sab196087
204*5088Sab196087# Help strings
205*5088Sab196087
206*5088Sab196087@ MSG_HELP_DUMP	"   \
207*5088Sab196087   The ehdr:dump command is used to display the contents of\n\
208*5088Sab196087   the ELF header using the same style used by the elfdump program.\n"
209*5088Sab196087
210*5088Sab196087@ MSG_HELP_E_IDENT	"   \
211*5088Sab196087   Examine or modify ELF Identification information for the\n\
212*5088Sab196087   object. This information is found in the e_ident array in\n\
213*5088Sab196087   the ELF header.\n\
214*5088Sab196087   \n\
215*5088Sab196087   If ehdr:e_ident is called without any argument, all values\n\
216*5088Sab196087   the value in e_ident are shown. If called with the index\n\
217*5088Sab196087   argument, the selected element of e_ident is shown. If also\n\
218*5088Sab196087   called with the value argument, the selected e_ident element\n\
219*5088Sab196087   is updated with the new value.\n"
220*5088Sab196087
221*5088Sab196087
222*5088Sab196087@ MSG_HELP_E_TYPE	"   \
223*5088Sab196087   Examine or modify the object file type. This information is\n\
224*5088Sab196087   found in the e_type field of the ELF header.\n\
225*5088Sab196087   \n\
226*5088Sab196087   If ehdr:e_type is called without an argument, the value of\n\
227*5088Sab196087   e_type is shown. If called with the value argument, the\n\
228*5088Sab196087   e_type field is updated with the new value.\n\
229*5088Sab196087   \n\
230*5088Sab196087   Note: Changing the type code of an object does not change the\n\
231*5088Sab196087   other contents of the file, and is unlikely to produce a usable\n\
232*5088Sab196087   ELF object.\n"
233*5088Sab196087
234*5088Sab196087
235*5088Sab196087@ MSG_HELP_E_MACHINE	"   \
236*5088Sab196087   Examine or modify the required architecture of the object.\n\
237*5088Sab196087   This information is found in the e_machine field of the\n\
238*5088Sab196087   ELF header.\n\
239*5088Sab196087   \n\
240*5088Sab196087   If ehdr:e_machine is called without an argument, the value of\n\
241*5088Sab196087   e_machine is shown. If called with the value argument, the\n\
242*5088Sab196087   e_machine field is updated with the new value.\n\
243*5088Sab196087   \n\
244*5088Sab196087   Note: Changing the architecture code of an object does not change the\n\
245*5088Sab196087   other contents of the file, and is unlikely to produce a usable\n\
246*5088Sab196087   ELF object.\n"
247*5088Sab196087
248*5088Sab196087
249*5088Sab196087@ MSG_HELP_E_VERSION	"   \
250*5088Sab196087   Examine or modify the object file version. This information\n\
251*5088Sab196087   is found in the e_version field of the ELF header.\n\
252*5088Sab196087   \n\
253*5088Sab196087   If ehdr:e_version is called without an argument, the value of\n\
254*5088Sab196087   e_version is shown. If called with the value argument, the\n\
255*5088Sab196087   e_version field is updated with the new value.\n\
256*5088Sab196087   \n\
257*5088Sab196087   Note: The e_ident[EI_VERSION] element of the ELF header\n\
258*5088Sab196087   identification array also contains a version value. These\n\
259*5088Sab196087   two fields should be set to the same value. Use the\n\
260*5088Sab196087   ehdr:ei_version command to change that element.\n"
261*5088Sab196087
262*5088Sab196087
263*5088Sab196087@ MSG_HELP_E_ENTRY	"   \
264*5088Sab196087   Examine or modify the virtual address to which the system\n\
265*5088Sab196087   first transfers control, thus starting the process. This\n\
266*5088Sab196087   information is found in the e_entry field of the ELF header.\n\
267*5088Sab196087   If the file has no associated entry point, this member\n\
268*5088Sab196087   holds zero.\n\
269*5088Sab196087   \n\
270*5088Sab196087   If ehdr:e_entry is called without an argument, the value of\n\
271*5088Sab196087   e_entry is shown. If called with the value argument, the\n\
272*5088Sab196087   e_entry field is updated with the new value.\n\
273*5088Sab196087   \n\
274*5088Sab196087   Note: The entry point of an object is highly system\n\
275*5088Sab196087   dependent. Changing it is likely to produce an object that\n\
276*5088Sab196087   does not run properly.\n"
277*5088Sab196087
278*5088Sab196087
279*5088Sab196087@ MSG_HELP_E_PHOFF	"   \
280*5088Sab196087   Examine or modify the program header table's file offset.\n\
281*5088Sab196087   This information is found in the e_phoff field of the\n\
282*5088Sab196087   ELF header. If the file has no program header table, this\n\
283*5088Sab196087   member holds zero.\n\
284*5088Sab196087   \n\
285*5088Sab196087   If ehdr:e_phoff is called without an argument, the value of\n\
286*5088Sab196087   e_phoff is shown. If called with the value argument, the\n\
287*5088Sab196087   e_phoff field is updated with the new value.\n\
288*5088Sab196087   \n\
289*5088Sab196087   Note: Changing the e_phoff field of an object does not change\n\
290*5088Sab196087   the actual layout of the file or move the program header table.\n\
291*5088Sab196087   As such, changing this value is likely to produce an unusable\n\
292*5088Sab196087   ELF object.\n"
293*5088Sab196087
294*5088Sab196087
295*5088Sab196087@ MSG_HELP_E_SHOFF	"   \
296*5088Sab196087   Examine or modify the section header table's file offset.\n\
297*5088Sab196087   This information is found in the e_shoff field of the\n\
298*5088Sab196087   ELF header. If the file has no section header table, this\n\
299*5088Sab196087   member holds zero.\n\
300*5088Sab196087   \n\
301*5088Sab196087   If ehdr:e_shoff is called without an argument, the value of\n\
302*5088Sab196087   e_shoff is shown. If called with the value argument, the\n\
303*5088Sab196087   e_shoff field is updated with the new value.\n\
304*5088Sab196087   \n\
305*5088Sab196087   Note: Changing the e_shoff field of an object does not change\n\
306*5088Sab196087   the actual layout of the file or move the section header table.\n\
307*5088Sab196087   As such, changing this value is likely to produce an unusable\n\
308*5088Sab196087   ELF object.\n"
309*5088Sab196087
310*5088Sab196087
311*5088Sab196087@ MSG_HELP_E_FLAGS	"   \
312*5088Sab196087   Examine or modify the processor specific flags associated\n\
313*5088Sab196087   with the file. This information is found in the e_flags\n\
314*5088Sab196087   field of the ELF header.\n\
315*5088Sab196087   \n\
316*5088Sab196087   If ehdr:e_flags is called without an argument, the value of\n\
317*5088Sab196087   e_flags is shown. If called with one or more flag_value\n\
318*5088Sab196087   arguments, the the following steps are taken:\n\
319*5088Sab196087   \n   \
320*5088Sab196087   o\tAll the flag_value arguments are OR'd together.\n\
321*5088Sab196087   \n   \
322*5088Sab196087   o\tIf the -cmp option has been specified, the new value\n\
323*5088Sab196087   \tis complemented.\n\
324*5088Sab196087   \n   \
325*5088Sab196087   o\tThe e_flags field of the ELF header is updated with\n\
326*5088Sab196087   \tthe new value. If -and is specified, the new value is\n\
327*5088Sab196087   \tAND'd against the existing value. If -or is specified,\n\
328*5088Sab196087   \tthe new value is OR'd against the existing value. If\n\
329*5088Sab196087   \tneither -and or -or are specified, the new value replaces\n\
330*5088Sab196087   \tthe existing value.\n\
331*5088Sab196087   \n\
332*5088Sab196087   Note: Changing the e_flags field of an object does not change\n\
333*5088Sab196087   the code contained in the file. Setting a flag that implies\n\
334*5088Sab196087   an ability the existing code cannot support will produce an\n\
335*5088Sab196087   unusable ELF object.\n"
336*5088Sab196087
337*5088Sab196087
338*5088Sab196087@ MSG_HELP_E_EHSIZE	"   \
339*5088Sab196087   Examine or modify the size of the ELF header. This information\n\
340*5088Sab196087   is found in the e_ehsize field of the ELF header.\n\
341*5088Sab196087   \n\
342*5088Sab196087   If ehdr:e_ehsize is called without an argument, the value of\n\
343*5088Sab196087   e_ehsize is shown. If called with the value argument, the\n\
344*5088Sab196087   e_ehsize field is updated with the new value.\n\
345*5088Sab196087   \n\
346*5088Sab196087   Note: Changing the e_ehsize field of the ELF header does not\n\
347*5088Sab196087   change the size of the actual ELF header data structure. Setting\n\
348*5088Sab196087   it to a different value is likely to produce an unusable ELF object.\n"
349*5088Sab196087
350*5088Sab196087
351*5088Sab196087@ MSG_HELP_E_PHENTSIZE	"   \
352*5088Sab196087   Examine or modify the size of one entry in the file's program\n\
353*5088Sab196087   header table. This information is found in the e_phentsize\n\
354*5088Sab196087   field of the ELF header.\n\
355*5088Sab196087   \n\
356*5088Sab196087   If ehdr:e_phentsize is called without an argument, the value of\n\
357*5088Sab196087   e_phentsize is shown. If called with the value argument, the\n\
358*5088Sab196087   e_phentsize field is updated with the new value.\n\
359*5088Sab196087   \n\
360*5088Sab196087   Note: Changing the e_phentsize field of the ELF header does\n\
361*5088Sab196087   not change the size of the actual program header array elements.\n\
362*5088Sab196087   Setting it to a different value is likely to produce an unusable\n\
363*5088Sab196087   ELF object.\n"
364*5088Sab196087
365*5088Sab196087
366*5088Sab196087@ MSG_HELP_E_PHNUM	"   \
367*5088Sab196087   Examine or modify the number of entries in the program header\n\
368*5088Sab196087   table. This information is found in the e_phnum field of the\n\
369*5088Sab196087   ELF header, or in the sh_link field of the first section header\n\
370*5088Sab196087   in the case of extended program indexes.\n\
371*5088Sab196087   \n\
372*5088Sab196087   If the number of program headers is greater than or equal\n\
373*5088Sab196087   to PN_XNUM (0xffff), e_phnum has the value PN_XNUM, and the\n\
374*5088Sab196087   actual number of program header table entries is contained\n\
375*5088Sab196087   in the sh_info field of the section header at index 0.\n\
376*5088Sab196087   \n\
377*5088Sab196087   If ehdr:e_phnum is called without an argument, the number\n\
378*5088Sab196087   of program headers is shown. If called with the value argument,\n\
379*5088Sab196087   the number is updated with the new value.\n\
380*5088Sab196087   \n\
381*5088Sab196087   Note: Changing e_phnum and/or the sh_link field of the first\n\
382*5088Sab196087   section header  does not change the size of the actual program\n\
383*5088Sab196087   header array in the file.\n"
384*5088Sab196087
385*5088Sab196087
386*5088Sab196087@ MSG_HELP_E_SHENTSIZE	"   \
387*5088Sab196087   Examine or modify the size of one entry in the file's section\n\
388*5088Sab196087   header table. This information is found in the e_shentsize\n\
389*5088Sab196087   field of the ELF header.\n\
390*5088Sab196087   \n\
391*5088Sab196087   If ehdr:e_shentsize is called without an argument, the value of\n\
392*5088Sab196087   e_shentsize is shown. If called with the value argument, the\n\
393*5088Sab196087   e_shentsize field is updated with the new value.\n\
394*5088Sab196087   \n\
395*5088Sab196087   Note: Changing the e_shentsize field of the ELF header does\n\
396*5088Sab196087   not change the size of the actual section header array elements.\n\
397*5088Sab196087   Setting it to a different value is likely to produce an unusable\n\
398*5088Sab196087   ELF object.\n"
399*5088Sab196087
400*5088Sab196087
401*5088Sab196087@ MSG_HELP_E_SHNUM	"   \
402*5088Sab196087   Examine or modify the number of entries in the section header\n\
403*5088Sab196087   table. This information is found in the e_shnum field of the\n\
404*5088Sab196087   ELF header, or in the sh_size field of the first section header\n\
405*5088Sab196087   in the case of extended section indexes.\n\
406*5088Sab196087   \n\
407*5088Sab196087   If the number of sections is greater than or equal to\n\
408*5088Sab196087   SHN_LORESERVE (0xff00), e_shnum has the value zero, and\n\
409*5088Sab196087   the actual number of section header table entries is\n\
410*5088Sab196087   contained in the sh_size field of the section header\n\
411*5088Sab196087   at index 0.\n\
412*5088Sab196087   \n\
413*5088Sab196087   If ehdr:e_shnum is called without an argument, the number of\n\
414*5088Sab196087   sections is shown. If called with the value argument, the\n\
415*5088Sab196087   number of sections is updated with the new value.\n\
416*5088Sab196087   \n\
417*5088Sab196087   Note: Changing e_shnum and/or the sh_size field of the first\n\
418*5088Sab196087   section header does not change the size of the actual section\n\
419*5088Sab196087   header array in the file.\n"
420*5088Sab196087
421*5088Sab196087
422*5088Sab196087@ MSG_HELP_E_SHSTRNDX	"   \
423*5088Sab196087   Examine or modify the section table index of the entry that is\n\
424*5088Sab196087   associated with the section name string table. This information\n\
425*5088Sab196087   is found in the e_shstrndx field of the ELF header, or in the\n\
426*5088Sab196087   sh_link field of the first section header in the case of\n\
427*5088Sab196087   extended section indexes. If the file has no section name\n\
428*5088Sab196087   string table, this member holds the value SHN_UNDEF.\n\
429*5088Sab196087   \n\
430*5088Sab196087   If the section name string table section index is greater\n\
431*5088Sab196087   than or equal to SHN_LORESERVE (0xff00), e_shstrndx has the\n\
432*5088Sab196087   value SHN_XINDEX (0xffff) and   the actual index of the section\n\
433*5088Sab196087   name string table section is contained in the sh_link field of\n\
434*5088Sab196087   the section header at index 0.\n\
435*5088Sab196087   \n\
436*5088Sab196087   If ehdr:e_shstrndx is called without an argument, the index of\n\
437*5088Sab196087   the section name string table is shown. If called with the value\n\
438*5088Sab196087   argument, the ELF header is updated with the new value.\n\
439*5088Sab196087   \n\
440*5088Sab196087   Note: The e_shstrndx field of the ELF header must reference\n\
441*5088Sab196087   a string table section. Otherwise, diagnostic tools will be\n\
442*5088Sab196087   confused by the resulting object.\n"
443*5088Sab196087
444*5088Sab196087
445*5088Sab196087@ MSG_HELP_EI_MAG0	"   \
446*5088Sab196087   Examine or modify the first byte of the object's \"magic number\".\n\
447*5088Sab196087   The magic number is the first 4 bytes of the object file, and is\n\
448*5088Sab196087   used to identify it as being an ELF object. This information\n\
449*5088Sab196087   is found in the e_ident[EI_MAG0] field of the ELF header.\n\
450*5088Sab196087   \n\
451*5088Sab196087   If ehdr:ei_mag0 is called without an argument, the value of\n\
452*5088Sab196087   e_ident[EI_MAG0] is shown. If called with the value argument,\n\
453*5088Sab196087   the e_ident[EI_MAG0] field is updated with the new value.\n\
454*5088Sab196087   \n\
455*5088Sab196087   Note: Changing the e_ident[EI_MAG0] field of the ELF header\n\
456*5088Sab196087   to a value other than 0x7f will cause the system to fail to\n\
457*5088Sab196087   identify it as an ELF object.\n"
458*5088Sab196087
459*5088Sab196087
460*5088Sab196087@ MSG_HELP_EI_MAG1	"   \
461*5088Sab196087   Examine or modify the second byte of the object's \"magic number\".\n\
462*5088Sab196087   The magic number is the first 4 bytes of the object file, and is\n\
463*5088Sab196087   used to identify it as being an ELF object. This information\n\
464*5088Sab196087   is found in the e_ident[EI_MAG1] field of the ELF header.\n\
465*5088Sab196087   \n\
466*5088Sab196087   If ehdr:ei_mag1 is called without an argument, the value of\n\
467*5088Sab196087   e_ident[EI_MAG1] is shown. If called with the value argument,\n\
468*5088Sab196087   the e_ident[EI_MAG1] field is updated with the new value.\n\
469*5088Sab196087   \n\
470*5088Sab196087   Note: Changing the e_ident[EI_MAG1] field of the ELF header\n\
471*5088Sab196087   to a value other than 0x45 ('E') will cause the system to\n\
472*5088Sab196087   fail to identify it as an ELF object.\n"
473*5088Sab196087
474*5088Sab196087
475*5088Sab196087@ MSG_HELP_EI_MAG2	"   \
476*5088Sab196087   Examine or modify the third byte of the object's \"magic number\".\n\
477*5088Sab196087   The magic number is the first 4 bytes of the object file, and is\n\
478*5088Sab196087   used to identify it as being an ELF object. This information\n\
479*5088Sab196087   is found in the e_ident[EI_MAG2] field of the ELF header.\n\
480*5088Sab196087   \n\
481*5088Sab196087   If ehdr:ei_mag2 is called without an argument, the value of\n\
482*5088Sab196087   e_ident[EI_MAG2] is shown. If called with the value argument,\n\
483*5088Sab196087   the e_ident[EI_MAG2] field is updated with the new value.\n\
484*5088Sab196087   \n\
485*5088Sab196087   Note: Changing the e_ident[EI_MAG2] field of the ELF header\n\
486*5088Sab196087   to a value other than 0x4c ('L') will cause the system to\n\
487*5088Sab196087   fail to identify it as an ELF object.\n"
488*5088Sab196087
489*5088Sab196087
490*5088Sab196087@ MSG_HELP_EI_MAG3	"   \
491*5088Sab196087   Examine or modify the fourth byte of the object's \"magic number\".\n\
492*5088Sab196087   The magic number is the first 4 bytes of the object file, and is\n\
493*5088Sab196087   used to identify it as being an ELF object. This information\n\
494*5088Sab196087   is found in the e_ident[EI_MAG3] field of the ELF header.\n\
495*5088Sab196087   \n\
496*5088Sab196087   If ehdr:ei_mag3 is called without an argument, the value of\n\
497*5088Sab196087   e_ident[EI_MAG3] is shown. If called with the value argument,\n\
498*5088Sab196087   e_ident[EI_MAG3] field is updated with the new value.\n\
499*5088Sab196087   \n\
500*5088Sab196087   Note: Changing the e_ident[EI_MAG3] field of the ELF header\n\
501*5088Sab196087   to a value other than 0x46 ('F') will cause the system to\n\
502*5088Sab196087   fail to identify it as an ELF object.\n"
503*5088Sab196087
504*5088Sab196087
505*5088Sab196087@ MSG_HELP_EI_CLASS	"   \
506*5088Sab196087   Examine or modify the file's class (system word size). This\n\
507*5088Sab196087   information is found in the e_ident[EI_CLASS] field of the\n\
508*5088Sab196087   ELF header.\n\
509*5088Sab196087   \n\
510*5088Sab196087   If ehdr:ei_class is called without an argument, the value of\n\
511*5088Sab196087   e_ident[EI_CLASS] is shown. If called with the value argument,\n\
512*5088Sab196087   the e_ident[EI_CLASS] field is updated with the new value.\n\
513*5088Sab196087   \n\
514*5088Sab196087   Note: Changing the e_ident[EI_CLASS] field of the ELF header\n\
515*5088Sab196087   does not alter the contents of the file, and is therefore\n\
516*5088Sab196087   likely to render the file unusable.\n"
517*5088Sab196087
518*5088Sab196087@ MSG_HELP_EI_DATA	"   \
519*5088Sab196087   Examine or modify the file's data encoding (byte order). This\n\
520*5088Sab196087   information is found in the e_ident[EI_DATA] field of the\n\
521*5088Sab196087   ELF header.\n\
522*5088Sab196087   \n\
523*5088Sab196087   If ehdr:ei_data is called without an argument, the value of\n\
524*5088Sab196087   e_ident[EI_DATA] is shown. If called with the value argument,\n\
525*5088Sab196087   the e_ident[EI_DATA] field is updated with the new value.\n\
526*5088Sab196087   \n\
527*5088Sab196087   Note: Changing the e_ident[EI_DATA] field of the ELF header\n\
528*5088Sab196087   does not alter the contents of the file or the byte order\n\
529*5088Sab196087   of the data, and is therefore likely to render the file unusable.\n"
530*5088Sab196087
531*5088Sab196087
532*5088Sab196087@ MSG_HELP_EI_VERSION	"   \
533*5088Sab196087   Examine or modify the object file version. This information\n\
534*5088Sab196087   is found in the e_ident[EI_VERSION] field of the ELF header.\n\
535*5088Sab196087   \n\
536*5088Sab196087   If ehdr:ei_version is called without an argument, the value\n\
537*5088Sab196087   of e_ident[EI_VERSION]  is shown. If called with the value\n\
538*5088Sab196087   argument, the e_ident[EI_VERSION] field is updated with the\n\
539*5088Sab196087   new value.\n\
540*5088Sab196087   \n\
541*5088Sab196087   Note: The e_version element of the ELF header also contains\n\
542*5088Sab196087   a version value. These two fields should be set to the same\n\
543*5088Sab196087   value. Use the ehdr:e_version command to change that element.\n"
544*5088Sab196087
545*5088Sab196087
546*5088Sab196087@ MSG_HELP_EI_OSABI	"   \
547*5088Sab196087   Examine or modify the operating system / ABI identification for\n\
548*5088Sab196087   the object. This information is kept in the e_ident[EI_OSABI]\n\
549*5088Sab196087   field of the ELF header.\n\
550*5088Sab196087   \n\
551*5088Sab196087   If ehdr:ei_osabi is called without arguments, current value of\n\
552*5088Sab196087   e_ident[EI_OSABI] is shown. If called with the value argument,\n\
553*5088Sab196087   the e_ident[EI_OSABI] field is updated with the new value.\n\
554*5088Sab196087   \n\
555*5088Sab196087   Note: Changing the e_ident[EI_OSABI] field of the ELF header\n\
556*5088Sab196087   does not alter the contents of the file, or cause the actual\n\
557*5088Sab196087   ABI to be altered. Setting an incompatible ABI value is likely\n\
558*5088Sab196087   to cause the object to become unusable.\n"
559*5088Sab196087
560*5088Sab196087
561*5088Sab196087@ MSG_HELP_EI_ABIVERSION	"   \
562*5088Sab196087   Examine or modify the ABI version for the object. This\n\
563*5088Sab196087   information is kept in the e_ident[EI_ABIVERSION] field of\n\
564*5088Sab196087   the ELF header.\n\
565*5088Sab196087   \n\
566*5088Sab196087   If ehdr:ei_abiversion is called without arguments, the current\n\
567*5088Sab196087   value of e_ident[EI_ABIVERSION] is shown. If called with the\n\
568*5088Sab196087   value argument, the e_ident[EI_ABIVERSION] field is updated with\n\
569*5088Sab196087   the new value.\n\
570*5088Sab196087   \n\
571*5088Sab196087   Note: The meaning of the e_ident[EI_ABIVERSION] field of\n\
572*5088Sab196087   the ELF header depends on the value of e_ident[EI_OSABI]\n\
573*5088Sab196087   (See ehdr:ei_osabi).\n"
574*5088Sab196087
575*5088Sab196087
576*5088Sab196087@ _END_
577*5088Sab196087
578*5088Sab196087
579*5088Sab196087
580*5088Sab196087# Strings
581*5088Sab196087
582*5088Sab196087@ MSG_STR_EMPTY		""
583*5088Sab196087@ MSG_STR_NL		"\n"
584*5088Sab196087@ MSG_STR_VALUE		"value"
585*5088Sab196087@ MSG_STR_EIDENT_HDR	"e_ident:\n"
586*5088Sab196087@ MSG_STR_INDEX		"index"
587*5088Sab196087@ MSG_STR_SEC		"sec"
588*5088Sab196087@ MSG_STR_TYPE		"type"
589*5088Sab196087@ MSG_STR_VERSION	"version"
590*5088Sab196087@ MSG_STR_OFFSET	"offset"
591*5088Sab196087@ MSG_STR_FLAGVALUE	"flag_value"
592*5088Sab196087@ MSG_STR_MINUS_SHNDX	"-shndx"
593*5088Sab196087@ MSG_STR_MINUS_SHTYP	"-shtyp"
594*5088Sab196087@ MSG_STR_SH_INFO	"sh_info"
595*5088Sab196087@ MSG_STR_SH_LINK	"sh_link"
596*5088Sab196087@ MSG_STR_SH_SIZE	"sh_size"
597*5088Sab196087
598*5088Sab196087
599*5088Sab196087# Format strings
600*5088Sab196087@ MSG_FMT_BKTSTR	"[%s]"
601*5088Sab196087@ MSG_FMT_BKTINT	"[%d]"
602*5088Sab196087@ MSG_FMT_STRNL		"%s\n"
603*5088Sab196087@ MSG_FMT_WORDVAL	"%u"
604*5088Sab196087@ MSG_FMT_DECNUMNL	"%d\n"
605*5088Sab196087@ MSG_FMT_HEXNUM	"%#x"
606*5088Sab196087@ MSG_FMT_HEXNUMNL	"%#x\n"
607*5088Sab196087@ MSG_FMT_HEXNUM_QCHR	"%#x ('%c')"
608*5088Sab196087@ MSG_FMT_EI_ELT	"    %-18s%s\n"
609*5088Sab196087
610*5088Sab196087
611*5088Sab196087
612*5088Sab196087
613*5088Sab196087# The following strings represent reserved words, files, pathnames and symbols.
614*5088Sab196087# Reference to this strings is via the MSG_ORIG() macro, and thus no message
615*5088Sab196087# translation is required.
616*5088Sab196087
617*5088Sab196087
618*5088Sab196087# Module name
619*5088Sab196087
620*5088Sab196087@ MSG_MOD_NAME		"ehdr"
621*5088Sab196087
622*5088Sab196087
623*5088Sab196087# Command names
624*5088Sab196087
625*5088Sab196087@ MSG_CMD_DUMP		"dump"
626*5088Sab196087
627*5088Sab196087@ MSG_CMD_E_IDENT	"e_ident"
628*5088Sab196087@ MSG_CMD_E_TYPE	"e_type"
629*5088Sab196087@ MSG_CMD_E_MACHINE	"e_machine"
630*5088Sab196087@ MSG_CMD_E_VERSION	"e_version"
631*5088Sab196087@ MSG_CMD_E_ENTRY	"e_entry"
632*5088Sab196087@ MSG_CMD_E_PHOFF	"e_phoff"
633*5088Sab196087@ MSG_CMD_E_SHOFF	"e_shoff"
634*5088Sab196087@ MSG_CMD_E_FLAGS	"e_flags"
635*5088Sab196087@ MSG_CMD_E_EHSIZE	"e_ehsize"
636*5088Sab196087@ MSG_CMD_E_PHENTSIZE	"e_phentsize"
637*5088Sab196087@ MSG_CMD_E_PHNUM	"e_phnum"
638*5088Sab196087@ MSG_CMD_E_SHENTSIZE	"e_shentsize"
639*5088Sab196087@ MSG_CMD_E_SHNUM	"e_shnum"
640*5088Sab196087@ MSG_CMD_E_SHSTRNDX	"e_shstrndx"
641*5088Sab196087
642*5088Sab196087@ MSG_CMD_EI_MAG0	"ei_mag0"
643*5088Sab196087@ MSG_CMD_EI_MAG1	"ei_mag1"
644*5088Sab196087@ MSG_CMD_EI_MAG2	"ei_mag2"
645*5088Sab196087@ MSG_CMD_EI_MAG3	"ei_mag3"
646*5088Sab196087@ MSG_CMD_EI_CLASS	"ei_class"
647*5088Sab196087@ MSG_CMD_EI_DATA	"ei_data"
648*5088Sab196087@ MSG_CMD_EI_VERSION	"ei_version"
649*5088Sab196087@ MSG_CMD_EI_OSABI	"ei_osabi"
650*5088Sab196087@ MSG_CMD_EI_ABIVERSION	"ei_abiversion"
651