]> rtime.felk.cvut.cz Git - fpga/lx-cpu1/binutils-tumbl.git/commitdiff
PR binutils/13558
authorNick Clifton <nickc@redhat.com>
Wed, 16 May 2012 14:26:44 +0000 (14:26 +0000)
committerNick Clifton <nickc@redhat.com>
Wed, 16 May 2012 14:26:44 +0000 (14:26 +0000)
* bfd/aout-cris.c: Include sysdep.h before bfd.h.
* bfd/aout-ns32k.c: Likewise.
* bfd/aout-sparcle.c: Likewise.
* bfd/aout0.c: Likewise.
* bfd/bfd-in2.h: Likewise.
* bfd/coff-stgo32.c: Likewise.
* bfd/cpu-lm32.c: Likewise.
* bfd/cpu-microblaze.c: Likewise.
* bfd/cpu-score.c: Likewise.
* bfd/cpu-tilegx.c: Likewise.
* bfd/cpu-tilepro.c: Likewise.
* bfd/elf32-lm32.c: Likewise.
* bfd/elf32-microblaze.c: Likewise.
* bfd/elf32-score7.c: Likewise.
* bfd/elf32-tilepro.c: Likewise.
* bfd/elfxx-tilegx.c: Likewise.
* bfd/mach-o.h: Likewise.
* bfd/nlm32-ppc.c: Likewise.
* bfd/ns32knetbsd.c: Likewise.
* bfd/pef.h: Likewise.
* bfd/plugin.c: Likewise.
* bfd/stab-syms.c: Likewise.
* bfd/sunos.c: Likewise.
* bfd/syms.c: Likewise.
* bfd/xsym.h: Likewise.

* Makefile.am (CFILES): Add syslex_wrap.c.
(sysinfo): Depend upon syslex_wrap.o.
(syslex_wrap.o): New rule.
(syslex.o): Delete rule.
* syslex_wrap.c: New file.
* Makefile.in: Regenerate.

32 files changed:
bfd/ChangeLog
bfd/aout-cris.c
bfd/aout-ns32k.c
bfd/aout-sparcle.c
bfd/aout0.c
bfd/bfd-in2.h
bfd/coff-stgo32.c
bfd/cpu-lm32.c
bfd/cpu-microblaze.c
bfd/cpu-score.c
bfd/cpu-tilegx.c
bfd/cpu-tilepro.c
bfd/elf32-lm32.c
bfd/elf32-microblaze.c
bfd/elf32-score7.c
bfd/elf32-tilepro.c
bfd/elfxx-tilegx.c
bfd/mach-o.h
bfd/nlm32-ppc.c
bfd/ns32knetbsd.c
bfd/pef.h
bfd/plugin.c
bfd/stab-syms.c
bfd/sunos.c
bfd/syms.c
bfd/xsym.h
binutils/ChangeLog
binutils/Makefile.am
binutils/Makefile.in
binutils/doc/Makefile.in
binutils/syslex.l
binutils/syslex_wrap.c [new file with mode: 0644]

index 6e9e0984f683afcd900e7a44d8df3fce2b16e0b7..200e37a6e1201cdb8733dec7f344fa2a7358a7b4 100644 (file)
@@ -1,3 +1,32 @@
+2012-05-16  Daniel Richard G.  <skunk@iskunk.org>
+
+       PR binutils/13558
+       * bfd/aout-cris.c: Include sysdep.h before bfd.h.
+       * bfd/aout-ns32k.c: Likewise.
+       * bfd/aout-sparcle.c: Likewise.
+       * bfd/aout0.c: Likewise.
+       * bfd/bfd-in2.h: Likewise.
+       * bfd/coff-stgo32.c: Likewise.
+       * bfd/cpu-lm32.c: Likewise.
+       * bfd/cpu-microblaze.c: Likewise.
+       * bfd/cpu-score.c: Likewise.
+       * bfd/cpu-tilegx.c: Likewise.
+       * bfd/cpu-tilepro.c: Likewise.
+       * bfd/elf32-lm32.c: Likewise.
+       * bfd/elf32-microblaze.c: Likewise.
+       * bfd/elf32-score7.c: Likewise.
+       * bfd/elf32-tilepro.c: Likewise.
+       * bfd/elfxx-tilegx.c: Likewise.
+       * bfd/mach-o.h: Likewise.
+       * bfd/nlm32-ppc.c: Likewise.
+       * bfd/ns32knetbsd.c: Likewise.
+       * bfd/pef.h: Likewise.
+       * bfd/plugin.c: Likewise.
+       * bfd/stab-syms.c: Likewise.
+       * bfd/sunos.c: Likewise.
+       * bfd/syms.c: Likewise.
+       * bfd/xsym.h: Likewise.
+
 2012-05-16  Alan Modra  <amodra@gmail.com>
 
        * elflink.c: Rename flaginfo to flinfo throughout, except..
