summaryrefslogtreecommitdiffstats
path: root/sys/boot
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2003-06-30 00:15:38 +0000
committerru <ru@FreeBSD.org>2003-06-30 00:15:38 +0000
commit8fec58f4cc8dafd4de8ed16bacbbf49d0c56a3f1 (patch)
tree22a27b85bebd0882b915006c1061379659fb1f11 /sys/boot
parent68cba5536261ecfb6a1ae7d66fbdd97474906746 (diff)
downloadFreeBSD-src-8fec58f4cc8dafd4de8ed16bacbbf49d0c56a3f1.zip
FreeBSD-src-8fec58f4cc8dafd4de8ed16bacbbf49d0c56a3f1.tar.gz
Revision 1.13, besides its useful part, replaced bsd.prog.mk by
bsd.lib.mk and thus broke the build since AFLAGS were not taken into considered anymore, as bsd.lib.mk currently has wrong .s.o rule that uses cc(1) instead of as(1). Revision 1.14 reverted to using as(1), and revision 1.15 brought AFLAGS back to the business, but revision 1.14 also broke "make clean". To fix this, but not break anything that was fixed in revisions 1.13-1.15, we revert mostly to revision 1.13 except for switching back to using bsd.prog.mk. This gives us back the default .s.o rule from sys.mk that uses as(1), and fixes "make clean" by restoring the full contents of OBJS. Also fixed LDFLAGS.
Diffstat (limited to 'sys/boot')
-rw-r--r--sys/boot/i386/kgzldr/Makefile14
1 files changed, 4 insertions, 10 deletions
diff --git a/sys/boot/i386/kgzldr/Makefile b/sys/boot/i386/kgzldr/Makefile
index 6207f73..7228a4f 100644
--- a/sys/boot/i386/kgzldr/Makefile
+++ b/sys/boot/i386/kgzldr/Makefile
@@ -1,25 +1,19 @@
# $FreeBSD$
-SRCS= boot.c inflate.c lib.c
+SRCS= start.s boot.c inflate.c lib.c crt.s sio.s
OBJS= ${SRCS:N*.h:R:S/$/.o/g}
CFLAGS= -ffreestanding
CFLAGS+=-Os
CFLAGS+=-DKZIP
-LDFLAGS=-nostdlib -static -r
+LDFLAGS=-nostdlib -static -Wl,-r
.PATH: ${.CURDIR}/../../../kern
-.for asm in start crt sio
-OBJS+= ${asm}.o
-${asm}.o: ${asm}.s
- ${AS} ${AFLAGS} -o ${.TARGET} ${.ALLSRC:M*${asm}*}
-.endfor
-
CLEANFILES=kgzldr.o
BOOT_COMCONSOLE_PORT?= 0x3f8
AFLAGS+=--defsym SIO_PRT=${BOOT_COMCONSOLE_PORT}
-all: ${OBJS} kgzldr.o
+all: kgzldr.o
kgzldr.o: ${OBJS}
${CC} ${LDFLAGS} -o ${.TARGET} ${OBJS}
@@ -28,4 +22,4 @@ realinstall:
${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
kgzldr.o ${DESTDIR}${LIBDIR}
-.include <bsd.lib.mk>
+.include <bsd.prog.mk>
OpenPOWER on IntegriCloud