sparc32-ext.h 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. /* SPARC NLM (NetWare Loadable Module) support for BFD.
  2. Copyright (C) 1993-2015 Free Software Foundation, Inc.
  3. This file is part of BFD, the Binary File Descriptor library.
  4. This program is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 3 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program; if not, write to the Free Software
  14. Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
  15. MA 02110-1301, USA. */
  16. /* The external format of the fixed header. */
  17. typedef struct nlm32_sparc_external_fixed_header
  18. {
  19. /* The signature field identifies the file as an NLM. It must contain
  20. the signature string, which depends upon the NLM target. */
  21. unsigned char signature[24];
  22. /* The version of the header. At this time, the highest version number
  23. is 4. */
  24. unsigned char version[4];
  25. /* The name of the module, which must be a DOS name (1-8 characters followed
  26. by a period and a 1-3 character extension). The first byte is the byte
  27. length of the name and the last byte is a null terminator byte. This
  28. field is fixed length, and any unused bytes should be null bytes. The
  29. value is set by the OUTPUT keyword to NLMLINK. */
  30. unsigned char moduleName[14];
  31. /* Padding to make it come out correct. */
  32. unsigned char pad1[2];
  33. /* The byte offset of the code image from the start of the file. */
  34. unsigned char codeImageOffset[4];
  35. /* The size of the code image, in bytes. */
  36. unsigned char codeImageSize[4];
  37. /* The byte offset of the data image from the start of the file. */
  38. unsigned char dataImageOffset[4];
  39. /* The size of the data image, in bytes. */
  40. unsigned char dataImageSize[4];
  41. /* The size of the uninitialized data region that the loader is to be
  42. allocated at load time. Uninitialized data follows the initialized
  43. data in the NLM address space. */
  44. unsigned char uninitializedDataSize[4];
  45. /* The byte offset of the custom data from the start of the file. The
  46. custom data is set by the CUSTOM keyword to NLMLINK. It is possible
  47. for this to be EOF if there is no custom data. */
  48. unsigned char customDataOffset[4];
  49. /* The size of the custom data, in bytes. */
  50. unsigned char customDataSize[4];
  51. /* The byte offset of the module dependencies from the start of the file.
  52. The module dependencies are determined by the MODULE keyword in
  53. NLMLINK. */
  54. unsigned char moduleDependencyOffset[4];
  55. /* The number of module dependencies at the moduleDependencyOffset. */
  56. unsigned char numberOfModuleDependencies[4];
  57. /* The byte offset of the relocation fixup data from the start of the file */
  58. unsigned char relocationFixupOffset[4];
  59. unsigned char numberOfRelocationFixups[4];
  60. unsigned char externalReferencesOffset[4];
  61. unsigned char numberOfExternalReferences[4];
  62. unsigned char publicsOffset[4];
  63. unsigned char numberOfPublics[4];
  64. /* The byte offset of the internal debug info from the start of the file.
  65. It is possible for this to be EOF if there is no debug info. */
  66. unsigned char debugInfoOffset[4];
  67. unsigned char numberOfDebugRecords[4];
  68. unsigned char codeStartOffset[4];
  69. unsigned char exitProcedureOffset[4];
  70. unsigned char checkUnloadProcedureOffset[4];
  71. unsigned char moduleType[4];
  72. unsigned char flags[4];
  73. } Nlm32_sparc_External_Fixed_Header;