This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

report CVS date in --version


This patch started out as simply providing date and version macros for bfd,
but it grew a little.  I've fixed version info printed for a number of
proggies in binutils/, and consolidated the version code in ld.  Dependencies
tweaked to have each Makefile depend on bfd/configure.in because they get
their VERSION define from there.  I also wasted much time converting bfd to
use the string concat macros from include/symcat.h rather than defining its
own.

I'll be running the following at 00:00 UTC from a crontab on my home
machine until someone can set up something similar on sourceware.

#! /bin/sh
cd /src/cygnus/bfd
sed -e 's/DATE.*/DATE '`date +%Y%m%d`/ < version.h > version.h.new
mv -f version.h.new version.h
cvs -Q commit -m "daily update" version.h


bfd/ChangeLog
	* version.h: New file.
	* bfd-in.h: (BFD_VERSION): Substitute bfd_version.
	(BFD_VERSION_DATE): Define.
	(BFD_VERSION_STRING): Define.
	* configure.in: AC_SUBST bfd_version, bfd_version_date and
	bfd_version_string.
	(AC_OUTPUT <bfd-in3.h>): Depend on version.h.
	* bfd-in2.h: Regenerate.
	* configure: Regenerate.
	* Makefile.am: Run "make dep-am"
	* Makefile.in: Regenerate.

	* bfd-in.h: Include "symcat.h".
	(CONCAT4): Redefine as for old CAT4.
	* aout-arm.c: Use equivalent CONCAT* macro in place of CAT* macros.
	Add warning regarding whitespace.
	* aout-cris.c: Likewise.
	* aout-ns32k.c: Likewise.
	* aout-sparcle.c: Likewise.
	* aout-tic30.c: Likewise.
	* aout0.c: Likewise.
	* armnetbsd.c: Likewise.
	* demo64.c: Likewise.
	* elf-bfd.h: Likewise.
	* gen-aout.c: Likewise.
	* host-aout.c: Likewise.
	* hp300bsd.c: Likewise.
	* hp300hpux.c: Likewise.
	* i386aout.c: Likewise.
	* i386bsd.c: Likewise.
	* i386dynix.c: Likewise.
	* i386freebsd.c: Likewise.
	* i386linux.c: Likewise.
	* i386lynx.c: Likewise.
	* i386mach3.c: Likewise.
	* i386netbsd.c: Likewise.
	* libaout.h: Likewise.
	* m68k4knetbsd.c: Likewise.
	* m68klinux.c: Likewise.
	* m68klynx.c: Likewise.
	* m68knetbsd.c: Likewise.
	* m88kmach3.c: Likewise.
	* mipsbsd.c: Likewise.
	* newsos3.c: Likewise.
	* ns32knetbsd.c: Likewise.
	* pc532-mach.c: Likewise.
	* pdp11.c: Likewise.
	* riscix.c: Likewise.
	* sparclinux.c: Likewise.
	* sparclynx.c: Likewise.
	* sparcnetbsd.c: Likewise.
	* sunos.c: Likewise.
	* targets.c: Likewise.
	* vaxnetbsd.c: Likewise.
	* vms-hdr.c: Likewise.

doc/bfd/ChangeLog
	* Makefile.in: Regenerate.

include/nlm/ChangeLog
	* common.h (NLM_CAT, NLM_CAT3): Don't define.
	(NLM_CAT4): Update conditions under which this is defined.  Document
	why CONCAT4 can't be used.

binutils/ChangeLog
	* coffdump.c (PROGRAM_VERSION): Delete.
	(main <'V'>): Call print_version.
	* srconv.c: Likewise.
	* sysdump.c: Likewise.
	* version.c (program_version): Remove.
	(print_version): Use BFD_VERSION_STRING.  Just print the current
	year in copyright message.
	* addr2line.c (program_version): Remove unused declaration.
	* objdump.c (display_target_tables): Use BFD_VERSION_STRING in
	place of BFD_VERSION.
	* Makefile.am (Makefile): Depend on bfd/configure.in
	(cplus-dem.o): Depend on Makefile.
	Run "make dep-am"
	* Makefile.in: Regenerate.

gas/ChangeLog
	* as.c (print_version_id): Use BFD_VERSION_STRING in place of
	BFD_VERSION.
	* Makefile.am (Makefile): Depend on bfd/configure.in
	Run "make dep-am"
	* Makefile.in: Regenerate.

gprof/ChangeLog
	* Makefile.am (Makefile): Depend on bfd/configure.in
	Run "make dep-am"
	* Makefile.in: Regenerate.

ld/ChangeLog
	* ldver.h (ld_program_version): Remove declaration.
	* lexsup.c (parse_args): Move printing of copyright message..
	* ldver.c (ldversion): .. to here.
	Use BFD_VERSION_STRING in place of BFD_VERSION.
	(ld_program_version): Remove.
	* Makefile.am (Makefile): Depend on bfd/configure.in
	Run "make dep-am"
	* Makefile.in: Regenerate.

opcodes/ChangeLog
	* Makefile.am (Makefile): Depend on bfd/configure.in
	Run "make dep-am"
	* Makefile.in: Regenerate.

-- 
Alan Modra

