tech-toolchain archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

New binutils



Anyone see a problem with the attached diff to change from MKBFD to MKBINUTILS 
and support HAVE_BINUTILS for set lists? I've left a backwards compatibility 
hook for anyone who might use MKBFD.

Thanks,
Nick
Index: distrib/sets/sets.subr
===================================================================
RCS file: /cvsroot/src/distrib/sets/sets.subr,v
retrieving revision 1.84
diff -u -p -r1.84 sets.subr
--- distrib/sets/sets.subr      18 Jun 2009 21:05:35 -0000      1.84
+++ distrib/sets/sets.subr      3 Sep 2009 11:57:54 -0000
@@ -15,6 +15,7 @@
 #      MACHINE 
 #      MACHINE_ARCH
 #      MACHINE_CPU
+#      HAVE_BINUTILS
 #      HAVE_GCC
 #      HAVE_GDB
 #      TOOLCHAIN_MISSING
@@ -23,6 +24,7 @@
 #
 MKVARS="\
        MKBFD           \
+       MKBINUTILS      \
        MKCATPAGES      \
        MKCOMPAT        \
        MKCRYPTO        \
@@ -180,7 +182,7 @@ MKXORG:=no
 .endif
 all:
 .for i in MACHINE MACHINE_ARCH MACHINE_CPU \
-               HAVE_GCC HAVE_GDB OBJECT_FMT TOOLCHAIN_MISSING \
+               HAVE_BINUTILS HAVE_GCC HAVE_GDB OBJECT_FMT TOOLCHAIN_MISSING \
                ${MKVARS}
        @echo "export \$i=\${\$i}"
 .endfor
@@ -249,6 +251,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g
 #                              ${obsolete} != 0
 #
 #      bfd                     ${MKBFD} != no
+#      binutils                ${MKBINUTILS} != no
 #      catpages                ${MKCATPAGES} != no
 #      compat                  ${MKCOMPAT} != no
 #      crypto                  ${MKCRYPTO} != no
@@ -289,6 +292,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g
 #      xorg                    ${MKX11} != no && ${X11FLAVOUR} == "Xorg"
 #      yp                      ${MKYP} != no
 #
+#      binutils=<n>            <n> = value of ${HAVE_BINUTILS}
 #      gcc=<n>                 <n> = value of ${HAVE_GCC}
 #      gdb=<n>                 <n> = value of ${HAVE_GDB}
 #
@@ -333,6 +337,7 @@ list_set_files()
                        }
 
                        if ("'"${TOOLCHAIN_MISSING}"'" != "yes") {
+                               wanted["binutils=" "'"${HAVE_BINUTILS}"'"] = 1
                                wanted["gcc=" "'"${HAVE_GCC}"'"] = 1
                                wanted["gdb=" "'"${HAVE_GDB}"'"] = 1
                        }
Index: etc/Makefile
===================================================================
RCS file: /cvsroot/src/etc/Makefile,v
retrieving revision 1.370
diff -u -p -r1.370 Makefile
--- etc/Makefile        25 Jul 2009 16:20:10 -0000      1.370
+++ etc/Makefile        3 Sep 2009 11:57:55 -0000
@@ -183,7 +183,7 @@ RELEASEVARS=        BSDOBJDIR BSDSRCDIR BUILDID
                KERNARCHDIR KERNCONFDIR KERNOBJDIR KERNSRCDIR \
                MACHINE MACHINE_ARCH MAKE MAKECONF MAKEFLAGS \
                MAKEOBJDIR MAKEOBJDIRPREFIX MAKEVERBOSE \
-               MKBFD MKCATPAGES \
+               MKBFD MKBINUTILS MKCATPAGES \
                MKCRYPTO MKCRYPTO_IDEA MKCRYPTO_MDC2 MKCRYPTO_RC5 MKCVS \
                MKDEBUG MKDEBUGLIB MKDOC MKDYNAMICROOT \
                MKGCC MKGCCCMDS MKGDB \
