diff options
-rw-r--r-- | gnu/usr.bin/binutils/Makefile.bsd-wrapper | 49 |
1 files changed, 29 insertions, 20 deletions
diff --git a/gnu/usr.bin/binutils/Makefile.bsd-wrapper b/gnu/usr.bin/binutils/Makefile.bsd-wrapper index 6752d81a2c7..652bc16e1d2 100644 --- a/gnu/usr.bin/binutils/Makefile.bsd-wrapper +++ b/gnu/usr.bin/binutils/Makefile.bsd-wrapper @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile.bsd-wrapper,v 1.32 1999/12/22 19:45:32 mickey Exp $ +# $OpenBSD: Makefile.bsd-wrapper,v 1.33 2000/08/04 10:07:59 espie Exp $ SUBDIRS= opcodes bfd MAN= @@ -6,7 +6,7 @@ MAN= # gdb not ready yet .if (${MACHINE_ARCH} != "unknown") SUBDIRS+= gdb mmalloc readline -MAN+= gdb/gdb.1 +MAN+= gdb/gdb.1 .endif # some ports use all of binutils, some do not. @@ -14,21 +14,21 @@ MAN+= gdb/gdb.1 (${MACHINE_ARCH} == "powerpc") || (${MACHINE_ARCH} == "hppa") SUBDIRS+= binutils ld gas gprof MAN+= binutils/ar.1 binutils/nm.1 \ - binutils/objcopy.1 binutils/objdump.1 binutils/ranlib.1 \ + binutils/objcopy.1 binutils/ranlib.1 \ binutils/size.1 binutils/strings.1 binutils/strip.1 \ gas/doc/as.1 gprof/gprof.1 ld/ld.1 -.else -MAN+= binutils/objdump.1 +MANSUBDIR=/alpha /pmax /powerpc /hppa .endif +MAN+= binutils/objdump.1 # Used by the GNU Makefile ALL_MODULES=${SUBDIRS:S/^/all-/g} INSTALL_MODULES=${SUBDIRS:S/^/install-/g} all: config.status - ${MAKE} CC="${CC}" CFLAGS="${CFLAGS} ${COPTS}" LDFLAGS=${LDSTATIC} \ - SUBDIRS="${SUBDIRS}" ALL_MODULES="${ALL_MODULES}" \ - INSTALL_MODULES="${INSTALL_MODULES}" + SUBDIRS="${SUBDIRS}" ${MAKE} CC="${CC}" CFLAGS="${CFLAGS} ${COPTS}" \ + LDFLAGS=${LDSTATIC} ALL_MODULES="${ALL_MODULES}" \ + INSTALL_MODULES="${INSTALL_MODULES}" cd ${.OBJDIR}/binutils && \ ${MAKE} CC="${CC}" CFLAGS="${CFLAGS} ${COPTS}" LDFLAGS=${LDSTATIC} \ objdump @@ -43,18 +43,25 @@ CF= --cache-file=${GLOBAL_AUTOCONF_CACHE} CF= .endif -config: .FORCE +do-config: .USE + PATH="/bin:/usr/bin:/sbin:/usr/sbin" \ + sh ${.CURDIR}/configure --prefix=/usr \ + --infodir='$${prefix}/share/info' \ + --disable-gdbtk --disable-commonbfdlib ${CF} + cd ${.OBJDIR} && \ + sed -e 's,SUBDIRS *=,SUBDIRS ?=,' <Makefile >Makefile.tmp && \ + mv -f Makefile.tmp Makefile + + +.PHONY: config + +config: do-config .ifndef GLOBAL_AUTOCONF_CACHE -rm -f config.cache .endif - PATH="/bin:/usr/bin:/sbin:/usr/sbin" \ - sh ${.CURDIR}/configure --prefix=/usr --infodir=/usr/share/info \ - --disable-gdbtk --disable-commonbfdlib ${CF} -config.status: - PATH="/bin:/usr/bin:/sbin:/usr/sbin" \ - sh ${.CURDIR}/configure --prefix=/usr --infodir=/usr/share/info \ - --disable-gdbtk --disable-commonbfdlib ${CF} +config.status: do-config + .ifdef NOMAN maninstall: @@ -62,10 +69,12 @@ maninstall: .endif install: maninstall - ${MAKE} prefix=${DESTDIR}/usr infodir=${DESTDIR}/usr/share/info \ - bindir=${DESTDIR}/usr/bin INSTALL_MAN= SUBDIRS="${SUBDIRS}" \ - ALL_MODULES="${ALL_MODULES}" INSTALL_MODULES="${INSTALL_MODULES}" \ - install install-info + SUBDIRS="${SUBDIRS}" ${MAKE} prefix='${DESTDIR}/usr' \ + infodir='${DESTDIR}/usr/share/info' \ + bindir='${DESTDIR}/usr/bin' \ + INSTALL_MAN= \ + ALL_MODULES="${ALL_MODULES}" INSTALL_MODULES="${INSTALL_MODULES}" \ + install install-info cd ${.OBJDIR}/binutils && \ ${INSTALL} ${INSTALL_COPY} ${INSTALL_STRIP} -o ${BINOWN} -g ${BINGRP} \ -m ${BINMODE} objdump ${DESTDIR}/usr/bin |