Index: bfd/version.h
===================================================================
RCS file: version.h
diff -N version.h
--- /dev/null	Tue May  5 13:32:27 1998
+++ version.h	Mon Oct  1 22:25:34 2001
@@ -0,0 +1 @@
+#define BFD_VERSION_DATE 20011001
Index: bfd/bfd-in.h
===================================================================
RCS file: /cvs/src/src/bfd/bfd-in.h,v
retrieving revision 1.34
diff -u -p -r1.34 bfd-in.h
--- bfd-in.h	2001/10/01 14:03:35	1.34
+++ bfd-in.h	2001/10/02 05:25:11
@@ -28,8 +28,22 @@ extern "C" {
 #endif
 
 #include "ansidecl.h"
+#include "symcat.h"
+#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
+#ifndef SABER
+/* This hack is to avoid a problem with some strict ANSI C preprocessors.
+   The problem is, "32_" is not a valid preprocessing token, and we don't
+   want extra underscores (e.g., "nlm_32_").  The XCONCAT2 macro will
+   cause the inner CONCAT2 macros to be evaluated first, producing
+   still-valid pp-tokens.  Then the final concatenation can be done.  */
+#undef CONCAT4
+#define CONCAT4(a,b,c,d) XCONCAT2(CONCAT2(a,b),CONCAT2(c,d))
+#endif
+#endif
 
-#define BFD_VERSION  "@VERSION@"
+#define BFD_VERSION @bfd_version@
+#define BFD_VERSION_DATE @bfd_version_date@
+#define BFD_VERSION_STRING @bfd_version_string@
 
 /* The word size used by BFD on the host.  This may be 64 with a 32
    bit target if the host is 64 bit, or if other 64 bit targets have
@@ -430,34 +444,9 @@ extern void bfd_hash_traverse PARAMS ((s
 				       boolean (*) (struct bfd_hash_entry *,
 						    PTR),
 				       PTR info));
-
-/* Semi-portable string concatenation in cpp.
-   The CAT4 hack is to avoid a problem with some strict ANSI C preprocessors.
-   The problem is, "32_" is not a valid preprocessing token, and we don't
-   want extra underscores (e.g., "nlm_32_").  The XCAT2 macro will cause the
-   inner CAT macros to be evaluated first, producing still-valid pp-tokens.
-   Then the final concatenation can be done.  (Sigh.)  */
-#ifndef CAT
-#ifdef SABER
-#define CAT(a,b)	a##b
-#define CAT3(a,b,c)	a##b##c
-#define CAT4(a,b,c,d)	a##b##c##d
-#else
-#if defined(__STDC__) || defined(ALMOST_STDC)
-#define CAT(a,b) a##b
-#define CAT3(a,b,c) a##b##c
-#define XCAT2(a,b)	CAT(a,b)
-#define CAT4(a,b,c,d)	XCAT2(CAT(a,b),CAT(c,d))
-#else
-#define CAT(a,b) a/**/b
-#define CAT3(a,b,c) a/**/b/**/c
-#define CAT4(a,b,c,d)	a/**/b/**/c/**/d
-#endif
-#endif
-#endif
 
 #define COFF_SWAP_TABLE (PTR) &bfd_coff_std_swap_table
-
+
 /* User program access to BFD facilities */
 
 /* Direct I/O routines, for programs which know more about the object
Index: bfd/configure.in
===================================================================
RCS file: /cvs/src/src/bfd/configure.in,v
retrieving revision 1.59
diff -u -p -r1.59 configure.in
--- configure.in	2001/09/29 12:07:00	1.59
+++ configure.in	2001/10/02 05:25:18
@@ -8,7 +8,27 @@ AC_CANONICAL_SYSTEM
 AC_ISC_POSIX
 
 AM_INIT_AUTOMAKE(bfd, 2.11.92)
+# Uncomment the next line to remove the date from the reported bfd version
+#is_release=y
 
+changequote(,)dnl
+bfd_version=`echo "${VERSION}" | sed -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$/\1\2\3\4\5/'`
+changequote([,])dnl
+
+bfd_version_string="\"${VERSION}\""
+bfd_version_date=`sed -e 's/.*DATE //' < ${srcdir}/version.h`
+if test x${is_release} = x; then
+dnl Sad, but we can't use XSTRING here to pick up the date from version.h
+dnl because traditional C doesn't allow it.
+  bfd_version_string="\"${VERSION} ${bfd_version_date}\""
+fi
+dnl Since we need to edit bfd-in3.h to get the date for bfd_version_string,
+dnl we may as well substitute for bfd_version_date too.  That way we don't
+dnl need to #include version.h
+AC_SUBST(bfd_version)
+AC_SUBST(bfd_version_date)
+AC_SUBST(bfd_version_string)
+
 dnl These must be called before AM_PROG_LIBTOOL, because it may want
 dnl to call AC_CHECK_PROG.
 AC_CHECK_TOOL(AR, ar)
@@ -751,6 +771,6 @@ case ${want_mmap}+${ac_cv_func_mmap_fixe
 esac
 
 rm -f doc/config.status
-AC_OUTPUT(Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in,
+AC_OUTPUT(Makefile doc/Makefile bfd-in3.h:bfd-in2.h:version.h po/Makefile.in:po/Make-in,
 [sed -e '/SRC-POTFILES =/r po/SRC-POTFILES' -e '/BLD-POTFILES =/r po/BLD-POTFILES' po/Makefile.in > po/Makefile])
 
Index: bfd/Makefile.am
===================================================================
RCS file: /cvs/src/src/bfd/Makefile.am,v
retrieving revision 1.63
diff -u -p -r1.63 Makefile.am
--- Makefile.am	2001/09/21 02:12:28	1.63
+++ Makefile.am	2001/10/02 05:30:03
@@ -642,6 +642,7 @@ install-data-local: $(BFD_H)
 	$(INSTALL_DATA) $(INCDIR)/ansidecl.h $(DESTDIR)$(includedir)/ansidecl.h
 	$(INSTALL_DATA) $(INCDIR)/bfdlink.h $(DESTDIR)$(includedir)/bfdlink.h
 
+Makefile: $(srcdir)/configure.in
 
 # Have to get rid of DEP1 here so that "$?" later includes all of $(CFILES).
 DEP: dep.sed $(CFILES) $(HFILES) bfd.h
[dependency changes snipped]
Index: bfd/aout-arm.c
===================================================================
RCS file: /cvs/src/src/bfd/aout-arm.c,v
retrieving revision 1.8
diff -u -p -r1.8 aout-arm.c
--- aout-arm.c	2001/09/18 09:57:21	1.8
+++ aout-arm.c	2001/10/02 05:25:09
@@ -21,9 +21,13 @@ Foundation, Inc., 59 Temple Place - Suit
 
 #include "bfd.h"
 #include "sysdep.h"
+
 /* Avoid multiple defininitions from aoutx if supporting standarad a.out
    as well as our own.  */
-#define NAME(x,y) CAT3(aoutarm,_32_,y)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define NAME(x,y) CONCAT3 (aoutarm,_32_,y)
 
 #define N_TXTADDR(x)						\
   ((N_MAGIC (x) == NMAGIC)					\
@@ -39,7 +43,7 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_arm
 
-#define MY(OP) CAT(aoutarm_,OP)
+#define MY(OP) CONCAT2 (aoutarm_,OP)
 #define N_BADMAG(x) ((((x).a_info & ~007200) != ZMAGIC) && \
                      (((x).a_info & ~006000) != OMAGIC) && \
                      ((x).a_info != NMAGIC))
Index: bfd/aout-cris.c
===================================================================
RCS file: /cvs/src/src/bfd/aout-cris.c,v
retrieving revision 1.7
diff -u -p -r1.7 aout-cris.c
--- aout-cris.c	2001/09/20 23:30:33	1.7
+++ aout-cris.c	2001/10/02 05:25:09
@@ -64,10 +64,11 @@ Foundation, Inc., 59 Temple Place - Suit
 /* The definition here seems not used; just provided as a convention.  */
 #define DEFAULT_ARCH bfd_arch_cris
 
-/* ??? Spacing might be essential for the parameters in this macro.
-   Do Not Change.  */
-#define MY(OP) CAT (cris_aout_,OP)
-#define NAME(x,y) CAT3(cris_aout,_32_,y)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (cris_aout_,OP)
+#define NAME(x, y) CONCAT3 (cris_aout,_32_,y)
 
 #include "bfd.h"
 
Index: bfd/aout-ns32k.c
===================================================================
RCS file: /cvs/src/src/bfd/aout-ns32k.c,v
retrieving revision 1.7
diff -u -p -r1.7 aout-ns32k.c
--- aout-ns32k.c	2001/09/18 09:57:21	1.7
+++ aout-ns32k.c	2001/10/02 05:25:09
@@ -25,7 +25,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "aout/aout64.h"
 #include "ns32k.h"
 
-#define MYNS(OP) CAT(ns32kaout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MYNS(OP) CONCAT2 (ns32kaout_,OP)
+
 reloc_howto_type *
 MYNS(bfd_reloc_type_lookup)
   PARAMS((bfd *abfd AND
@@ -37,7 +41,7 @@ MYNS(write_object_contents)
 
 /* Avoid multiple definitions from aoutx if supporting
    standard a.out format(s) as well as this one.  */
-#define NAME(x,y) CAT3(ns32kaout,_32_,y)
+#define NAME(x,y) CONCAT3 (ns32kaout,_32_,y)
 
 void bfd_ns32k_arch PARAMS ((void));
 
Index: bfd/aout-sparcle.c
===================================================================
RCS file: /cvs/src/src/bfd/aout-sparcle.c,v
retrieving revision 1.2
diff -u -p -r1.2 aout-sparcle.c
--- aout-sparcle.c	2001/03/08 21:03:56	1.2
+++ aout-sparcle.c	2001/10/02 05:25:09
@@ -1,5 +1,5 @@
 /* BFD backend for sparc little-endian aout binaries.
-   Copyright 1996 Free Software Foundation, Inc.
+   Copyright 1996, 2001 Free Software Foundation, Inc.
    Written by Cygnus Support.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -19,7 +19,11 @@ along with this program; if not, write t
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #define TARGETNAME "a.out-sparc-little"
-#define MY(OP) CAT(sparcle_aout_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (sparcle_aout_,OP)
 
 #include "bfd.h"
 #include "bfdlink.h"
Index: bfd/aout-tic30.c
===================================================================
RCS file: /cvs/src/src/bfd/aout-tic30.c,v
retrieving revision 1.12
diff -u -p -r1.12 aout-tic30.c
--- aout-tic30.c	2001/09/18 09:57:21	1.12
+++ aout-tic30.c	2001/10/02 05:25:10
@@ -28,9 +28,12 @@
 #define DEFAULT_ARCH bfd_arch_tic30
 #define ARCH_SIZE 32
 
-#define MY(OP) CAT(tic30_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (tic30_aout_,OP)
 #define TARGETNAME "a.out-tic30"
-#define NAME(x,y) CAT3(tic30_aout,_32_,y)
+#define NAME(x,y) CONCAT3 (tic30_aout,_32_,y)
 
 #include "bfd.h"
 #include "sysdep.h"
Index: bfd/aout0.c
===================================================================
RCS file: /cvs/src/src/bfd/aout0.c,v
retrieving revision 1.2
diff -u -p -r1.2 aout0.c
--- aout0.c	2001/03/08 21:03:56	1.2
+++ aout0.c	2001/10/02 05:25:10
@@ -1,5 +1,5 @@
 /* BFD backend for SunOS style a.out with flags set to 0
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -20,7 +20,11 @@ along with this program; if not, write t
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #define TARGETNAME "a.out-zero-big"
-#define MY(OP) CAT(aout0_big_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (aout0_big_,OP)
 
 #include "bfd.h"
 
Index: bfd/armnetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/armnetbsd.c,v
retrieving revision 1.3
diff -u -p -r1.3 armnetbsd.c
--- armnetbsd.c	2001/03/08 21:03:57	1.3
+++ armnetbsd.c	2001/10/02 05:25:10
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/ARM a.out-ish binaries.
-   Copyright 1999, 2000 Free Software Foundation, Inc.
+   Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -27,12 +27,16 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_MID 		M_ARM6_NETBSD
 /*#define MACHTYPE_OK(mtype) ((mtype) == M_ARM6_NETBSD)*/
 
-#define MY(OP) 			CAT (armnetbsd_, OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) 			CONCAT2 (armnetbsd_, OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME 		"a.out-arm-netbsd"
 
 #if 0
-#define NAME(x,y) CAT3(aoutarm,_32_,y)
+#define NAME(x,y) CONCAT3 (aoutarm,_32_,y)
 
 #define aoutarm_32_get_section_contents aout_32_get_section_contents
 
Index: bfd/demo64.c
===================================================================
RCS file: /cvs/src/src/bfd/demo64.c,v
retrieving revision 1.2
diff -u -p -r1.2 demo64.c
--- demo64.c	2001/03/08 21:03:58	1.2
+++ demo64.c	2001/10/02 05:25:18
@@ -1,5 +1,6 @@
 /* BFD backend for demonstration 64-bit a.out binaries.
-   Copyright 1990, 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1993, 1994, 2001
+   Free Software Foundation, Inc.
    Written by Cygnus Support.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -19,6 +20,11 @@ along with this program; if not, write t
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #define ARCH_SIZE 64
-#define MY(OP) CAT(demo_64_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (demo_64_,OP)
+
 #define TARGETNAME  "demo64"
 #include "aoutf1.h"
Index: bfd/elf-bfd.h
===================================================================
RCS file: /cvs/src/src/bfd/elf-bfd.h,v
retrieving revision 1.47
diff -u -p -r1.47 elf-bfd.h
--- elf-bfd.h	2001/09/29 06:21:58	1.47
+++ elf-bfd.h	2001/10/02 05:25:19
@@ -33,17 +33,20 @@ Foundation, Inc., 59 Temple Place - Suit
 #define NUM_SHDR_ENTRIES(shdr) ((shdr)->sh_size / (shdr)->sh_entsize)
 
 /* If size isn't specified as 64 or 32, NAME macro should fail.  */
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
 #ifndef NAME
 #if ARCH_SIZE==64
-#define NAME(x,y) CAT4(x,64,_,y)
+#define NAME(x,y) CONCAT4 (x,64,_,y)
 #endif
 #if ARCH_SIZE==32
-#define NAME(x,y) CAT4(x,32,_,y)
+#define NAME(x,y) CONCAT4 (x,32,_,y)
 #endif
 #endif
 
 #ifndef NAME
-#define NAME(x,y) CAT4(x,NOSIZE,_,y)
+#define NAME(x,y) CONCAT4 (x,NOSIZE,_,y)
 #endif
 
 #define ElfNAME(X)	NAME(Elf,X)
Index: bfd/gen-aout.c
===================================================================
RCS file: /cvs/src/src/bfd/gen-aout.c,v
retrieving revision 1.2
diff -u -p -r1.2 gen-aout.c
--- gen-aout.c	2001/03/08 21:04:01	1.2
+++ gen-aout.c	2001/10/02 05:25:24
@@ -1,5 +1,5 @@
 /* Generate parameters for an a.out system.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -87,9 +87,12 @@ main (argc, argv)
       fprintf (stderr, _("         fix DEFAULT_ARCH in the output file yourself\n"));
       arch = "unknown";
     }
-  printf("#define DEFAULT_ARCH bfd_arch_%s\n", arch);
+  printf("#define DEFAULT_ARCH bfd_arch_%s\n\n", arch);
 
-  printf("\n#define MY(OP) CAT(%s_,OP)\n", target);
+  printf("/* Do not \"beautify\" the CONCAT* macro args.  Traditional C will not");
+  printf("   remove whitespace added here, and thus will fail to concatenate");
+  printf("   the tokens.  */");
+  printf("\n#define MY(OP) CONCAT2 (%s_,OP)\n\n", target);
   printf("#define TARGETNAME \"a.out-%s\"\n\n", target);
 
   printf("#include \"bfd.h\"\n");
Index: bfd/host-aout.c
===================================================================
RCS file: /cvs/src/src/bfd/host-aout.c,v
retrieving revision 1.2
diff -u -p -r1.2 host-aout.c
--- host-aout.c	2001/03/08 21:04:01	1.2
+++ host-aout.c	2001/10/02 05:25:24
@@ -1,5 +1,6 @@
 /* BFD backend for local host's a.out binaries
-   Copyright 1990, 1991, 1992, 1994, 1995 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1994, 1995, 2001
+   Free Software Foundation, Inc.
    Written by Cygnus Support.  Probably John Gilmore's fault.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -77,7 +78,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #endif
 #endif /* HOST_MACHINE_ARCH */
 
-#define MY(OP) CAT(host_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (host_aout_,OP)
 #define TARGETNAME "a.out"
 
 #include "aout-target.h"
Index: bfd/hp300bsd.c
===================================================================
RCS file: /cvs/src/src/bfd/hp300bsd.c,v
retrieving revision 1.2
diff -u -p -r1.2 hp300bsd.c
--- hp300bsd.c	2001/03/08 21:04:01	1.2
+++ hp300bsd.c	2001/10/02 05:25:24
@@ -1,5 +1,5 @@
 /* BFD back-end for HP 9000/300 (68000-based) machines running BSD Unix.
-   Copyright 1992, 1994, 1995 Free Software Foundation, Inc.
+   Copyright 1992, 1994, 1995, 2001 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -27,7 +27,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_m68k
 
-#define MY(OP) CAT(hp300bsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (hp300bsd_,OP)
 #define TARGETNAME "a.out-hp300bsd"
 
 #include "bfd.h"
Index: bfd/hp300hpux.c
===================================================================
RCS file: /cvs/src/src/bfd/hp300hpux.c,v
retrieving revision 1.7
diff -u -p -r1.7 hp300hpux.c
--- hp300hpux.c	2001/09/18 09:57:24	1.7
+++ hp300hpux.c	2001/10/02 05:25:24
@@ -100,8 +100,12 @@ Foundation, Inc., 59 Temple Place - Suit
    This should also be fixed.  */
 
 #define TARGETNAME "a.out-hp300hpux"
-#define MY(OP) CAT(hp300hpux_,OP)
 
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (hp300hpux_,OP)
+
 #define external_exec hp300hpux_exec_bytes
 #define external_nlist hp300hpux_nlist_bytes
 
@@ -123,7 +127,7 @@ Foundation, Inc., 59 Temple Place - Suit
 /* provide overrides for routines in this file */
 /***********************************************/
 /* these don't use MY because that causes problems within JUMP_TABLE
-   (CAT winds up being expanded recursively, which ANSI C compilers
+   (CONCAT2 winds up being expanded recursively, which ANSI C compilers
    will not do).  */
 #define MY_get_symtab hp300hpux_get_symtab
 #define MY_get_symtab_upper_bound hp300hpux_get_symtab_upper_bound
@@ -181,7 +185,7 @@ Foundation, Inc., 59 Temple Place - Suit
 #define HP_RLENGTH_LONG		0x02
 #define HP_RLENGTH_ALIGN	0x03
 
-#define NAME(x,y) CAT3(hp300hpux,_32_,y)
+#define NAME(x,y) CONCAT3 (hp300hpux,_32_,y)
 #define ARCH_SIZE 32
 
 /* aoutx.h requires definitions for BMAGIC and QMAGIC.  */
Index: bfd/i386aout.c
===================================================================
RCS file: /cvs/src/src/bfd/i386aout.c,v
retrieving revision 1.4
diff -u -p -r1.4 i386aout.c
--- i386aout.c	2001/09/18 09:57:25	1.4
+++ i386aout.c	2001/10/02 05:25:24
@@ -41,7 +41,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE 0x400000
 #define DEFAULT_ARCH bfd_arch_i386
 
-#define MY(OP) CAT(i386aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386aout_,OP)
 #define TARGETNAME "a.out-i386"
 #define NO_WRITE_HEADER_KLUDGE 1
 
Index: bfd/i386bsd.c
===================================================================
RCS file: /cvs/src/src/bfd/i386bsd.c,v
retrieving revision 1.2
diff -u -p -r1.2 i386bsd.c
--- i386bsd.c	2001/03/08 21:04:01	1.2
+++ i386bsd.c	2001/10/02 05:25:24
@@ -1,5 +1,6 @@
 /* BFD back-end for i386 a.out binaries under BSD.
-   Copyright 1990, 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1993, 1994, 2001
+   Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -35,7 +36,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_ARCH	bfd_arch_i386
 #define MACHTYPE_OK(mtype) ((mtype) == M_386 || (mtype) == M_UNKNOWN)
 
-#define MY(OP) CAT(i386bsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386bsd_,OP)
 #define TARGETNAME "a.out-i386-bsd"
 
 #include "bfd.h"
Index: bfd/i386dynix.c
===================================================================
RCS file: /cvs/src/src/bfd/i386dynix.c,v
retrieving revision 1.3
diff -u -p -r1.3 i386dynix.c
--- i386dynix.c	2001/09/18 09:57:25	1.3
+++ i386dynix.c	2001/10/02 05:25:24
@@ -31,9 +31,12 @@ Foundation, Inc., 59 Temple Place - Suit
 #define DEFAULT_ARCH	bfd_arch_i386
 #define MACHTYPE_OK(mtype) ((mtype) == M_386 || (mtype) == M_UNKNOWN)
 
-#define MY(OP) CAT(i386dynix_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386dynix_,OP)
 #define TARGETNAME "a.out-i386-dynix"
-#define NAME(x,y) CAT3(i386dynix,_32_,y)
+#define NAME(x,y) CONCAT3 (i386dynix,_32_,y)
 #define ARCH_SIZE 32
 #define NAME_swap_exec_header_in NAME(i386dynix_32_,swap_exec_header_in)
 #define MY_get_section_contents aout_32_get_section_contents
Index: bfd/i386freebsd.c
===================================================================
RCS file: /cvs/src/src/bfd/i386freebsd.c,v
retrieving revision 1.2
diff -u -p -r1.2 i386freebsd.c
--- i386freebsd.c	2001/03/08 21:04:01	1.2
+++ i386freebsd.c	2001/10/02 05:25:24
@@ -1,5 +1,5 @@
 /* BFD back-end for FreeBSD/386 a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1996 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1996, 2001 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -26,7 +26,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_ARCH	bfd_arch_i386
 #define MACHTYPE_OK(mtype) ((mtype) == M_386_NETBSD || (mtype) == M_UNKNOWN)
 
-#define MY(OP) CAT(i386freebsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386freebsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-i386-freebsd"
 
Index: bfd/i386linux.c
===================================================================
RCS file: /cvs/src/src/bfd/i386linux.c,v
retrieving revision 1.4
diff -u -p -r1.4 i386linux.c
--- i386linux.c	2001/09/18 09:57:25	1.4
+++ i386linux.c	2001/10/02 05:25:25
@@ -36,7 +36,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "libaout.h"           /* BFD a.out internal data structures */
 
 #define DEFAULT_ARCH bfd_arch_i386
-#define MY(OP) CAT(i386linux_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386linux_,OP)
 #define TARGETNAME "a.out-i386-linux"
 
 extern const bfd_target MY(vec);
Index: bfd/i386lynx.c
===================================================================
RCS file: /cvs/src/src/bfd/i386lynx.c,v
retrieving revision 1.5
diff -u -p -r1.5 i386lynx.c
--- i386lynx.c	2001/09/18 09:57:25	1.5
+++ i386lynx.c	2001/10/02 05:25:25
@@ -26,7 +26,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_i386
 
-#define MY(OP) CAT(i386lynx_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386lynx_aout_,OP)
 #define TARGETNAME "a.out-i386-lynx"
 
 #include "bfd.h"
Index: bfd/i386mach3.c
===================================================================
RCS file: /cvs/src/src/bfd/i386mach3.c,v
retrieving revision 1.4
diff -u -p -r1.4 i386mach3.c
--- i386mach3.c	2001/09/18 09:57:25	1.4
+++ i386mach3.c	2001/10/02 05:25:25
@@ -43,7 +43,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "libaout.h"           /* BFD a.out internal data structures */
 
 #define DEFAULT_ARCH bfd_arch_i386
-#define MY(OP) CAT(i386mach3_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386mach3_,OP)
 #define TARGETNAME "a.out-mach3"
 
 static boolean MY (set_sizes) PARAMS ((bfd *));
Index: bfd/i386netbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/i386netbsd.c,v
retrieving revision 1.2
diff -u -p -r1.2 i386netbsd.c
--- i386netbsd.c	2001/03/08 21:04:01	1.2
+++ i386netbsd.c	2001/10/02 05:25:25
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/386 a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1998
+   Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1998, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -27,7 +27,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_ARCH	bfd_arch_i386
 #define	DEFAULT_MID 	M_386_NETBSD
 
-#define MY(OP) CAT(i386netbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (i386netbsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-i386-netbsd"
 
Index: bfd/libaout.h
===================================================================
RCS file: /cvs/src/src/bfd/libaout.h,v
retrieving revision 1.6
diff -u -p -r1.6 libaout.h
--- libaout.h	2001/09/18 09:57:25	1.6
+++ libaout.h	2001/10/02 05:25:26
@@ -78,6 +78,9 @@ Foundation, Inc., 59 Temple Place - Suit
 
 /* Parameterize the a.out code based on whether it is being built
    for a 32-bit architecture or a 64-bit architecture.  */
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
 #if ARCH_SIZE==64
 #define GET_WORD H_GET_64
 #define GET_SWORD H_GET_S64
@@ -85,9 +88,9 @@ Foundation, Inc., 59 Temple Place - Suit
 #define PUT_WORD H_PUT_64
 #define PUT_MAGIC H_PUT_32
 #ifndef NAME
-#define NAME(x,y) CAT3(x,_64_,y)
+#define NAME(x,y) CONCAT3 (x,_64_,y)
 #endif
-#define JNAME(x) CAT(x,_64)
+#define JNAME(x) CONCAT2 (x,_64)
 #define BYTES_IN_WORD 8
 #else
 #if ARCH_SIZE==16
@@ -97,9 +100,9 @@ Foundation, Inc., 59 Temple Place - Suit
 #define PUT_WORD H_PUT_16
 #define PUT_MAGIC H_PUT_16
 #ifndef NAME
-#define NAME(x,y) CAT3(x,_16_,y)
+#define NAME(x,y) CONCAT3 (x,_16_,y)
 #endif
-#define JNAME(x) CAT(x,_16)
+#define JNAME(x) CONCAT2 (x,_16)
 #define BYTES_IN_WORD 2
 #else /* ARCH_SIZE == 32 */
 #define GET_WORD H_GET_32
@@ -108,9 +111,9 @@ Foundation, Inc., 59 Temple Place - Suit
 #define PUT_WORD H_PUT_32
 #define PUT_MAGIC H_PUT_32
 #ifndef NAME
-#define NAME(x,y) CAT3(x,_32_,y)
+#define NAME(x,y) CONCAT3 (x,_32_,y)
 #endif
-#define JNAME(x) CAT(x,_32)
+#define JNAME(x) CONCAT2 (x,_32)
 #define BYTES_IN_WORD 4
 #endif /* ARCH_SIZE==32 */
 #endif /* ARCH_SIZE==64 */
Index: bfd/m68k4knetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/m68k4knetbsd.c,v
retrieving revision 1.2
diff -u -p -r1.2 m68k4knetbsd.c
--- m68k4knetbsd.c	2001/03/08 21:04:01	1.2
+++ m68k4knetbsd.c	2001/10/02 05:25:26
@@ -1,5 +1,6 @@
 /* BFD back-end for NetBSD/m68k a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1995, 1998 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1995, 1998, 2001
+   Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -25,7 +26,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define DEFAULT_ARCH	bfd_arch_m68k
 #define DEFAULT_MID 	M_68K4K_NETBSD
 
-#define MY(OP) CAT(m68k4knetbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (m68k4knetbsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-m68k4k-netbsd"
 
Index: bfd/m68klinux.c
===================================================================
RCS file: /cvs/src/src/bfd/m68klinux.c,v
retrieving revision 1.6
diff -u -p -r1.6 m68klinux.c
--- m68klinux.c	2001/09/18 09:57:25	1.6
+++ m68klinux.c	2001/10/02 05:25:27
@@ -37,7 +37,11 @@ Foundation, Inc., 59 Temple Place - Suit
 
 #define TARGET_IS_BIG_ENDIAN_P
 #define DEFAULT_ARCH bfd_arch_m68k
-#define MY(OP) CAT(m68klinux_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (m68klinux_,OP)
 #define TARGETNAME "a.out-m68k-linux"
 
 extern const bfd_target MY(vec);
Index: bfd/m68klynx.c
===================================================================
RCS file: /cvs/src/src/bfd/m68klynx.c,v
retrieving revision 1.2
diff -u -p -r1.2 m68klynx.c
--- m68klynx.c	2001/03/08 21:04:01	1.2
+++ m68klynx.c	2001/10/02 05:25:27
@@ -1,5 +1,5 @@
 /* BFD back-end for m68k binaries under LynxOS.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -26,7 +26,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_m68k
 
-#define MY(OP) CAT(m68klynx_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (m68klynx_aout_,OP)
 #define TARGETNAME "a.out-m68k-lynx"
 
 #include "bfd.h"
Index: bfd/m68knetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/m68knetbsd.c,v
retrieving revision 1.3
diff -u -p -r1.3 m68knetbsd.c
--- m68knetbsd.c	2001/03/08 21:04:01	1.3
+++ m68knetbsd.c	2001/10/02 05:25:27
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/m68k a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000
+   Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -28,7 +28,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define DEFAULT_ARCH	bfd_arch_m68k
 #define DEFAULT_MID 	M_68K_NETBSD
 
-#define MY(OP) CAT(m68knetbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (m68knetbsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-m68k-netbsd"
 
Index: bfd/m88kmach3.c
===================================================================
RCS file: /cvs/src/src/bfd/m88kmach3.c,v
retrieving revision 1.2
diff -u -p -r1.2 m88kmach3.c
--- m88kmach3.c	2001/03/08 21:04:01	1.2
+++ m88kmach3.c	2001/10/02 05:25:27
@@ -1,5 +1,6 @@
 /* BFD back-end for Motorola m88k a.out (Mach 3) binaries.
-   Copyright 1990, 1991, 1993, 1994, 1995 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1993, 1994, 1995, 2001
+   Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -32,7 +33,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "libaout.h"
 
 #define DEFAULT_ARCH bfd_arch_m88k
-#define MY(OP) CAT(m88kmach3_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (m88kmach3_,OP)
 #define TARGETNAME "a.out-m88k-mach3"
 
 #include "aout-target.h"
Index: bfd/mipsbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/mipsbsd.c,v
retrieving revision 1.7
diff -u -p -r1.7 mipsbsd.c
--- mipsbsd.c	2001/09/18 09:57:25	1.7
+++ mipsbsd.c	2001/10/02 05:25:27
@@ -36,7 +36,10 @@ Foundation, Inc., 59 Temple Place - Suit
 			    || (mtype) == M_MIPS1 || (mtype) == M_MIPS2)
 #define MY_symbol_leading_char '\0'
 
-#define MY(OP) CAT(mipsbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (mipsbsd_,OP)
 
 #include "bfd.h"
 #include "sysdep.h"
@@ -52,7 +55,7 @@ static void MY(choose_reloc_size) PARAMS
 #define MY_write_object_contents MY(write_object_contents)
 static boolean MY(write_object_contents) PARAMS ((bfd *abfd));
 
-/* We can't use MY(x) here because it leads to a recursive call to CAT
+/* We can't use MY(x) here because it leads to a recursive call to CONCAT2
    when expanded inside JUMP_TABLE.  */
 #define MY_bfd_reloc_type_lookup mipsbsd_reloc_howto_type_lookup
 #define MY_canonicalize_reloc mipsbsd_canonicalize_reloc
Index: bfd/newsos3.c
===================================================================
RCS file: /cvs/src/src/bfd/newsos3.c,v
retrieving revision 1.3
diff -u -p -r1.3 newsos3.c
--- newsos3.c	2001/03/08 21:04:01	1.3
+++ newsos3.c	2001/10/02 05:25:27
@@ -1,5 +1,6 @@
 /* BFD back-end for NewsOS3 (Sony, 68k) binaries.
-   Copyright 1990, 1991, 1994, 1995, 2000 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1994, 1995, 2000, 2001
+   Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -21,7 +22,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	SEGMENT_SIZE	TARGET_PAGE_SIZE
 #define TEXT_START_ADDR 0
 #define BYTES_IN_WORD 4
-#define MY(OP) CAT(newsos3_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (newsos3_,OP)
 #define TARGETNAME "a.out-newsos3"
 #define ENTRY_CAN_BE_ZERO
 #define N_SHARED_LIB(x) 0 /* Avoids warning when compiled with -Wall.  */
Index: bfd/ns32knetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/ns32knetbsd.c,v
retrieving revision 1.3
diff -u -p -r1.3 ns32knetbsd.c
--- ns32knetbsd.c	2001/03/08 21:04:01	1.3
+++ ns32knetbsd.c	2001/10/02 05:25:27
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/ns32k a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1994, 1995, 1998, 2000
+   Copyright 1990, 1991, 1992, 1994, 1995, 1998, 2000, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -27,9 +27,12 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_ARCH	bfd_arch_ns32k
 #define	DEFAULT_MID 	M_532_NETBSD
 
-#define MY(OP) CAT(pc532netbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (pc532netbsd_,OP)
 
-#define NAME(x,y) CAT3(ns32kaout,_32_,y)
+#define NAME(x,y) CONCAT3 (ns32kaout,_32_,y)
 
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-ns32k-netbsd"
Index: bfd/pc532-mach.c
===================================================================
RCS file: /cvs/src/src/bfd/pc532-mach.c,v
retrieving revision 1.5
diff -u -p -r1.5 pc532-mach.c
--- pc532-mach.c	2001/09/18 09:57:25	1.5
+++ pc532-mach.c	2001/10/02 05:25:27
@@ -50,10 +50,13 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_ns32k
 
-#define MY(OP) CAT(pc532machaout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (pc532machaout_,OP)
 
 /* Must be the same as aout-ns32k.c */
-#define NAME(x,y) CAT3(ns32kaout,_32_,y)
+#define NAME(x,y) CONCAT3 (ns32kaout,_32_,y)
 
 #define TARGETNAME "a.out-pc532-mach"
 
Index: bfd/pdp11.c
===================================================================
RCS file: /cvs/src/src/bfd/pdp11.c,v
retrieving revision 1.8
diff -u -p -r1.8 pdp11.c
--- pdp11.c	2001/09/20 23:30:37	1.8
+++ pdp11.c	2001/10/02 05:25:30
@@ -41,7 +41,11 @@
 #define	DEFAULT_ARCH	bfd_arch_pdp11
 #define	DEFAULT_MID 	M_PDP11
 
-#define MY(OP) CAT(pdp11_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (pdp11_aout_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-pdp11"
 
Index: bfd/riscix.c
===================================================================
RCS file: /cvs/src/src/bfd/riscix.c,v
retrieving revision 1.7
diff -u -p -r1.7 riscix.c
--- riscix.c	2001/09/18 09:57:26	1.7
+++ riscix.c	2001/10/02 05:25:31
@@ -83,7 +83,10 @@ Foundation, Inc., 59 Temple Place - Suit
 #define SEGMENT_SIZE TARGET_PAGE_SIZE
 #define DEFAULT_ARCH bfd_arch_arm
 
-#define MY(OP) CAT(riscix_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (riscix_,OP)
 #define TARGETNAME "a.out-riscix"
 #define N_BADMAG(x) ((((x).a_info & ~007200) != ZMAGIC) && \
                      (((x).a_info & ~006000) != OMAGIC) && \
Index: bfd/sparclinux.c
===================================================================
RCS file: /cvs/src/src/bfd/sparclinux.c,v
retrieving revision 1.5
diff -u -p -r1.5 sparclinux.c
--- sparclinux.c	2001/09/18 09:57:26	1.5
+++ sparclinux.c	2001/10/02 05:25:32
@@ -37,7 +37,10 @@ USA.  */
 #include "libaout.h"           /* BFD a.out internal data structures */
 
 #define DEFAULT_ARCH bfd_arch_sparc
-#define MY(OP) CAT(sparclinux_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (sparclinux_,OP)
 #define TARGETNAME "a.out-sparc-linux"
 
 extern const bfd_target MY(vec);
Index: bfd/sparclynx.c
===================================================================
RCS file: /cvs/src/src/bfd/sparclynx.c,v
retrieving revision 1.5
diff -u -p -r1.5 sparclynx.c
--- sparclynx.c	2001/09/18 09:57:26	1.5
+++ sparclynx.c	2001/10/02 05:25:32
@@ -29,7 +29,10 @@ Foundation, Inc., 59 Temple Place - Suit
 
 #endif
 
-#define MY(OP) CAT (sparclynx_aout_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (sparclynx_aout_,OP)
 #define TARGETNAME "a.out-sparc-lynx"
 
 #include "bfd.h"
Index: bfd/sparcnetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/sparcnetbsd.c,v
retrieving revision 1.3
diff -u -p -r1.3 sparcnetbsd.c
--- sparcnetbsd.c	2001/03/08 21:04:02	1.3
+++ sparcnetbsd.c	2001/10/02 05:25:32
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/sparc a.out-ish binaries.
-   Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000
+   Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000, 2001
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -28,7 +28,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define DEFAULT_ARCH	bfd_arch_sparc
 #define DEFAULT_MID 	M_SPARC_NETBSD
 
-#define MY(OP) CAT(sparcnetbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (sparcnetbsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-sparc-netbsd"
 
Index: bfd/sunos.c
===================================================================
RCS file: /cvs/src/src/bfd/sunos.c,v
retrieving revision 1.5
diff -u -p -r1.5 sunos.c
--- sunos.c	2001/09/18 09:57:26	1.5
+++ sunos.c	2001/10/02 05:25:34
@@ -20,7 +20,11 @@ along with this program; if not, write t
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #define TARGETNAME "a.out-sunos-big"
-#define MY(OP) CAT(sunos_big_,OP)
+
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (sunos_big_,OP)
 
 #include "bfd.h"
 #include "bfdlink.h"
Index: bfd/targets.c
===================================================================
RCS file: /cvs/src/src/bfd/targets.c,v
retrieving revision 1.46
diff -u -p -r1.46 targets.c
--- targets.c	2001/09/18 09:57:26	1.46
+++ targets.c	2001/10/02 05:25:34
@@ -250,12 +250,15 @@ BFD_JUMP_TABLE macros.
 
 .
 .  {* Generic entry points.  *}
-.#define BFD_JUMP_TABLE_GENERIC(NAME)\
-.CAT(NAME,_close_and_cleanup),\
-.CAT(NAME,_bfd_free_cached_info),\
-.CAT(NAME,_new_section_hook),\
-.CAT(NAME,_get_section_contents),\
-.CAT(NAME,_get_section_contents_in_window)
+Do not "beautify" the CONCAT* macro args.  Traditional C will not
+remove whitespace added here, and thus will fail to concatenate
+the tokens.
+.#define BFD_JUMP_TABLE_GENERIC(NAME) \
+.CONCAT2 (NAME,_close_and_cleanup), \
+.CONCAT2 (NAME,_bfd_free_cached_info), \
+.CONCAT2 (NAME,_new_section_hook), \
+.CONCAT2 (NAME,_get_section_contents), \
+.CONCAT2 (NAME,_get_section_contents_in_window)
 .
 .  {* Called when the BFD is being closed to do any necessary cleanup.  *}
 .  boolean  (*_close_and_cleanup) PARAMS ((bfd *));
@@ -270,13 +273,13 @@ BFD_JUMP_TABLE macros.
 .    PARAMS ((bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type));
 .
 .  {* Entry points to copy private data.  *}
-.#define BFD_JUMP_TABLE_COPY(NAME)\
-.CAT(NAME,_bfd_copy_private_bfd_data),\
-.CAT(NAME,_bfd_merge_private_bfd_data),\
-.CAT(NAME,_bfd_copy_private_section_data),\
-.CAT(NAME,_bfd_copy_private_symbol_data),\
-.CAT(NAME,_bfd_set_private_flags),\
-.CAT(NAME,_bfd_print_private_bfd_data)\
+.#define BFD_JUMP_TABLE_COPY(NAME) \
+.CONCAT2 (NAME,_bfd_copy_private_bfd_data), \
+.CONCAT2 (NAME,_bfd_merge_private_bfd_data), \
+.CONCAT2 (NAME,_bfd_copy_private_section_data), \
+.CONCAT2 (NAME,_bfd_copy_private_symbol_data), \
+.CONCAT2 (NAME,_bfd_set_private_flags), \
+.CONCAT2 (NAME,_bfd_print_private_bfd_data) \
 .  {* Called to copy BFD general private data from one object file
 .     to another.  *}
 .  boolean  (*_bfd_copy_private_bfd_data) PARAMS ((bfd *, bfd *));
@@ -298,26 +301,26 @@ BFD_JUMP_TABLE macros.
 .  boolean  (*_bfd_print_private_bfd_data) PARAMS ((bfd *, PTR));
 .
 .  {* Core file entry points.  *}
-.#define BFD_JUMP_TABLE_CORE(NAME)\
-.CAT(NAME,_core_file_failing_command),\
-.CAT(NAME,_core_file_failing_signal),\
-.CAT(NAME,_core_file_matches_executable_p)
+.#define BFD_JUMP_TABLE_CORE(NAME) \
+.CONCAT2 (NAME,_core_file_failing_command), \
+.CONCAT2 (NAME,_core_file_failing_signal), \
+.CONCAT2 (NAME,_core_file_matches_executable_p)
 .  char *   (*_core_file_failing_command) PARAMS ((bfd *));
 .  int      (*_core_file_failing_signal) PARAMS ((bfd *));
 .  boolean  (*_core_file_matches_executable_p) PARAMS ((bfd *, bfd *));
 .
 .  {* Archive entry points.  *}
-.#define BFD_JUMP_TABLE_ARCHIVE(NAME)\
-.CAT(NAME,_slurp_armap),\
-.CAT(NAME,_slurp_extended_name_table),\
-.CAT(NAME,_construct_extended_name_table),\
-.CAT(NAME,_truncate_arname),\
-.CAT(NAME,_write_armap),\
-.CAT(NAME,_read_ar_hdr),\
-.CAT(NAME,_openr_next_archived_file),\
-.CAT(NAME,_get_elt_at_index),\
-.CAT(NAME,_generic_stat_arch_elt),\
-.CAT(NAME,_update_armap_timestamp)
+.#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
+.CONCAT2 (NAME,_slurp_armap), \
+.CONCAT2 (NAME,_slurp_extended_name_table), \
+.CONCAT2 (NAME,_construct_extended_name_table), \
+.CONCAT2 (NAME,_truncate_arname), \
+.CONCAT2 (NAME,_write_armap), \
+.CONCAT2 (NAME,_read_ar_hdr), \
+.CONCAT2 (NAME,_openr_next_archived_file), \
+.CONCAT2 (NAME,_get_elt_at_index), \
+.CONCAT2 (NAME,_generic_stat_arch_elt), \
+.CONCAT2 (NAME,_update_armap_timestamp)
 .  boolean  (*_bfd_slurp_armap) PARAMS ((bfd *));
 .  boolean  (*_bfd_slurp_extended_name_table) PARAMS ((bfd *));
 .  boolean  (*_bfd_construct_extended_name_table)
@@ -333,18 +336,18 @@ BFD_JUMP_TABLE macros.
 .  boolean  (*_bfd_update_armap_timestamp) PARAMS ((bfd *));
 .
 .  {* Entry points used for symbols.  *}
-.#define BFD_JUMP_TABLE_SYMBOLS(NAME)\
-.CAT(NAME,_get_symtab_upper_bound),\
-.CAT(NAME,_get_symtab),\
-.CAT(NAME,_make_empty_symbol),\
-.CAT(NAME,_print_symbol),\
-.CAT(NAME,_get_symbol_info),\
-.CAT(NAME,_bfd_is_local_label_name),\
-.CAT(NAME,_get_lineno),\
-.CAT(NAME,_find_nearest_line),\
-.CAT(NAME,_bfd_make_debug_symbol),\
-.CAT(NAME,_read_minisymbols),\
-.CAT(NAME,_minisymbol_to_symbol)
+.#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
+.CONCAT2 (NAME,_get_symtab_upper_bound), \
+.CONCAT2 (NAME,_get_symtab), \
+.CONCAT2 (NAME,_make_empty_symbol), \
+.CONCAT2 (NAME,_print_symbol), \
+.CONCAT2 (NAME,_get_symbol_info), \
+.CONCAT2 (NAME,_bfd_is_local_label_name), \
+.CONCAT2 (NAME,_get_lineno), \
+.CONCAT2 (NAME,_find_nearest_line), \
+.CONCAT2 (NAME,_bfd_make_debug_symbol), \
+.CONCAT2 (NAME,_read_minisymbols), \
+.CONCAT2 (NAME,_minisymbol_to_symbol)
 .  long     (*_bfd_get_symtab_upper_bound) PARAMS ((bfd *));
 .  long     (*_bfd_canonicalize_symtab) PARAMS ((bfd *,
 .                                                struct symbol_cache_entry **));
@@ -379,10 +382,10 @@ BFD_JUMP_TABLE macros.
 .                                             asymbol *));
 .
 .  {* Routines for relocs.  *}
-.#define BFD_JUMP_TABLE_RELOCS(NAME)\
-.CAT(NAME,_get_reloc_upper_bound),\
-.CAT(NAME,_canonicalize_reloc),\
-.CAT(NAME,_bfd_reloc_type_lookup)
+.#define BFD_JUMP_TABLE_RELOCS(NAME) \
+.CONCAT2 (NAME,_get_reloc_upper_bound), \
+.CONCAT2 (NAME,_canonicalize_reloc), \
+.CONCAT2 (NAME,_bfd_reloc_type_lookup)
 .  long     (*_get_reloc_upper_bound) PARAMS ((bfd *, sec_ptr));
 .  long     (*_bfd_canonicalize_reloc) PARAMS ((bfd *, sec_ptr, arelent **,
 .                                               struct symbol_cache_entry **));
@@ -391,25 +394,25 @@ BFD_JUMP_TABLE macros.
 .           (*reloc_type_lookup) PARAMS ((bfd *, bfd_reloc_code_real_type));
 .
 .  {* Routines used when writing an object file.  *}
-.#define BFD_JUMP_TABLE_WRITE(NAME)\
-.CAT(NAME,_set_arch_mach),\
-.CAT(NAME,_set_section_contents)
+.#define BFD_JUMP_TABLE_WRITE(NAME) \
+.CONCAT2 (NAME,_set_arch_mach), \
+.CONCAT2 (NAME,_set_section_contents)
 .  boolean  (*_bfd_set_arch_mach) PARAMS ((bfd *, enum bfd_architecture,
 .                                          unsigned long));
 .  boolean  (*_bfd_set_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
 .                                                 file_ptr, bfd_size_type));
 .
 .  {* Routines used by the linker.  *}