Index: external/gpl3/Makefile
===================================================================
RCS file: /cvsroot/src/external/gpl3/Makefile,v
retrieving revision 1.1
diff -u -p -r1.1 Makefile
--- external/gpl3/Makefile      21 Aug 2009 06:54:01 -0000      1.1
+++ external/gpl3/Makefile      3 Sep 2009 11:57:55 -0000
@@ -2,7 +2,7 @@
 
 .include <bsd.own.mk>
 
-.if ${MKBFD} != "no" && ${HAVE_BINUTILS} == "219"
+.if ${MKBINUTILS} != "no" && ${HAVE_BINUTILS} == "219"
 SUBDIR+=       binutils
 .endif
 
Index: external/gpl3/binutils/usr.bin/Makefile
===================================================================
RCS file: /cvsroot/src/external/gpl3/binutils/usr.bin/Makefile,v
retrieving revision 1.1
diff -u -p -r1.1 Makefile
--- external/gpl3/binutils/usr.bin/Makefile     18 Aug 2009 20:22:07 -0000      
1.1
+++ external/gpl3/binutils/usr.bin/Makefile     3 Sep 2009 11:57:55 -0000
@@ -2,12 +2,12 @@
 
 .include <bsd.own.mk>
 
-.if ${MKBFD} != "no" && exists(${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk)
+.if ${MKBINUTILS} != "no" && 
exists(${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk)
 .include "${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk"
 
 SSUBDIR+=      common gas gprof ld 
${G_PROGRAMS:C/-new$//:C/sysdump//:C/srconv//:cxxfilt=c++filt}
 SUBDIR+=       ${SSUBDIR:O} # alphabetize
 
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.subdir.mk>
Index: external/gpl3/binutils/usr.sbin/dbsym/Makefile
===================================================================
RCS file: /cvsroot/src/external/gpl3/binutils/usr.sbin/dbsym/Makefile,v
retrieving revision 1.1
diff -u -p -r1.1 Makefile
--- external/gpl3/binutils/usr.sbin/dbsym/Makefile      18 Aug 2009 20:22:20 
-0000      1.1
+++ external/gpl3/binutils/usr.sbin/dbsym/Makefile      3 Sep 2009 11:57:55 
-0000
@@ -4,7 +4,7 @@
 
 .if (defined(HOSTPROG) && \
      (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN))) || \
-    ${MKBFD} != "no"
+    ${MKBINUTILS} != "no"
 TOP=           ${NETBSDSRCDIR}/external/gpl3/binutils
 DIST=          ${TOP}/dist
 BFDSUBDIR=     lib
@@ -34,6 +34,6 @@ CPPFLAGS+=    -I${TOP}/${BFDSUBDIR}/libbfd/
 LDADD+=                -lintl
 DPADD+=                ${LIBINTL}
 .endif # HOSTPROG
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.prog.mk>
Index: external/gpl3/binutils/usr.sbin/mdsetimage/Makefile
===================================================================
RCS file: /cvsroot/src/external/gpl3/binutils/usr.sbin/mdsetimage/Makefile,v
retrieving revision 1.1
diff -u -p -r1.1 Makefile
--- external/gpl3/binutils/usr.sbin/mdsetimage/Makefile 18 Aug 2009 20:22:20 
-0000      1.1
+++ external/gpl3/binutils/usr.sbin/mdsetimage/Makefile 3 Sep 2009 11:57:55 
-0000
@@ -4,7 +4,7 @@
 
 .if (defined(HOSTPROG) && \
      (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN))) || \
-    ${MKBFD} != "no"
+    ${MKBINUTILS} != "no"
 TOP=           ${NETBSDSRCDIR}/external/gpl3/binutils
 DIST=          ${TOP}/dist
 BFDSUBDIR=     lib
@@ -34,6 +34,6 @@ CPPFLAGS+=    -I${TOP}/${BFDSUBDIR}/libbfd/
 LDADD+=                -lintl
 DPADD+=                ${LIBINTL}
 .endif # HOSTPROG
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.prog.mk>
Index: gnu/lib/Makefile
===================================================================
RCS file: /cvsroot/src/gnu/lib/Makefile,v
retrieving revision 1.43
diff -u -p -r1.43 Makefile
--- gnu/lib/Makefile    18 Aug 2009 15:11:25 -0000      1.43
+++ gnu/lib/Makefile    3 Sep 2009 11:57:55 -0000
@@ -2,7 +2,7 @@
 
 .include <bsd.own.mk>
 
-.if ${MKBFD} != "no"
+.if ${MKBINUTILS} != "no"
 .if ${HAVE_BINUTILS} == "216"
 SUBDIR+= libopcodes libbfd libiberty
 .endif
Index: gnu/usr.bin/binutils/Makefile
===================================================================
RCS file: /cvsroot/src/gnu/usr.bin/binutils/Makefile,v
retrieving revision 1.22
diff -u -p -r1.22 Makefile
--- gnu/usr.bin/binutils/Makefile       4 Dec 2003 09:29:33 -0000       1.22
+++ gnu/usr.bin/binutils/Makefile       3 Sep 2009 11:57:55 -0000
@@ -2,7 +2,7 @@
 
 .include <bsd.own.mk>
 
-.if ${MKBFD} != "no" && exists(${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk)
+.if ${MKBINUTILS} != "no" && 
exists(${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk)
 .include "${.CURDIR}/common/arch/${MACHINE_ARCH}/defs.mk"
 
 #SUBDIR=               libopcodes libbfd libiberty .WAIT
@@ -10,6 +10,6 @@
 SSUBDIR+=      common gas gprof ld 
${G_PROGRAMS:C/-new$//:C/sysdump//:C/srconv//:cxxfilt=c++filt}
 SUBDIR+=       ${SSUBDIR:O} # alphabetize
 
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.subdir.mk>
Index: gnu/usr.sbin/dbsym/Makefile
===================================================================
RCS file: /cvsroot/src/gnu/usr.sbin/dbsym/Makefile,v
retrieving revision 1.13
diff -u -p -r1.13 Makefile
--- gnu/usr.sbin/dbsym/Makefile 3 Jan 2004 14:04:27 -0000       1.13
+++ gnu/usr.sbin/dbsym/Makefile 3 Sep 2009 11:57:55 -0000
@@ -4,7 +4,7 @@
 
 .if (defined(HOSTPROG) && \
      (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN))) || \
-    ${MKBFD} != "no"
+    ${MKBINUTILS} != "no"
 TOP=           ${NETBSDSRCDIR}/gnu
 DIST=          ${TOP}/dist/binutils
 BFDSUBDIR=     lib
@@ -34,6 +34,6 @@ CPPFLAGS+=    -I${TOP}/${BFDSUBDIR}/libbfd/
 LDADD+=                -lintl
 DPADD+=                ${LIBINTL}
 .endif # HOSTPROG
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.prog.mk>
Index: gnu/usr.sbin/mdsetimage/Makefile
===================================================================
RCS file: /cvsroot/src/gnu/usr.sbin/mdsetimage/Makefile,v
retrieving revision 1.19
diff -u -p -r1.19 Makefile
--- gnu/usr.sbin/mdsetimage/Makefile    9 Feb 2008 02:37:21 -0000       1.19
+++ gnu/usr.sbin/mdsetimage/Makefile    3 Sep 2009 11:57:55 -0000
@@ -4,7 +4,7 @@
 
 .if (defined(HOSTPROG) && \
      (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN))) || \
-    ${MKBFD} != "no"
+    ${MKBINUTILS} != "no"
 TOP=           ${NETBSDSRCDIR}/gnu
 DIST=          ${TOP}/dist/binutils
 BFDSUBDIR=     lib
@@ -34,6 +34,6 @@ CPPFLAGS+=    -I${TOP}/${BFDSUBDIR}/libbfd/
 LDADD+=                -lintl
 DPADD+=                ${LIBINTL}
 .endif # HOSTPROG
-.endif # MKBFD != no
+.endif # MKBINUTILS != no
 
 .include <bsd.prog.mk>
Index: share/man/man5/mk.conf.5
===================================================================
RCS file: /cvsroot/src/share/man/man5/mk.conf.5,v
retrieving revision 1.46
diff -u -p -r1.46 mk.conf.5
--- share/man/man5/mk.conf.5    15 Nov 2008 11:27:49 -0000      1.46
+++ share/man/man5/mk.conf.5    3 Sep 2009 11:57:55 -0000
@@ -224,20 +224,18 @@ flag.
 Indicates whether the Automated Testing Framework is built and installed.
 .DFLTy
 .
-.It Sy MKBFD
+.It Sy MKBINUTILS
 .YorN
-Indicates whether
+Indicates whether any of the binutils tools or libraries should be built.
+That is, the libraries 
 .Sy libbfd ,
 .Sy libiberty ,
-or any of the things that depend
-upon them (such as the binutils,
+or any of the things that depend upon them, e.g.
 .Xr as 1 ,
-.Xr gdb 1 ,
 .Xr ld 1 ,
 .Xr dbsym 8 ,
 or
-.Xr mdsetimage 8 )
-should be built.
+.Xr mdsetimage 8 .
 .DFLTy
 .
 .It Sy MKCATPAGES
Index: share/mk/bsd.README
===================================================================
RCS file: /cvsroot/src/share/mk/bsd.README,v
retrieving revision 1.251
diff -u -p -r1.251 bsd.README
--- share/mk/bsd.README 18 Jun 2009 06:36:59 -0000      1.251
+++ share/mk/bsd.README 3 Sep 2009 11:57:56 -0000
@@ -117,8 +117,9 @@ MKATF               If "no", don't build libatf-c, li
                with the Automated Testing Framework (ATF).
                Default: yes
 
-MKBFD          If "no", don't build libbfd, libiberty, or any of the things
-               that depend on them (binutils/gas/ld, gdb, dbsym, mdsetimage).
+MKBFD          Obsolete, use MKBINUTILS
+
+MKBINUTILS     If "no", don't build binutils (gas, ld, etc and libbfd, 
libopcodes)
                Default: yes
 
 MKCATPAGES     If "no", don't build or install the catman pages.
@@ -591,7 +592,7 @@ TOOLCHAIN_MISSING
                TOOLCHAIN_MISSING is conditionally assigned the value "yes". 
                Otherwise, the variable is unconditionally assigned the
                value "no".
-               If not "no", ${MKBFD}, ${MKGCC}, and ${MKGDB} are
+               If not "no", ${MKBINUTILS}, ${MKGCC}, and ${MKGDB} are
                unconditionally assigned the value "no".
 
 EXTERNAL_TOOLCHAIN
Index: share/mk/bsd.own.mk
===================================================================
RCS file: /cvsroot/src/share/mk/bsd.own.mk,v
retrieving revision 1.568
diff -u -p -r1.568 bsd.own.mk
--- share/mk/bsd.own.mk 18 Aug 2009 14:53:00 -0000      1.568
+++ share/mk/bsd.own.mk 3 Sep 2009 11:57:57 -0000
@@ -476,14 +476,14 @@ OBJECT_FMT=       ELF
 # If this platform's toolchain is missing, we obviously cannot build it.
 #
 .if ${TOOLCHAIN_MISSING} != "no"
-MKBFD:= no
+MKBINUTILS:= no
 MKGDB:= no
 MKGCC:= no
 .endif
 
 #
 # If we are using an external toolchain, we can still build the target's
-# BFD stuff, but we cannot build GCC's support libraries, since those are
+# binutils, but we cannot build GCC's support libraries, since those are
 # tightly-coupled to the version of GCC being used.
 #
 .if defined(EXTERNAL_TOOLCHAIN)
@@ -650,11 +650,18 @@ MKCOMPAT:=        no
 .endif
 
 #
+# MK* backward compatibility.
+#
+.if defined(MKBFD)
+MKBINUTILS?=   ${MKBFD}
+.endif
+
+#
 # MK* options which default to "yes".
 #
 .for var in \
        MKATF \
-       MKBFD MKBINUTILS \
+       MKBINUTILS \
        MKCATPAGES MKCRYPTO MKCOMPLEX MKCVS \
        MKDOC \
        MKGCC MKGCCCMDS MKGDB \


Home | Main Index | Thread Index | Old Index