ELF: Don't generate unused section symbols
[deliverable/binutils-gdb.git] / bfd / bfd-in2.h
index 43ead185c197bbad6f1b1d4b806876f0b5efe6f3..7eff85b7eaa6e58e26baf24b6dae06597688c18a 100644 (file)
@@ -6416,6 +6416,9 @@ typedef struct bfd_symbol
      with this name and type in use.  BSF_OBJECT must also be set.  */
 #define BSF_GNU_UNIQUE          (1 << 23)
 
+  /* This section symbol should be included in the symbol table.  */
+#define BSF_SECTION_SYM_USED    (1 << 24)
+
   flagword flags;
 
   /* A pointer to the section to which this symbol is
@@ -7291,6 +7294,11 @@ bfd_boolean generic_core_file_matches_executable_p
    (bfd_assert (__FILE__,__LINE__), NULL))
 #endif
 
+/* Defined to TRUE if unused section symbol should be kept.  */
+#ifndef TARGET_KEEP_UNUSED_SECTION_SYMBOLS
+#define TARGET_KEEP_UNUSED_SECTION_SYMBOLS TRUE
+#endif
+
 enum bfd_flavour
 {
   /* N.B. Update bfd_flavour_name if you change this.  */
@@ -7364,6 +7372,9 @@ typedef struct bfd_target
      possible targets when more than one target matches.  */
   unsigned char match_priority;
 
+ /* TRUE if unused section symbols should be kept.  */
+  bfd_boolean keep_unused_section_symbols;
+
   /* Entries for byte swapping for data. These are different from the
      other entry points, since they don't take a BFD as the first argument.
      Certain other handlers could do the same.  */
@@ -7794,6 +7805,12 @@ bfd_asymbol_flavour (const asymbol *sy)
   return sy->the_bfd->xvec->flavour;
 }
 
+static inline bfd_boolean
+bfd_keep_unused_section_symbols (const bfd *abfd)
+{
+  return abfd->xvec->keep_unused_section_symbols;
+}
+
 bfd_boolean bfd_set_default_target (const char *name);
 
 const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
This page took 0.028592 seconds and 4 git commands to generate.