diff options
author | Tristan Gingold <gingold@adacore.com> | 2011-08-08 07:39:44 +0000 |
---|---|---|
committer | Tristan Gingold <gingold@adacore.com> | 2011-08-08 07:39:44 +0000 |
commit | 53d58d96a751e0ff3c3bc4323f676bed1d521e0f (patch) | |
tree | fce549d8f49a9fd17422a439b41c98111dc302c1 /bfd/mach-o.h | |
parent | 066a66625f57511b9240cf37f8ab61e26d9f394c (diff) | |
download | gdb-53d58d96a751e0ff3c3bc4323f676bed1d521e0f.zip gdb-53d58d96a751e0ff3c3bc4323f676bed1d521e0f.tar.gz gdb-53d58d96a751e0ff3c3bc4323f676bed1d521e0f.tar.bz2 |
2011-08-08 Tristan Gingold <gingold@adacore.com>
* mach-o.c (bfd_mach_o_normalize_section_name): New function.
(bfd_mach_o_convert_section_name_to_bfd): Use it.
(bfd_mach_o_get_section_type_from_name): New function.
(bfd_mach_o_get_section_attribute_from_name): Ditto.
* mach-o.h (bfd_mach_o_section): Move bfdsection field at the end.
Add comments. Add prototypes for the above new functions.
Diffstat (limited to 'bfd/mach-o.h')
-rw-r--r-- | bfd/mach-o.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/bfd/mach-o.h b/bfd/mach-o.h index f0c2f6f..183076b 100644 --- a/bfd/mach-o.h +++ b/bfd/mach-o.h @@ -46,7 +46,7 @@ bfd_mach_o_header; typedef struct bfd_mach_o_section { - asection *bfdsection; + /* Fields present in the file. */ char sectname[16 + 1]; char segname[16 + 1]; bfd_vma addr; @@ -59,6 +59,9 @@ typedef struct bfd_mach_o_section unsigned long reserved1; unsigned long reserved2; unsigned long reserved3; + + /* Corresponding bfd section. */ + asection *bfdsection; } bfd_mach_o_section; #define BFD_MACH_O_SECTION_SIZE 68 @@ -610,6 +613,11 @@ bfd_boolean bfd_mach_o_set_section_contents (bfd *, asection *, const void *, file_ptr, bfd_size_type); unsigned int bfd_mach_o_version (bfd *); +unsigned int bfd_mach_o_get_section_type_from_name (const char *); +unsigned int bfd_mach_o_get_section_attribute_from_name (const char *); +void bfd_mach_o_normalize_section_name (const char *, const char *, + const char **, flagword *); + extern const bfd_target mach_o_fat_vec; #endif /* _BFD_MACH_O_H_ */ |