1# 2# CDDL HEADER START 3# 4# The contents of this file are subject to the terms of the 5# Common Development and Distribution License, Version 1.0 only 6# (the "License"). You may not use this file except in compliance 7# with the License. 8# 9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10# or http://www.opensolaris.org/os/licensing. 11# See the License for the specific language governing permissions 12# and limitations under the License. 13# 14# When distributing Covered Code, include this CDDL HEADER in each 15# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16# If applicable, add the following below this CDDL HEADER, with the 17# fields enclosed by brackets "[]" replaced with your own identifying 18# information: Portions Copyright [yyyy] [name of copyright owner] 19# 20# CDDL HEADER END 21# 22 23# 24# Copyright 2006 Sun Microsystems, Inc. All rights reserved. 25# Use is subject to license terms. 26# 27# ident "%Z%%M% %I% %E% SMI" 28 29@ _START_ 30 31# Message file for cmd/sgs/elfdump. 32 33@ MSG_ID_ELFDUMP 34 35# Usage Messages 36 37@ MSG_USAGE_BRIEF "usage: %s [-cCdegGhHiklmnprsuvy] [-N name] \ 38 [-W file] file(s)\n" 39@ MSG_USAGE_DETAIL1 "\t[-c]\t\tdump section header information\n" 40@ MSG_USAGE_DETAIL2 "\t[-C]\t\tdemangle C++ symbol names\n" 41@ MSG_USAGE_DETAIL3 "\t[-d]\t\tdump the contents of the .dynamic section\n" 42@ MSG_USAGE_DETAIL4 "\t[-e]\t\tdump the elf header\n" 43@ MSG_USAGE_DETAIL5 "\t[-g]\t\tdump the contents of the .group sections\n" 44@ MSG_USAGE_DETAIL6 "\t[-G]\t\tdump the contents of the .got section\n" 45@ MSG_USAGE_DETAIL7 "\t[-h]\t\tdump the contents of the .hash section\n" 46@ MSG_USAGE_DETAIL8 "\t[-H]\t\tdump the contents of the .SUNW_hwcap \ 47 section\n" 48@ MSG_USAGE_DETAIL9 "\t[-i]\t\tdump the contents of the .interp section\n" 49@ MSG_USAGE_DETAIL9_1 "\t[-l]\t\tdump with no truncated section names\n" 50@ MSG_USAGE_DETAIL10 "\t[-k]\t\tcalculate elf checksum\n" 51@ MSG_USAGE_DETAIL11 "\t[-m]\t\tdump the contents of the .SUNW_move \ 52 section\n" 53@ MSG_USAGE_DETAIL12 "\t[-n]\t\tdump the contents of the .note section\n" 54@ MSG_USAGE_DETAIL13 "\t[-N name]\tqualify an option with a `name'\n" 55@ MSG_USAGE_DETAIL14 "\t[-p]\t\tdump the program headers\n" 56@ MSG_USAGE_DETAIL15 "\t[-r]\t\tdump the contents of the relocation \ 57 sections\n" 58@ MSG_USAGE_DETAIL16 "\t[-s]\t\tdump the contents of the symbol table \ 59 sections\n" 60@ MSG_USAGE_DETAIL17 "\t[-u]\t\tdump the contents of a frame unwind \ 61 section\n" 62@ MSG_USAGE_DETAIL18 "\t[-v]\t\tdump the contents of the version sections\n" 63@ MSG_USAGE_DETAIL19 "\t[-w file]\twrite the contents of specified section \ 64 to `file'\n" 65@ MSG_USAGE_DETAIL20 "\t[-y]\t\tdump the contents of the .SUNW_syminfo \ 66 section\n" 67 68@ MSG_USAGE_DEMANGLE "usage: -C option is only meaningful \ 69 with other options that display symbol names\n" 70@ MSG_USAGE_LONGNAME "usage: -l option is only meaningful \ 71 with other options that display section names\n" 72 73# Errors 74 75@ MSG_ERR_BADFILE "%s: invalid file type\n" 76@ MSG_ERR_BADREL1 "%s: bad relocation entry: %s: relocation requires symbol\n" 77@ MSG_ERR_SHSTRNULL "%s: zero size section header string table (shstrtab)\n" 78@ MSG_ERR_FAILURE "%s: %s failed: %s\n" 79@ MSG_ERR_BADSHNAME "%s: %s: invalid sh_name: %lld\n" 80@ MSG_ERR_BADSHLINK "%s: %s: invalid sh_link: %lld\n" 81@ MSG_ERR_BADSHINFO "%s: %s: invalid sh_info: %lld\n" 82@ MSG_ERR_BADSHTYPE "%s: %s: invalid sh_type: %lld\n" 83@ MSG_ERR_BADALIGN "%s: %s: bad sh_offset alignment\n" 84@ MSG_ERR_SIBADCOUNT "%s: %s: bad syminfo entry: %d\n" 85@ MSG_ERR_BADCAP "%s: %s: bad capabilities entry: %s\n" 86@ MSG_ERR_BADSYM "%s: %s: bad symbol entry: %s\n" 87@ MSG_ERR_BADSYM2 "%s: %s: bad symbol entry: %s: must be SHN_COMMON or \ 88 defined in SHT_NOBITS section\n" 89@ MSG_ERR_BADSYM3 "%s: %s: bad symbol entry: %s: must be defined in \ 90 a SHF_TLS section\n" 91@ MSG_ERR_BADSYM4 "%s: %s: bad symbol entry: %s: must be defined in \ 92 a non-SHF_TLS section\n" 93@ MSG_ERR_BADSYM5 "%s: %s: bad symbol entry: %s: invalid shndx: %d\n" 94@ MSG_ERR_BADSYM6 "%s: %s: bad symbol entry: %s: section[%d] size: %lld: \ 95 is smaller than symbol size: %lld\n" 96@ MSG_ERR_BADMOVE "%s: %s: bad move table entry: %s\n" 97@ MSG_ERR_BADREL "%s: %s: bad relocation table entry: %s\n" 98@ MSG_ERR_RELBADSYMNDX "%s: bad symbol reference from relocation entry: %s\n" 99@ MSG_ERR_MVBADSYMNDX "%s: bad symbol reference from move entry: %s\n" 100@ MSG_ERR_HSBADSYMNDX "%s: bad symbol reference from hash entry: %s\n" 101@ MSG_ERR_GRBADSYMNDX "%s: bad symbol reference from group entry: %s\n" 102@ MSG_ERR_BADSYMXINDEX1 "%s: %s: index[%d]: invalid SHN_XINDEX reference: \ 103 SHT_SYMTAB_SHNDX section truncated: no entry for this \ 104 symbol\n" 105@ MSG_ERR_BADSYMXINDEX2 "%s: %s: index[%d]: invalid SHN_XINDEX reference: \ 106 bad SHT_SYMTAB_SHNDX entry: invalid shndx: 0x%x\n" 107@ MSG_ERR_BADSYMXINDEX3 "%s: %s: index[%d]: invalid SHN_XINDEX reference: \ 108 SHT_SYMTAB_SHNDX section not found\n" 109@ MSG_ERR_BADSTOFF "%s: %s: index[%d]: bad %s offset: 0x%llx: max 0x%llx\n" 110@ MSG_ERR_BADDYN "%s: %s: bad index into .dynamic: %d\n" 111@ MSG_ERR_BADSZ "%s: %s: zero size or entry size information\n" 112@ MSG_ERR_BADMINFO "%s: %s: invalid m_info: 0x%llx\n" 113@ MSG_ERR_BADHASH "%s: %s: bad hash entry: symbol %s: exists in bucket \ 114 %d, should be bucket %d\n" 115 116@ MSG_WARN_INVINTERP1 "%s: PT_INTERP header has no associated section\n" 117@ MSG_WARN_INVINTERP2 "%s: interp section: %s: and PT_INTERP program \ 118 header have conflicting size or offsets\n" 119@ MSG_WARN_INVCAP1 "%s: PT_SUNWCAP header has no associated section\n" 120@ MSG_WARN_INVCAP2 "%s: capabilities section: %s: requires PT_CAP program \ 121 header\n" 122@ MSG_WARN_INVCAP3 "%s: capabilities section: %s: and PT_CAP program \ 123 header have conflicting size or offsets\n" 124 125# Elf Output Messages 126 127@ MSG_ELF_SHDR "Section Header[%d]: sh_name: %s" 128@ MSG_ELF_PHDR "Program Header[%d]:" 129 130@ MSG_ELF_SCN_CAP "Hardware/Software Capabilities Section: %s" 131@ MSG_ELF_SCN_INTERP "Interpreter Section: %s" 132@ MSG_ELF_SCN_VERDEF "Version Definition Section: %s" 133@ MSG_ELF_SCN_VERNEED "Version Needed Section: %s" 134@ MSG_ELF_SCN_SYMTAB "Symbol Table Section: %s" 135@ MSG_ELF_SCN_RELOC "Relocation Section: %s" 136@ MSG_ELF_SCN_UNWIND "Unwind Section: %s" 137@ MSG_ELF_SCN_DYNAMIC "Dynamic Section: %s" 138@ MSG_ELF_SCN_NOTE "Note Section: %s" 139@ MSG_ELF_SCN_HASH "Hash Section: %s" 140@ MSG_ELF_SCN_SYMINFO "Syminfo Section: %s" 141@ MSG_ELF_SCN_GOT "Global Offset Table Section: %s (%u entries)" 142 143@ MSG_ELF_RELOC_RELA "\ttype\t\t offset addend section \ 144 with respect to" 145@ MSG_ELF_RELOC_REL "\ttype\t\t offset section \ 146 with respect to" 147@ MSG_ELF_L_RELOC_RELA "\ttype\t\t offset addend section/symbol" 148@ MSG_ELF_L_RELOC_REL "\ttype\t\t offset section/symbol" 149@ MSG_ELF_HASH_BKTS1 "%10.10s buckets contain %8d symbols" 150@ MSG_ELF_HASH_BKTS2 "%10.10s buckets %8d symbols (globals)" 151@ MSG_ELF_HASH_INFO " bucket symndx name" 152@ MSG_HASH_OVERFLW "%s: warning: section %s: too many symbols to count, \ 153 bucket=%d count=%d" 154@ MSG_ELF_ERR_SHDR "\tunable to obtain section header: shstrtab[%lld]\n" 155@ MSG_ELF_ERR_DATA "\tunable to obtain section data: shstrtab[%lld]\n" 156@ MSG_ELF_ERR_SCN "\tunable to obtain section header: section[%d]\n" 157@ MSG_ELF_ERR_SCNDATA "\tunable to obtain section data: section[%d]\n" 158@ MSG_ARCHIVE_SYMTAB "\nSymbol Table: (archive)" 159@ MSG_ARCHIVE_FIELDS " index offset member name and symbol" 160 161@ MSG_GOT_MULTIPLE "%s: multiple relocations against \ 162 the same GOT entry ndx: %d addr: 0x%llx\n" 163@ MSG_GOT_UNEXPECTED "%s: warning: section %s: section unexpected within \ 164 relocatable object\n" 165 166 167# Miscellaneous clutter 168 169@ MSG_STR_INDEX "index" 170@ MSG_STR_NAME "name" 171@ MSG_STR_NULL "(null)" 172@ MSG_STR_DEPRECATED "(deprecated value)" 173@ MSG_STR_UNKNOWN "<unknown>" 174@ MSG_STR_SECTION "%.12s (section)" 175@ MSG_STR_L_SECTION "%s (section)" 176@ MSG_STR_CHECKSUM "elf checksum: 0x%lx" 177 178@ MSG_FMT_SCNNDX "section[%d]" 179 180@ MSG_ERR_MALLOC "%s: malloc: %s\n" 181@ MSG_ERR_OPEN "%s: open: %s\n" 182 183# 184# For Elf{32,64}_Move section 185# 186@ MSG_MV_TITLE "Move Section: %s\n\ 187 \toffset\tndx\tsize\trepeat\tstride\tvalue\twith \ 188 respect to" 189@ MSG_MV_ENTRY "\t0x%llx\t0x%llx\t%d\t%d\t%d\t0x%llx\t%s" 190 191 192# 193# SHT_GROUP messages 194# 195@ MSG_GRP_NOTSYMTAB "%s: %s: sh_link[%lld] does not point to .symtab\n" 196@ MSG_GRP_BADSYMNDX "%s: %s: sh_info[%lld] has invalid symbol index\n" 197@ MSG_GRP_BADENTSZ "%s: %s: has invalid sh_entsize: %lld\n" 198@ MSG_GRP_LINE1 "\nGroup Section: %s" 199@ MSG_GRP_LINE2 "\t[ndx] Flags/Section Signature Symbol" 200@ MSG_GRP_LINE3 "\t [0] %-24s %s" 201@ MSG_GRP_INVALSCN "<invalid section>" 202 203# 204# SHT_NOTE messages 205# 206@ MSG_NOTE_BADDATASIZE "%s: %s: note header exceeds section size. \ 207 offset: 0x%x\n" 208@ MSG_NOTE_BADNMSIZE "%s: %s: note name value exceeds section size. \ 209 offset: 0x%x namesize: 0x%x\n" 210@ MSG_NOTE_BADDESIZE "%s: %s: note data size exceeds section size. \ 211 offset: 0x%x datasize: 0x%x\n" 212 213 214@ _END_ 215 216# The following strings represent reserved words, files, pathnames and symbols. 217# Reference to this strings is via the MSG_ORIG() macro, and thus no message 218# translation is required. 219 220 221@ MSG_GRP_COMDAT " COMDAT" 222@ MSG_GRP_FMT1 " 0x%x" 223@ MSG_GRP_FMT2 "%13.13s %s[%d]\n" 224@ MSG_GRP_CLOSBRKT " ]" 225 226@ MSG_ELF_GOT ".got" 227 228@ MSG_ELF_GETEHDR "elf_getehdr" 229@ MSG_ELF_GETPHDR "elf_getphdr" 230@ MSG_ELF_GETSHDR "elf_getshdr" 231@ MSG_ELF_GETSCN "elf_getscn" 232@ MSG_ELF_GETDATA "elf_getdata" 233@ MSG_ELF_GETARHDR "elf_getarhdr" 234@ MSG_ELF_GETARSYM "elf_getarsym" 235@ MSG_ELF_RAND "elf_rand" 236@ MSG_ELF_BEGIN "elf_begin" 237@ MSG_ELF_GETPHNUM "elf_getphnum" 238@ MSG_ELF_GETSHNUM "elf_getshnum" 239@ MSG_ELF_GETSHSTRNDX "elf_getshstrndx" 240@ MSG_ELF_ARSYM "ARSYM" 241 242@ MSG_GOT_SYM "_GLOBAL_OFFSET_TABLE_" 243 244@ MSG_STR_OPTIONS "CcdeGgHhiklmN:nprsuvw:y" 245 246@ MSG_STR_EMPTY "" 247@ MSG_STR_NL "\n" 248 249@ MSG_FMT_INDENT " %s" 250@ MSG_FMT_INDEX " [%lld]" 251@ MSG_FMT_INDEX2 "[%lld]" 252@ MSG_FMT_INTEGER " %d" 253@ MSG_FMT_HASH_INFO "%10.10s %-10s %s" 254@ MSG_FMT_ARSYM1 "%10.10s 0x%8.8x (%s):%s" 255@ MSG_FMT_ARSYM2 "%10.10s 0x%8.8x" 256@ MSG_FMT_ARNAME "%s(%s)" 257@ MSG_FMT_NLSTR "\n%s:" 258@ MSG_FMT_NLSTRNL "\n%s:\n" 259 260@ MSG_SUNW_OST_SGS "SUNW_OST_SGS" 261 262# Unwind info 263@ MSG_SCN_FRM ".eh_frame" 264@ MSG_SCN_FRMHDR ".eh_frame_hdr" 265@ MSG_UNW_FRMHDR "Frame Header:" 266@ MSG_UNW_FRMVERS " Version: %d" 267@ MSG_UNW_FRPTRENC " FramePtrEnc: %-16s FramePtr: 0x%llx" 268@ MSG_UNW_FDCNENC " FdeCntEnc: %-16s FdeCnt: %lld" 269@ MSG_UNW_TABENC " TableEnc: %-16s" 270@ MSG_UNW_BINSRTAB1 " Binary Search Table:" 271@ MSG_UNW_BINSRTAB2 " InitialLoc FdeLoc" 272@ MSG_UNW_BINSRTABENT " 0x%012llx 0x%012llx" 273@ MSG_UNW_CIE "CIE: [0x%08llx]" 274@ MSG_UNW_CIELNGTH " length: 0x%02x cieid: %d" 275@ MSG_UNW_CIEVERS " version: %d augstring: `%s'" 276@ MSG_UNW_CIECALGN " codealign: 0x%llx dataalign: %lld \ 277 retaddr: %d" 278@ MSG_UNW_CIEAUXVAL " Auxillary vals:" 279@ MSG_UNW_CIEAUXSIZE " size: %d" 280@ MSG_UNW_CIEAUXPERS " pers: 0x%02x %s 0x%08llx" 281@ MSG_UNW_CIEAUXCENC " cenc: 0x%02x %s" 282@ MSG_UNW_CIEAUXLSDA " lsda: 0x%02x %s" 283@ MSG_UNW_CIEAUXUNEC " Unexpected aug val: %c" 284@ MSG_UNW_CIECFI " CallFrameInstructions:" 285@ MSG_UNW_CIECFI1 "\n " 286@ MSG_UNW_CIECFI2 "0x%02x " 287 288@ MSG_UNW_FDE " FDE: [0x%08llx]" 289@ MSG_UNW_FDELNGTH " length: 0x%02x cieptr: 0x%02x" 290@ MSG_UNW_FDEINITLOC " initloc: 0x%08llx addrrange: 0x%04llx" 291@ MSG_UNW_FDEAUXVAL " Auxillary vals:" 292@ MSG_UNW_FDEAUXSIZE " size: 0x%llx" 293@ MSG_UNW_FDEAUXLSDA " lsda: 0x%llx" 294@ MSG_UNW_FDECFI " CallFrameInstructions:" 295@ MSG_UNW_FDECFI1 "\n " 296@ MSG_UNW_FDECFI2 "0x%02x " 297 298# Note messages 299 300@ MSG_NOTE_TYPE " type %#x" 301@ MSG_NOTE_NAMESZ " namesz %#x:" 302@ MSG_NOTE_DESCSZ " descsz %#x:" 303@ MSG_NOTE_DESC " desc[%d]\t%s" 304@ MSG_NOTE_TOK "%2.2x " 305