Date: Mon, 24 Sep 2001 16:53:16 +0900 (JST) From: Takahashi Yoshihiro <nyan@FreeBSD.org> To: marcel@FreeBSD.org Cc: current@FreeBSD.org Subject: Fix sysinstall problem Message-ID: <20010924.165316.74191154.yosihiro@cc.kogakuin.ac.jp>
next in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
current sysinstall building has a problem.
It uses the boot programs in /boot. So, even if we change boot0 and/or
mbr, the new sysinstall includes old one. And, it breaks cross
building, too.
I have made the patch to fix this problem. It adds a new target "boot"
into Makefile.inc1. Because, the boot programs must be made after
"cross-tools" target and before "par-depend" target.
Please review it.
Thank you.
---
TAKAHASHI Yoshihiro
THE CENTER for INFORMATION SCIENCE, Kogakuin Univ.
[-- Attachment #2 --]
Index: src/Makefile.inc1
===================================================================
RCS file: /home/ncvs/src/Makefile.inc1,v
retrieving revision 1.217
diff -u -r1.217 Makefile.inc1
--- src/Makefile.inc1 2001/09/20 12:24:10 1.217
+++ src/Makefile.inc1 2001/09/23 13:39:02
@@ -300,6 +300,11 @@
cd ${.CURDIR}; ${WMAKE} -DNOHTML -DNOINFO -DNOMAN -DNOFSCHG libraries
@echo
@echo "--------------------------------------------------------------"
+ @echo ">>> stage 4: building boot"
+ @echo "--------------------------------------------------------------"
+ cd ${.CURDIR}; ${WMAKE} boot
+ @echo
+ @echo "--------------------------------------------------------------"
@echo ">>> stage 4: make dependencies"
@echo "--------------------------------------------------------------"
cd ${.CURDIR}; ${WMAKE} par-depend
@@ -805,6 +810,13 @@
${MAKE} install
.endif
.endfor
+
+boot:
+.if exists(${.CURDIR}/sys/boot)
+ cd ${.CURDIR}/sys/boot; \
+ ${MAKE} depend; \
+ ${MAKE} all
+.endif
.for __target in clean cleandepend cleandir depend obj
.for entry in ${SUBDIR}
Index: src/usr.sbin/sysinstall/Makefile
===================================================================
RCS file: /home/ncvs/src/usr.sbin/sysinstall/Makefile,v
retrieving revision 1.117
diff -u -r1.117 Makefile
--- src/usr.sbin/sysinstall/Makefile 2001/09/05 07:12:19 1.117
+++ src/usr.sbin/sysinstall/Makefile 2001/09/23 08:05:21
@@ -55,15 +55,38 @@
file2c 'const char termcap_xterm[] = {' ',0};' \
>> makedevs.tmp
.if ${MACHINE} == "i386"
+.if exists(${.OBJDIR}/../../sys/boot/${MACHINE}/boot0/boot0)
+ file2c 'u_char boot0[] = {' '};' \
+ < ${.OBJDIR}/../../sys/boot/${MACHINE}/boot0/boot0 \
+ >> makedevs.tmp
+.else
file2c 'u_char boot0[] = {' '};' < /boot/boot0 >> makedevs.tmp
+.endif
echo "size_t boot0_size = sizeof(boot0);" >> makedevs.tmp
+.if exists(${.OBJDIR}/../../sys/boot/${MACHINE}/mbr/mbr)
+ file2c 'u_char mbr[] = {' '};' \
+ < ${.OBJDIR}/../../sys/boot/${MACHINE}/mbr/mbr >> makedevs.tmp
+.else
file2c 'u_char mbr[] = {' '};' < /boot/mbr >> makedevs.tmp
+.endif
echo "size_t mbr_size = sizeof(mbr);" >> makedevs.tmp
.endif
.if ${MACHINE} == "pc98"
+.if exists(${.OBJDIR}/../../sys/boot/${MACHINE}/boot0/boot0)
+ file2c 'u_char boot0[] = {' '};' \
+ < ${.OBJDIR}/../../sys/boot/${MACHINE}/boot0/boot0 \
+ >> makedevs.tmp
+.else
file2c 'u_char boot0[] = {' '};' < /boot/boot0 >> makedevs.tmp
+.endif
echo "size_t boot0_size = sizeof(boot0);" >> makedevs.tmp
+.if exists(${.OBJDIR}/../../sys/boot/${MACHINE}/boot0.5/boot0.5)
+ file2c 'u_char boot05[] = {' '};' \
+ < ${.OBJDIR}/../../sys/boot/${MACHINE}/boot0.5/boot0.5 \
+ >> makedevs.tmp
+.else
file2c 'u_char boot05[] = {' '};' < /boot/boot0.5 >> makedevs.tmp
+.endif
echo "size_t boot05_size = sizeof(boot05);" >> makedevs.tmp
.endif
mv makedevs.tmp makedevs.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010924.165316.74191154.yosihiro>