-.#define BFD_JUMP_TABLE_LINK(NAME)\
-.CAT(NAME,_sizeof_headers),\
-.CAT(NAME,_bfd_get_relocated_section_contents),\
-.CAT(NAME,_bfd_relax_section),\
-.CAT(NAME,_bfd_link_hash_table_create),\
-.CAT(NAME,_bfd_link_add_symbols),\
-.CAT(NAME,_bfd_final_link),\
-.CAT(NAME,_bfd_link_split_section),\
-.CAT(NAME,_bfd_gc_sections),\
-.CAT(NAME,_bfd_merge_sections)
+.#define BFD_JUMP_TABLE_LINK(NAME) \
+.CONCAT2 (NAME,_sizeof_headers), \
+.CONCAT2 (NAME,_bfd_get_relocated_section_contents), \
+.CONCAT2 (NAME,_bfd_relax_section), \
+.CONCAT2 (NAME,_bfd_link_hash_table_create), \
+.CONCAT2 (NAME,_bfd_link_add_symbols), \
+.CONCAT2 (NAME,_bfd_final_link), \
+.CONCAT2 (NAME,_bfd_link_split_section), \
+.CONCAT2 (NAME,_bfd_gc_sections), \
+.CONCAT2 (NAME,_bfd_merge_sections)
 .  int      (*_bfd_sizeof_headers) PARAMS ((bfd *, boolean));
 .  bfd_byte *(*_bfd_get_relocated_section_contents)
 .    PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