index f1f30601f40ec3408d107bf1b182b5b0926738c6..3e3d21ad7a73769ae2d959b3784a3c71b64bf34e 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD backend for CRIS a.out binaries.
-   Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2009
+   Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2009, 2012
    Free Software Foundation, Inc.
    Contributed by Axis Communications AB.
    Written by Hans-Peter Nilsson.
@@ -66,6 +66,7 @@
 #define MY(OP) CONCAT2 (cris_aout_,OP)
 #define NAME(x, y) CONCAT3 (cris_aout,_32_,y)
 
+#include "sysdep.h"
 #include "bfd.h"
 
 /* Version 1 of the header.  */
index 5cf5ad4fabd23c3a19bbd63c8f2f6d48a06525c1..75886bca1d26e2a182e2acc1ea382b8be7399122 100644 (file)
@@ -20,6 +20,7 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
+#include "sysdep.h"
 #include "bfd.h"
 #include "aout/aout64.h"
 #include "ns32k.h"
index afcc3421121b4e8d4d5def2f37e98d42fae7bb13..e050423300968ee3df4b4b7c8ac17b02f02ab69a 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD backend for sparc little-endian aout binaries.
-   Copyright 1996, 2001, 2005, 2007 Free Software Foundation, Inc.
+   Copyright 1996, 2001, 2005, 2007, 2012 Free Software Foundation, Inc.
    Written by Cygnus Support.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -25,6 +25,7 @@
    the tokens.  */
 #define MY(OP) CONCAT2 (sparcle_aout_,OP)
 
+#include "sysdep.h"
 #include "bfd.h"
 #include "bfdlink.h"
 #include "libaout.h"
index e87af0071c1ee7144bcca69804c073fabdf3b76e..7cec377314bd2dff988bacb6992c13d847efcba5 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD backend for SunOS style a.out with flags set to 0
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001, 2005, 2007
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001, 2005, 2007, 2012
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -27,6 +27,7 @@
    the tokens.  */
 #define MY(OP) CONCAT2 (aout0_big_,OP)
 
+#include "sysdep.h"
 #include "bfd.h"
 
 #define MY_exec_hdr_flags 0
index fa2b9a5688d86ef466fb663b19cc515f92423011..a006591959a0cfb7cd4d207d9880bf596827e6ae 100644 (file)
@@ -6306,8 +6306,8 @@ typedef struct bfd_target
 
   /* Sets the bitmask of allowed and disallowed section flags.  */
   bfd_boolean (*_bfd_lookup_section_flags) (struct bfd_link_info *,
-                                           struct flag_info *,
-                                           asection *);
+                                            struct flag_info *,
+                                            asection *);
 
   /* Attempt to merge SEC_MERGE sections.  */
   bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
