diff options
author | Pascal Stumpf <pascal@cvs.openbsd.org> | 2012-09-25 09:01:04 +0000 |
---|---|---|
committer | Pascal Stumpf <pascal@cvs.openbsd.org> | 2012-09-25 09:01:04 +0000 |
commit | c60458c393b55d9504705533498b27f875701860 (patch) | |
tree | 5115d5b6aae47a50100423669a4044fe68d47d46 /sys/arch/i386/stand | |
parent | 364f9c056d58d6405fd541d95b067d8af7b7ed8b (diff) |
Reduce the diff between amd64/stand and i386/stand, requested by deraadt@.
These create essentially the same bootblocks, so the build system should not be
diverging too much, or at least easily diffable.
There is still a lot of work to be done here, but this is the low-hanging fruit.
ok jsing@
Diffstat (limited to 'sys/arch/i386/stand')
-rw-r--r-- | sys/arch/i386/stand/boot/Makefile | 4 | ||||
-rw-r--r-- | sys/arch/i386/stand/cdboot/Makefile | 15 | ||||
-rw-r--r-- | sys/arch/i386/stand/pxeboot/Makefile | 16 |
3 files changed, 16 insertions, 19 deletions
diff --git a/sys/arch/i386/stand/boot/Makefile b/sys/arch/i386/stand/boot/Makefile index 2ae36be8f06..ed97ba30cb6 100644 --- a/sys/arch/i386/stand/boot/Makefile +++ b/sys/arch/i386/stand/boot/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.38 2012/08/29 22:23:07 pascal Exp $ +# $OpenBSD: Makefile,v 1.39 2012/09/25 09:01:03 pascal Exp $ .include "${.CURDIR}/../Makefile.inc" @@ -45,7 +45,7 @@ SRCS+= ufs.c SRCS+= strlcpy.c .PATH: ${S}/lib/libkern/arch/i386 -SRCS+= moddi3.c divdi3.c qdivrem.c +SRCS+= divdi3.c moddi3.c qdivrem.c .PATH: ${S}/lib/libz SRCS+= adler32.c crc32.c inflate.c inftrees.c diff --git a/sys/arch/i386/stand/cdboot/Makefile b/sys/arch/i386/stand/cdboot/Makefile index 4bbabc7b17c..e3e72201560 100644 --- a/sys/arch/i386/stand/cdboot/Makefile +++ b/sys/arch/i386/stand/cdboot/Makefile @@ -1,24 +1,23 @@ -# $OpenBSD: Makefile,v 1.10 2012/08/29 22:23:08 pascal Exp $ +# $OpenBSD: Makefile,v 1.11 2012/09/25 09:01:03 pascal Exp $ .include "${.CURDIR}/../Makefile.inc" MAN= cdboot.8 .if ${MACHINE} == "i386" +S =${.CURDIR}/../../../.. +SADIR= ${.CURDIR}/.. + PROG= cdboot +SRCS= srt0.S LD?= ld SIZE?= size -LDFLAGS+=-nostdlib -Bstatic +LDFLAGS+=-nostdlib -Bstatic -Ttext $(LINKADDR) -N -x -noinhibit-exec -nopie INSTALL_STRIP= -LDFLAGS+=-Ttext $(LINKADDR) -N -x -noinhibit-exec -nopie CLEANFILES+= crt0.o ${PROG}.whole -SRCS= srt0.S SRCS+= boot.c cmd.c vars.c bootarg.c conf.c -S =${.CURDIR}/../../../.. -SADIR= ${.CURDIR}/.. - LDADD= ${LIBSA} ${LIBZ} DPADD= ${LIBSA} ${LIBZ} @@ -31,7 +30,7 @@ ${PROG}: $(OBJS) $(DPADD) $(LD) $(LDFLAGS) -o ${PROG} $(OBJS) $(LDADD) @$(SIZE) ${PROG} cp ${PROG} ${PROG}.whole - if [ -x ${.OBJDIR}/${PROG} ]; then \ + @if [ -x ${.OBJDIR}/${PROG} ]; then \ objcopy -O binary ${PROG} ${.OBJDIR}/.tmp;\ mv -f ${.OBJDIR}/.tmp ${.OBJDIR}/${PROG}; \ ls -l ${.OBJDIR}/${PROG}; \ diff --git a/sys/arch/i386/stand/pxeboot/Makefile b/sys/arch/i386/stand/pxeboot/Makefile index 3c6f42b368e..2455d65205d 100644 --- a/sys/arch/i386/stand/pxeboot/Makefile +++ b/sys/arch/i386/stand/pxeboot/Makefile @@ -1,24 +1,23 @@ -# $OpenBSD: Makefile,v 1.7 2012/08/29 22:23:08 pascal Exp $ +# $OpenBSD: Makefile,v 1.8 2012/09/25 09:01:03 pascal Exp $ .include "${.CURDIR}/../Makefile.inc" MAN= pxeboot.8 .if ${MACHINE} == "i386" +S =${.CURDIR}/../../../.. +SADIR= ${.CURDIR}/.. + PROG= pxeboot LD?= ld SIZE?= size -LDFLAGS+=-nostdlib -Bstatic -nopie +LDFLAGS+=-nostdlib -Bstatic -Ttext $(LINKADDR) -N -x -noinhibit-exec -nopie INSTALL_STRIP= -LDFLAGS+=-Ttext $(LINKADDR) -N -x -noinhibit-exec CLEANFILES+= crt0.o ${PROG}.whole SRCS= srt0.S SRCS+= boot.c cmd.c vars.c bootarg.c conf.c devopen.c net.c open.c -S =${.CURDIR}/../../../.. -SADIR= ${.CURDIR}/.. - LDADD= ${LIBSA} ${LIBZ} DPADD= ${LIBSA} ${LIBZ} @@ -43,9 +42,8 @@ NOPROG= .include <bsd.prog.mk> -CPPFLAGS+=-DBOOTMAGIC=$(BOOTMAGIC) ${DEBUGFLAGS} -CPPFLAGS+=-DLINKADDR=${LINKADDR} -CFLAGS+=${SACFLAGS} -D__INTERNAL_LIBSA_CREAD -fno-pie +CPPFLAGS+=-DBOOTMAGIC=$(BOOTMAGIC) ${DEBUGFLAGS} -DLINKADDR=${LINKADDR} +CFLAGS+=$(SACFLAGS) -D__INTERNAL_LIBSA_CREAD -fno-pie #AFLAGS+=-Wa,-R # AFLAGS+=-Wa,-a AFLAGS+=-fno-pie |