@@ -439,11 +442,11 @@ BFD_JUMP_TABLE macros.
 .  boolean  (*_bfd_merge_sections) PARAMS ((bfd *, struct bfd_link_info *));
 .
 .  {* Routines to handle dynamic symbols and relocs.  *}
-.#define BFD_JUMP_TABLE_DYNAMIC(NAME)\
-.CAT(NAME,_get_dynamic_symtab_upper_bound),\
-.CAT(NAME,_canonicalize_dynamic_symtab),\
-.CAT(NAME,_get_dynamic_reloc_upper_bound),\
-.CAT(NAME,_canonicalize_dynamic_reloc)
+.#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
+.CONCAT2 (NAME,_get_dynamic_symtab_upper_bound), \
+.CONCAT2 (NAME,_canonicalize_dynamic_symtab), \
+.CONCAT2 (NAME,_get_dynamic_reloc_upper_bound), \
+.CONCAT2 (NAME,_canonicalize_dynamic_reloc)
 .  {* Get the amount of memory required to hold the dynamic symbols. *}
 .  long     (*_bfd_get_dynamic_symtab_upper_bound) PARAMS ((bfd *));
 .  {* Read in the dynamic symbols.  *}
Index: bfd/vaxnetbsd.c
===================================================================
RCS file: /cvs/src/src/bfd/vaxnetbsd.c,v
retrieving revision 1.3
diff -u -p -r1.3 vaxnetbsd.c
--- vaxnetbsd.c	2001/03/08 21:04:02	1.3
+++ vaxnetbsd.c	2001/10/02 05:25:34
@@ -1,5 +1,5 @@
 /* BFD back-end for NetBSD/VAX a.out-ish binaries.
-   Copyright 1998, 2000 Free Software Foundation, Inc.
+   Copyright 1998, 2000, 2001 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -26,7 +26,11 @@ Foundation, Inc., 59 Temple Place - Suit
 #define	DEFAULT_ARCH	bfd_arch_vax
 #define	DEFAULT_MID 	M_VAX_NETBSD
 
-#define MY(OP) CAT(vaxnetbsd_,OP)
+/* Do not "beautify" the CONCAT* macro args.  Traditional C will not
+   remove whitespace added here, and thus will fail to concatenate
+   the tokens.  */
+#define MY(OP) CONCAT2 (vaxnetbsd_,OP)
+
 /* This needs to start with a.out so GDB knows it is an a.out variant.  */
 #define TARGETNAME "a.out-vax-netbsd"
 