index c10194e6be85ecea35329bdfa38f2ba4c74fa347..125b0d915a1974080d617a1deedc851c454e85c7 100644 (file)
@@ -1,6 +1,6 @@
 /* BFD back-end for Intel 386 COFF files (DJGPP variant with a stub).
    Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2005, 2006, 2007, 2009,
-   2011  Free Software Foundation, Inc.
+   2011, 2012  Free Software Foundation, Inc.
    Written by Robert Hoehne.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -54,6 +54,7 @@
 { COFF_SECTION_NAME_PARTIAL_MATCH (".gnu.linkonce.wi"), \
   COFF_ALIGNMENT_FIELD_EMPTY, COFF_ALIGNMENT_FIELD_EMPTY, 0 }
 
+#include "sysdep.h"
 #include "bfd.h"
 
 /* At first the prototypes.  */
index 5ddce0438b0490c2204fa1ab9c9ebc00fa022644..5222a914a51b68c4dd2fb0580ca6ae5ad2bd03d0 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the Lattice Mico32 architecture.
-   Copyright 2008 Free Software Foundation, Inc.
+   Copyright 2008, 2012 Free Software Foundation, Inc.
    Contributed by Jon Beniston <jon@beniston.com>
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -19,8 +19,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 const bfd_arch_info_type bfd_lm32_arch = 
index c59fa45d5202545775c10c9eebcdb97fdd4567ce..2cf6bc68afb5ce50e5d9d36a01fa6bb0ad787b36 100644 (file)
@@ -1,6 +1,6 @@
 /* BFD Xilinx MicroBlaze architecture definition
 
-   Copyright 2009 Free Software Foundation, Inc.
+   Copyright 2009, 2012 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -19,8 +19,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 const bfd_arch_info_type bfd_microblaze_arch =
index 7a8d7b49591ee29225d4b82c1288a93af73f1a0b..329c97c402167164191ad3aeda0453699e300609 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the score processor
-   Copyright 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
+   Copyright 2006, 2007, 2008, 2009, 2012 Free Software Foundation, Inc.
    Contributed by
    Brain.lin (brain.lin@sunplusct.com)
    Mei Ligang (ligang@sunnorth.com.cn)
@@ -22,8 +22,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 /* This routine is provided two arch_infos and works out which Score
index f98cb0c4675230b6b9b09bd3fedf110c94d4e00a..11234ecad28183f72f9bc89c621a480fb10510da 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the TILE-Gx processor.
-   Copyright 2011 Free Software Foundation, Inc.
+   Copyright 2011, 2012 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -18,8 +18,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 const bfd_arch_info_type bfd_tilegx32_arch =
index 33bfab0139de06228c1a288f719dd13872bb8b33..4066fc19df54acfcc36dd4b8950c832dbcda76ba 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the TILEPro processor.
-   Copyright 2011 Free Software Foundation, Inc.
+   Copyright 2011, 2012 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -18,8 +18,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 const bfd_arch_info_type bfd_tilepro_arch =
index b18f08f459f8ae8700b0ae86410e24b36cc9007e..b2211a302e47120da37f2ed75a7cda476f4d7954 100644 (file)
@@ -19,8 +19,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 #include "elf-bfd.h"
 #include "elf/lm32.h"
index a58f7b39a07aadddc03769fa87a95b66ce596d97..1fe0640b0280c6738a43d4cc250243edf80f3014 100644 (file)
@@ -22,8 +22,8 @@
 
 int dbg = 0;
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "bfdlink.h"
 #include "libbfd.h"
 #include "elf-bfd.h"
index b18991b4129c60b3970c0925bf9b9b98cfc1e8d6..7ec774a419bf43a20e12b8f5dd92f264fd5814c1 100644 (file)
@@ -22,8 +22,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 #include "libiberty.h"
 #include "elf-bfd.h"
index 88c1326fdd53036e7fb2138ae8256d7252b85065..899abdd52e64838dfcbc8bd69af46706e92bd9b6 100644 (file)
@@ -18,8 +18,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 #include "elf-bfd.h"
 #include "elf/tilepro.h"
index 9939228fbcef8294cba729c8bbe974897e9de625..02f80c53c48108fcf5d43acb92724616e13d94b1 100644 (file)
@@ -18,8 +18,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 #include "elf-bfd.h"
 #include "elf/tilegx.h"
index 7f54961c7f3ae9d1f8a90508fa634def08947969..67ee43db827c3024867eef58c91463c4518befd4 100644 (file)
@@ -23,6 +23,7 @@
 #ifndef _BFD_MACH_O_H_
 #define _BFD_MACH_O_H_
 
+#include "sysdep.h"
 #include "bfd.h"
 #include "mach-o/loader.h"
 
index b8c5852d909d7b415320582a0fb484b5ce0091fb..ef5bfa9848390066cce93fa59a598158a05d9bda 100644 (file)
@@ -1,6 +1,6 @@
 /* Support for 32-bit PowerPC NLM (NetWare Loadable Module)
    Copyright 1994, 1995, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-   2007 Free Software Foundation, Inc.
+   2007, 2012 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -19,8 +19,8 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-#include "bfd.h"
 #include "sysdep.h"
+#include "bfd.h"
 #include "libbfd.h"
 
 /* The format of a PowerPC NLM changed.  Define OLDFORMAT to get the
index 6b636ae6b0e58058b4fee154b7b14dc943eb879d..fe0a6882a6e0237893f2dbfd7429c9a5aba2a382 100644 (file)
@@ -1,6 +1,6 @@
 /* BFD back-end for NetBSD/ns32k a.out-ish binaries.
    Copyright 1990, 1991, 1992, 1994, 1995, 1998, 2000, 2001, 2002, 2005,
-   2007  Free Software Foundation, Inc.
+   2007, 2012  Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -46,6 +46,7 @@
    for me -- IWD.  */
 #define MY_bfd_reloc_type_lookup ns32kaout_bfd_reloc_type_lookup
 
