]> git.wh0rd.org Git - elf2flt.git/commitdiff
elf2flt: fix unused warning for e1/bfin targets
authorMike Frysinger <vapier@gentoo.org>
Mon, 12 Dec 2016 05:35:04 +0000 (00:35 -0500)
committerMike Frysinger <vapier@gentoo.org>
Mon, 12 Dec 2016 05:35:04 +0000 (00:35 -0500)
The one call site for this func is inside of an e1/bfin ifdef check,
so add the same logic to the definition to fix a build error:
elf2flt.c:212:1: error: ‘get_symbol_offset’ defined but not used [-Werror=unused-function]

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
elf2flt.c

index 2d91beaaaa910b08aea40544981a051bad2dec5c..08296cf4e22c3fdbf757b3c683bf0348eee1c7da 100644 (file)
--- a/elf2flt.c
+++ b/elf2flt.c
@@ -208,6 +208,7 @@ dump_symbols(asymbol **symbol_table, long number_of_symbols)
 
 
 
+#if !defined TARGET_e1 && !defined TARGET_bfin
 static long
 get_symbol_offset(char *name, asection *sec, asymbol **symbol_table, long number_of_symbols)
 {
@@ -220,7 +221,8 @@ get_symbol_offset(char *name, asection *sec, asymbol **symbol_table, long number
     }
   }
   return -1;
-}  
+}
+#endif