Index: bfd/vms-hdr.c
===================================================================
RCS file: /cvs/src/src/bfd/vms-hdr.c,v
retrieving revision 1.9
diff -u -p -r1.9 vms-hdr.c
--- vms-hdr.c	2001/09/19 05:33:13	1.9
+++ vms-hdr.c	2001/10/02 05:25:34
@@ -313,7 +313,7 @@ _bfd_vms_write_hdr (abfd, objtype)
   else
     _bfd_vms_output_counted (abfd, "NONAME");
 
-  _bfd_vms_output_counted (abfd, BFD_VERSION);
+  _bfd_vms_output_counted (abfd, BFD_VERSION_STRING);
   _bfd_vms_output_dump (abfd, get_vms_time_string (), 17);
   _bfd_vms_output_fill (abfd, 0, 17);
   _bfd_vms_output_flush (abfd);
Index: binutils/Makefile.am
===================================================================
RCS file: /cvs/src/src/binutils/Makefile.am,v
retrieving revision 1.24
diff -u -p -r1.24 Makefile.am
--- Makefile.am	2001/09/30 19:53:06	1.24
+++ Makefile.am	2001/10/02 05:25:37
@@ -177,7 +177,7 @@ stamp-under: Makefile
 	$(SHELL) $(srcdir)/../move-if-change underscore.t underscore.c
 	touch stamp-under
 