+#include "sysdep.h"
 #include "bfd.h"               /* To ensure following declaration is OK.  */
 
 const struct reloc_howto_struct * MY_bfd_reloc_type_lookup (bfd *, bfd_reloc_code_real_type);
index db8d18cfefc1d261ec225f113728bf1f881210f5..d73ff370c9ccb840bba87f0561ed94d48f6cb43b 100644 (file)
--- a/bfd/pef.h
+++ b/bfd/pef.h
@@ -19,6 +19,7 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
+#include "sysdep.h"
 #include "bfd.h"
 
 #include <stdio.h>
index 0a29e378d50dee96c6ab695bacd32c40d7ee7634..733ba71adf76682f8a8ed1dd69ec2e6a4456ef59 100644 (file)
@@ -1,5 +1,5 @@
 /* Plugin support for BFD.
-   Copyright 2009, 2010, 2011
+   Copyright 2009, 2010, 2011, 2012
    Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -20,6 +20,7 @@
    MA 02110-1301, USA.  */
 
 #include "config.h"
+#include "sysdep.h"
 #include "bfd.h"
 
 #if BFD_SUPPORTS_PLUGINS
@@ -34,7 +35,6 @@
 #endif
 #include <stdarg.h>
 #include "plugin-api.h"
-#include "sysdep.h"
 #include "plugin.h"
 #include "libbfd.h"
 #include "libiberty.h"
index 9e9274f987dc4a46bc7d7703262ec945a41522b8..8e65ddc65c156245a3e340f33f25ccf5913c9626 100644 (file)
@@ -1,5 +1,5 @@
 /* Table of stab names for the BFD library.
-   Copyright 1990, 1991, 1992, 1994, 1995, 1996, 2000, 2005, 2007
+   Copyright 1990, 1991, 1992, 1994, 1995, 1996, 2000, 2005, 2007, 2012
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -20,6 +20,7 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
+#include "sysdep.h"
 #include "bfd.h"
 
 #define ARCH_SIZE 32           /* Value doesn't matter.  */
index 8ef25edbb1cfa9cf045375664caa72c8b3f2094a..bd140015eb72b12946fba6758d7643b181283b56 100644 (file)
@@ -1,6 +1,6 @@
 /* BFD backend for SunOS binaries.
    Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2011
+   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2011, 2012
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -28,6 +28,7 @@
    the tokens.  */
 #define MY(OP) CONCAT2 (sunos_big_,OP)
 