-cplus-dem.o: $(BASEDIR)/libiberty/cplus-dem.c $(INCDIR)/getopt.h
+cplus-dem.o: $(BASEDIR)/libiberty/cplus-dem.c $(INCDIR)/getopt.h Makefile
 	$(COMPILE) -c -DMAIN -DVERSION='"$(VERSION)"' $(BASEDIR)/libiberty/cplus-dem.c
 
 cxxfilt_SOURCES =
@@ -280,6 +280,8 @@ diststuff: $(EXTRA_DIST) info
 DISTCLEANFILES = stamp-under sysinfo underscore.c sysroff.c sysroff.h \
 	site.exp site.bak
 
+Makefile: $(BFDDIR)/configure.in
+
 # Targets to rebuild dependencies in this Makefile.
 # Have to get rid of DEP1 here so that "$?" later includes all of $(CFILES).
 DEP: dep.sed $(CFILES) $(HFILES) $(GENERATED_CFILES) $(GENERATED_HFILES) config.h
[dependency changes snipped]
Index: binutils/addr2line.c
===================================================================
RCS file: /cvs/src/src/binutils/addr2line.c,v
retrieving revision 1.10
diff -u -p -r1.10 addr2line.c
--- addr2line.c	2001/09/19 05:33:15	1.10
+++ addr2line.c	2001/10/02 05:25:39
@@ -36,8 +36,6 @@
 #include "demangle.h"
 #include "bucomm.h"
 
-extern char *program_version;
-
 static boolean with_functions;	/* -f, show function names.  */
 static boolean do_demangle;	/* -C, demangle names.  */
 static boolean base_names;	/* -s, strip directory names.  */
Index: binutils/coffdump.c
===================================================================
RCS file: /cvs/src/src/binutils/coffdump.c,v
retrieving revision 1.5
diff -u -p -r1.5 coffdump.c
--- coffdump.c	2001/09/19 05:33:15	1.5
+++ coffdump.c	2001/10/02 05:25:39
@@ -30,8 +30,6 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "coffgrok.h"
 #include "bucomm.h"
 
-#define PROGRAM_VERSION "1.0"
-
 static int atnl;
 
 static void tab PARAMS ((int));
@@ -512,7 +510,7 @@ main (ac, av)
 	  show_help ();
 	  /*NOTREACHED*/
 	case 'V':
-	  printf (_("GNU %s version %s\n"), program_name, PROGRAM_VERSION);
+	  print_version ("coffdump");
 	  exit (0);
 	  /*NOTREACHED*/
 	case 0:
Index: binutils/objdump.c
===================================================================
RCS file: /cvs/src/src/binutils/objdump.c,v
retrieving revision 1.44
diff -u -p -r1.44 objdump.c
--- objdump.c	2001/09/28 21:10:41	1.44
+++ objdump.c	2001/10/02 05:25:44
@@ -2733,7 +2733,7 @@ display_target_tables ()
 static void
 display_info ()
 {
-  printf (_("BFD header file version %s\n"), BFD_VERSION);
+  printf (_("BFD header file version %s\n"), BFD_VERSION_STRING);
   display_target_list ();
   display_target_tables ();
 }
Index: binutils/srconv.c
===================================================================
RCS file: /cvs/src/src/binutils/srconv.c,v
retrieving revision 1.6
diff -u -p -r1.6 srconv.c
--- srconv.c	2001/09/19 05:33:17	1.6
+++ srconv.c	2001/10/02 05:25:45
@@ -36,7 +36,6 @@
 #include "coff/internal.h"
 #include "../bfd/libcoff.h"
 
-#define PROGRAM_VERSION "1.5"
 /*#define FOOP1 1 */
 
 static int addrsize;
@@ -1993,7 +1992,7 @@ main (ac, av)
 	  show_help ();
 	  /*NOTREACHED */
 	case 'V':
-	  printf (_("GNU %s version %s\n"), program_name, PROGRAM_VERSION);
+	  print_version ("srconv");
 	  exit (0);
 	  /*NOTREACHED */
 	case 0:
Index: binutils/sysdump.c
===================================================================
RCS file: /cvs/src/src/binutils/sysdump.c,v
retrieving revision 1.6
diff -u -p -r1.6 sysdump.c
--- sysdump.c	2001/09/19 05:33:17	1.6
+++ sysdump.c	2001/10/02 05:25:45
@@ -33,8 +33,6 @@
 #include <getopt.h>
 #include "sysroff.h"
 
-#define PROGRAM_VERSION "1.0"
-
 static int dump = 1;
 static int segmented_p;
 static int code;
@@ -778,7 +776,7 @@ main (ac, av)
 	  show_help ();
 	  /*NOTREACHED*/
 	case 'V':
-	  printf (_("GNU %s version %s\n"), program_name, PROGRAM_VERSION);
+	  print_version ("sysdump");
 	  exit (0);
 	  /*NOTREACHED*/
 	case 0:
Index: binutils/version.c
===================================================================
RCS file: /cvs/src/src/binutils/version.c,v
retrieving revision 1.4
diff -u -p -r1.4 version.c
--- version.c	2001/03/13 06:43:58	1.4
+++ version.c	2001/10/02 05:25:45
@@ -22,11 +22,6 @@ Foundation, 59 Temple Place - Suite 330,
 #include "bfd.h"
 #include "bucomm.h"
 
-/* This is the version numbers for the binutils.  They all change in
-   lockstep -- it's easier that way. */
-
-const char *program_version = VERSION;
-
 /* Print the version number and copyright information, and exit.  This
    implements the --version option for the various programs.  */
 
@@ -36,8 +31,8 @@ print_version (name)
 {
   /* This output is intended to follow the GNU standards document.  */
   /* xgettext:c-format */
-  printf ("GNU %s %s\n", name, program_version);
-  printf (_("Copyright 1997, 98, 99, 2000, 2001 Free Software Foundation, Inc.\n"));
+  printf ("GNU %s %s\n", name, BFD_VERSION_STRING);
+  printf (_("Copyright 2001 Free Software Foundation, Inc.\n"));
   printf (_("\
 This program is free software; you may redistribute it under the terms of\n\
 the GNU General Public License.  This program has absolutely no warranty.\n"));
Index: gas/Makefile.am
===================================================================
RCS file: /cvs/src/src/gas/Makefile.am,v
retrieving revision 1.41
diff -u -p -r1.41 Makefile.am
--- Makefile.am	2001/09/30 15:55:46	1.41
+++ Makefile.am	2001/10/02 05:25:53
@@ -753,6 +753,8 @@ de-stage3:
 DEP_FILE_DEPS =  $(CFILES) $(HFILES) $(TARGET_CPU_CFILES) \
 	$(TARGET_CPU_HFILES) $(OBJ_FORMAT_CFILES) $(OBJ_FORMAT_HFILES)
 
+Makefile: $(BFDDIR)/configure.in
+
 # Automatic dependency computation.  This is a real pain, because the
 # dependencies change based on target_cpu_type and obj_format.
 # Just to make things even more complicated, automake separates the
[dependency changes snipped]
Index: gas/as.c
===================================================================
RCS file: /cvs/src/src/gas/as.c,v
retrieving revision 1.31
diff -u -p -r1.31 as.c
--- as.c	2001/09/22 09:23:30	1.31
+++ as.c	2001/10/02 05:25:56
@@ -208,7 +208,7 @@ print_version_id ()
 
 #ifdef BFD_ASSEMBLER
   fprintf (stderr, _("GNU assembler version %s (%s) using BFD version %s"),
-	   VERSION, TARGET_ALIAS, BFD_VERSION);
+	   VERSION, TARGET_ALIAS, BFD_VERSION_STRING);
 #else
   fprintf (stderr, _("GNU assembler version %s (%s)"), VERSION, TARGET_ALIAS);
 #endif