+#include "sysdep.h"
 #include "bfd.h"
 #include "bfdlink.h"
 #include "libaout.h"
index e819eae16d6e1abb33c38837fec8ec01fde8d9b7..bf5a48894ca417620c16a652c19de4ed61cf3153 100644 (file)
@@ -1,6 +1,6 @@
 /* Generic symbol-table support for the BFD library.
    Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009
+   2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009, 2012
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -107,6 +107,7 @@ SUBSECTION
        which has been created using <<bfd_make_empty_symbol>>.  Here is an
        example showing the creation of a symbol table with only one element:
 
+|      #include "sysdep.h"
 |      #include "bfd.h"
 |      int main (void)
 |      {
index 85e173a224ad9d879c753e78e1c9836439a7c159..e4a754ce899be7447df9786598ed3170dbcbb8ce 100644 (file)
@@ -1,5 +1,5 @@
 /* xSYM symbol-file support for BFD.
-   Copyright 1999, 2000, 2001, 2002, 2003, 2005, 2006, 2007
+   Copyright 1999, 2000, 2001, 2002, 2003, 2005, 2006, 2007, 2012
    Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -19,6 +19,7 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
+#include "sysdep.h"
 #include "bfd.h"
 #include <stdio.h>
 
index fc8420cc2d807f0807c39f73638fcb4166bdee8c..64786dae8f4d4d7d18905b66369060546a0563d1 100644 (file)
@@ -1,3 +1,13 @@
+2012-05-16  Daniel Richard G.  <skunk@iskunk.org>
+
+       PR binutils/13558
+       * Makefile.am (CFILES): Add syslex_wrap.c.
+       (sysinfo): Depend upon syslex_wrap.o.
+       (syslex_wrap.o): New rule.
+       (syslex.o): Delete rule.
+       * syslex_wrap.c: New file.
+       * Makefile.in: Regenerate.
+
 2012-05-15  James Murray <jsm@jsm-net.demon.co.uk>
 
        * readelf.c (get_machine_name): Update m68hc12 entry.
index e492cb3841482ebde0dcb4e2e5aac6ee8d692f69..3364bee6a9cbd9ecea5af87d3901723cfba7fa69 100644 (file)
@@ -106,7 +106,7 @@ CFILES = \
        rclex.c rdcoff.c rddbg.c readelf.c rename.c \
        resbin.c rescoff.c resrc.c resres.c \
        size.c srconv.c stabs.c strings.c sysdump.c \
-       unwind-ia64.c elfedit.c version.c \
+       syslex_wrap.c unwind-ia64.c elfedit.c version.c \
        windres.c winduni.c wrstabs.c \
        windmc.c mclex.c
 
@@ -268,15 +268,11 @@ sysroff.c: sysinfo$(EXEEXT_FOR_BUILD) sysroff.info
 sysroff.h: sysinfo$(EXEEXT_FOR_BUILD) sysroff.info
        ./sysinfo$(EXEEXT_FOR_BUILD) -d <$(srcdir)/sysroff.info >sysroff.h
 
-sysinfo$(EXEEXT_FOR_BUILD): sysinfo.@OBJEXT@ syslex.@OBJEXT@
-       $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.@OBJEXT@ syslex.@OBJEXT@
+sysinfo$(EXEEXT_FOR_BUILD): sysinfo.@OBJEXT@ syslex_wrap.@OBJEXT@
+       $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.@OBJEXT@ syslex_wrap.@OBJEXT@
 
-syslex.@OBJEXT@: syslex.c sysinfo.h config.h
-       if [ -r syslex.c ]; then \
-         $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) syslex.c ; \
-       else \
-         $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) $(srcdir)/syslex.c ;\
-       fi
+syslex_wrap.@OBJEXT@: syslex_wrap.c syslex.c sysinfo.h config.h
+       $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) $(srcdir)/syslex_wrap.c
 
 sysinfo.@OBJEXT@: sysinfo.c
        if [ -r sysinfo.c ]; then \
index 3ac0d0aa9f604eff109dd5c984caf6c2a302d841..88678133a1488fecee666c01f393d9465452913f 100644 (file)
@@ -476,7 +476,7 @@ CFILES = \
        rclex.c rdcoff.c rddbg.c readelf.c rename.c \
        resbin.c rescoff.c resrc.c resres.c \
        size.c srconv.c stabs.c strings.c sysdump.c \
-       unwind-ia64.c elfedit.c version.c \
+       syslex_wrap.c unwind-ia64.c elfedit.c version.c \
        windres.c winduni.c wrstabs.c \
        windmc.c mclex.c
 
@@ -880,6 +880,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stabs.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strings.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sysdump.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslex_wrap.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/unwind-ia64.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/windmc.Po@am__quote@
@@ -1284,15 +1285,11 @@ sysroff.c: sysinfo$(EXEEXT_FOR_BUILD) sysroff.info
 sysroff.h: sysinfo$(EXEEXT_FOR_BUILD) sysroff.info
        ./sysinfo$(EXEEXT_FOR_BUILD) -d <$(srcdir)/sysroff.info >sysroff.h
 
-sysinfo$(EXEEXT_FOR_BUILD): sysinfo.@OBJEXT@ syslex.@OBJEXT@
-       $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.@OBJEXT@ syslex.@OBJEXT@
+sysinfo$(EXEEXT_FOR_BUILD): sysinfo.@OBJEXT@ syslex_wrap.@OBJEXT@
+       $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.@OBJEXT@ syslex_wrap.@OBJEXT@
 
-syslex.@OBJEXT@: syslex.c sysinfo.h config.h
-       if [ -r syslex.c ]; then \
-         $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) syslex.c ; \
-       else \
-         $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) $(srcdir)/syslex.c ;\
-       fi
+syslex_wrap.@OBJEXT@: syslex_wrap.c syslex.c sysinfo.h config.h
+       $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(NO_WERROR) $(srcdir)/syslex_wrap.c
 
 sysinfo.@OBJEXT@: sysinfo.c
        if [ -r sysinfo.c ]; then \
index 3acf28a55b16b2af6fea07ba6ff6c8e6574eea7d..e39ee65c88812c082b135d5f44835975b4abf7a1 100644 (file)
@@ -44,6 +44,7 @@ am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
        $(top_srcdir)/../config/gettext-sister.m4 \
        $(top_srcdir)/../config/iconv.m4 \
        $(top_srcdir)/../config/largefile.m4 \
+       $(top_srcdir)/../config/lcmessage.m4 \
        $(top_srcdir)/../config/lead-dot.m4 \
        $(top_srcdir)/../config/lib-ld.m4 \
        $(top_srcdir)/../config/lib-link.m4 \
index abfa6783767c57f2a7fb20619eaa0c9011494055..14aee731e3a165df527edceda8cf364120b5ddae 100644 (file)
@@ -1,7 +1,7 @@
 %option noinput nounput
 
 %{
-/* Copyright 2001, 2003, 2005, 2007, 2011 Free Software Foundation, Inc.
+/* Copyright 2001, 2003, 2005, 2007, 2011, 2012 Free Software Foundation, Inc.
 
    This file is part of GNU Binutils.
 
@@ -20,7 +20,8 @@
    Software Foundation, 51 Franklin Street - Fifth Floor, Boston, MA
    02110-1301, USA.  */
 
-#include "config.h"
+/* Note: config.h is #included via syslex_wrap.c.  */
+
 #ifdef HAVE_STRING_H
 #include <string.h>
 #else
@@ -28,6 +29,7 @@
 #include <strings.h>
 #endif
 #endif
+
 #include "sysinfo.h"
 
 #ifndef YY_NO_UNPUT
diff --git a/binutils/syslex_wrap.c b/binutils/syslex_wrap.c
new file mode 100644 (file)
index 0000000..e10b5fd
--- /dev/null
@@ -0,0 +1,8 @@
+/* Wrapper source to ensure that config.h is the first header file seen by
+   the compiler.  */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "syslex.c"