Index: gprof/Makefile.am
===================================================================
RCS file: /cvs/src/src/gprof/Makefile.am,v
retrieving revision 1.10
diff -u -p -r1.10 Makefile.am
--- Makefile.am	2001/06/19 11:57:24	1.10
+++ Makefile.am	2001/10/02 05:26:18
@@ -69,6 +69,8 @@ gprof.1: $(srcdir)/gprof.texi
 	       (rm -f $@.T$$$$ && exit 1)
 	rm -f gprof.pod
 
+Makefile: $(BFDDIR)/configure.in
+
 # Targets to rebuild dependencies in this Makefile.
 # Have to get rid of DEP1 here so that "$?" later includes all sources.
 DEP: dep.sed $(gprof_SOURCES) $(noinst_HEADERS) gconfig.h
[dependency changes snipped]
Index: include/nlm/common.h
===================================================================
RCS file: /cvs/src/src/include/nlm/common.h,v
retrieving revision 1.2
diff -u -p -r1.2 common.h
--- common.h	2001/03/14 02:27:44	1.2
+++ common.h	2001/10/02 05:26:20
@@ -1,5 +1,5 @@
 /* NLM (NetWare Loadable Module) support for BFD.
-   Copyright 1993 Free Software Foundation, Inc.
+   Copyright 1993, 2001 Free Software Foundation, Inc.
 
    Written by Fred Fish @ Cygnus Support
 
@@ -23,36 +23,35 @@ Foundation, Inc., 59 Temple Place - Suit
 /* This file is part of NLM support for BFD, and contains the portions
    that are common to both the internal and external representations. */
 
-/* Semi-portable string concatenation in cpp.
-   The NLM_CAT4 hack is to avoid a problem with some strict ANSI C
-   preprocessors.  The problem is, "32_" or "64_" are not a valid
-   preprocessing tokens, and we don't want extra underscores (e.g.,
-   "nlm_32_").  The XNLM_CAT2 macro will cause the inner NLM_CAT macros
-   to be evaluated first, producing still-valid pp-tokens.  Then the
-   final concatenation can be done.  (Sigh.)  */
-
-#ifdef SABER
-#  define NLM_CAT(a,b)		a##b
-#  define NLM_CAT3(a,b,c)	a##b##c
-#  define NLM_CAT4(a,b,c,d)	a##b##c##d
-#else
-#  ifdef __STDC__
-#    define NLM_CAT(a,b)	a##b
-#    define NLM_CAT3(a,b,c)	a##b##c
-#    define XNLM_CAT2(a,b)	NLM_CAT(a,b)
-#    define NLM_CAT4(a,b,c,d)	XNLM_CAT2(NLM_CAT(a,b),NLM_CAT(c,d))
-#  else
-#    define NLM_CAT(a,b)	a/**/b
-#    define NLM_CAT3(a,b,c)	a/**/b/**/c
-#    define NLM_CAT4(a,b,c,d)	a/**/b/**/c/**/d
-#  endif
-#endif
-
 /* If NLM_ARCH_SIZE is not defined, default to 32.  NLM_ARCH_SIZE is
    optionally defined by the application. */
 
 #ifndef NLM_ARCH_SIZE
 #  define NLM_ARCH_SIZE			32
+#endif
+
+/* Due to horrible details of ANSI macro expansion, we can't use CONCAT4
+   for NLM_NAME.  CONCAT2 is used in BFD_JUMP_TABLE macros, and some of
+   them will expand to tokens that themselves are macros defined in terms
+   of NLM_NAME.  If NLM_NAME were defined using CONCAT4 (which is itself
+   defined in bfd-in.h using CONCAT2), ANSI preprocessor rules say that
+   the CONCAT2 within NLM_NAME should not be expanded.
+   So use another name.  */
+#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
+#ifdef SABER
+#define NLM_CAT4(a,b,c,d) a##b##c##d
+#else
+/* This hack is to avoid a problem with some strict ANSI C preprocessors.
+   The problem is, "32_" is not a valid preprocessing token, and we don't
+   want extra underscores (e.g., "nlm_32_").  The NLM_XCAT2 macro will
+   cause the inner CAT2 macros to be evaluated first, producing
+   still-valid pp-tokens.  Then the final concatenation can be done.  */
+#define NLM_CAT2(a,b)	  a##b
+#define NLM_XCAT2(a,b)	  NLM_CAT2(a,b)
+#define NLM_CAT4(a,b,c,d) NLM_XCAT2(NLM_CAT2(a,b),NLM_CAT2(c,d))
+#endif
+#else
+#define NLM_CAT4(a,b,c,d) a/**/b/**/c/**/d
 #endif
 
 #if NLM_ARCH_SIZE == 32
Index: ld/Makefile.am
===================================================================
RCS file: /cvs/src/src/ld/Makefile.am,v
retrieving revision 1.71
diff -u -p -r1.71 Makefile.am
--- Makefile.am	2001/09/30 22:22:05	1.71
+++ Makefile.am	2001/10/02 05:26:23
@@ -1012,6 +1012,8 @@ DISTCLEANFILES = tdirs site.exp site.bak
 distclean-local:
 	rm -rf ldscripts
 
+Makefile: $(BFDDIR)/configure.in
+
 # Targets to rebuild dependencies in this Makefile.
 # Have to get rid of DEP1 here so that "$?" later includes all of $(CFILES).
 DEP: dep.sed $(CFILES) $(HFILES) $(GENERATED_CFILES) $(GENERATED_HFILES) config.h
[dependency changes snipped]
Index: ld/ldver.c
===================================================================
RCS file: /cvs/src/src/ld/ldver.c,v
retrieving revision 1.4
diff -u -p -r1.4 ldver.c
--- ldver.c	2001/03/13 06:14:27	1.4
+++ ldver.c	2001/10/02 05:26:25
@@ -1,5 +1,5 @@
 /* ldver.c -- Print linker version.
-   Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 2000
+   Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 2000, 2001
    Free Software Foundation, Inc.
 
 This file is part of GLD, the Gnu Linker.
@@ -30,16 +30,22 @@ Foundation, Inc., 59 Temple Place - Suit
 #include "ldemul.h"
 #include "ldmain.h"
 
-const char *ld_program_version = VERSION;
-
 void
 ldversion (noisy)
      int noisy;
 {
-  fprintf (stdout, _("GNU ld version %s (with BFD %s)\n"),
-	   ld_program_version, BFD_VERSION);
+  /* Output for noisy == 2 is intended to follow the GNU standards.  */
+  fprintf (stdout, _("GNU ld version %s\n"), BFD_VERSION_STRING);
+
+  if (noisy & 2)
+    {
+      printf (_("Copyright 2001 Free Software Foundation, Inc.\n"));
+      printf (_("\
+This program is free software; you may redistribute it under the terms of\n\
+the GNU General Public License.  This program has absolutely no warranty.\n"));
+    }
 
-  if (noisy)
+  if (noisy & 1)
     {
       ld_emulation_xfer_type **ptr = ld_emulations;
 
Index: ld/ldver.h
===================================================================
RCS file: /cvs/src/src/ld/ldver.h,v
retrieving revision 1.2
diff -u -p -r1.2 ldver.h
--- ldver.h	2001/03/13 06:14:27	1.2
+++ ldver.h	2001/10/02 05:26:25
@@ -17,6 +17,4 @@ You should have received a copy of the G
 along with this program; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
-extern const char *ld_program_version;
-
 void ldversion PARAMS ((int));
Index: ld/lexsup.c
===================================================================
RCS file: /cvs/src/src/ld/lexsup.c,v
retrieving revision 1.41
diff -u -p -r1.41 lexsup.c
--- lexsup.c	2001/09/29 12:57:54	1.41
+++ lexsup.c	2001/10/02 05:26:26
@@ -1003,22 +1003,7 @@ parse_args (argc, argv)
 	  version_printed = true;
 	  break;
 	case OPTION_VERSION:
-	  /* This output is intended to follow the GNU standards document.  */
-	  printf ("GNU ld %s\n", ld_program_version);
-	  printf (_("Copyright 2001 Free Software Foundation, Inc.\n"));
-	  printf (_("\
-This program is free software; you may redistribute it under the terms of\n\
-the GNU General Public License.  This program has absolutely no warranty.\n"));
-	  {
-	    ld_emulation_xfer_type **ptr = ld_emulations;
-
-	    printf (_("  Supported emulations:\n"));
-	    while (*ptr)
-	      {
-		printf ("   %s\n", (*ptr)->emulation_name);
-		ptr++;
-	      }
-	  }
+	  ldversion (2);
 	  xexit (0);
 	  break;
 	case OPTION_VERSION_SCRIPT:
Index: opcodes/Makefile.am
===================================================================
RCS file: /cvs/src/src/opcodes/Makefile.am,v
retrieving revision 1.35
diff -u -p -r1.35 Makefile.am
--- Makefile.am	2001/09/30 18:54:18	1.35
+++ Makefile.am	2001/10/02 05:26:29
@@ -312,6 +312,8 @@ s390-mkopc: s390-mkopc.c
 s390-opc.tab: s390-mkopc s390-opc.txt
 	./s390-mkopc < $(srcdir)/s390-opc.txt > s390-opc.tab
 
+Makefile: $(BFDDIR)/configure.in
+
 # This dependency stuff is copied from BFD.
 
 DEP: dep.sed $(CFILES) $(HFILES) config.h
[dependency changes snipped]


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]