diff options
author | kn <kn@cvs.openbsd.org> | 2021-07-26 12:47:48 +0000 |
---|---|---|
committer | kn <kn@cvs.openbsd.org> | 2021-07-26 12:47:48 +0000 |
commit | 6cc79f68089a7db02ffed215bdd098edc274fec5 (patch) | |
tree | 6b5c9e83a04364707001724b2c04cc11c7f8e3bf /distrib/riscv64/ramdisk | |
parent | fbeb36730108f715d613dba2aec63f9310695251 (diff) |
Pass make flags to kernel and lib builds
Running `make -j4' in /usr/src/distrib/amd64/ramdisk_cd/ et al. executes
make(1) to both build the RAMDISK kernel and build libraries.
Doing so does not propagate the flags specified to the ramdisk_cd
invocation, which in turn means `-j4' for example is ignored and both kernel
and libraries will not be built in parallel.
Pass make(1)'s MFLAGS along to retain relevant flags; make is clever enough
to separate flags, variable assignments and targets from each other and only
pass along things to `MFLAGS' that'd make sense, i.e. `make -C. -j4 foo=bar'
does *not* pass `-C.' to change directories.
(can be easily tested with `make -p ... | grep MFLAGS'.)
This makes hacking on ramdisks/the installer much faster, espescially since
the `bsd' target does `make clean' and therefore builds a new kernel every
time.
OK deraadt
Diffstat (limited to 'distrib/riscv64/ramdisk')
-rw-r--r-- | distrib/riscv64/ramdisk/Makefile | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/distrib/riscv64/ramdisk/Makefile b/distrib/riscv64/ramdisk/Makefile index 6af67bbc7fb..c3aed053d45 100644 --- a/distrib/riscv64/ramdisk/Makefile +++ b/distrib/riscv64/ramdisk/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.3 2021/05/19 23:15:21 drahn Exp $ +# $OpenBSD: Makefile,v 1.4 2021/07/26 12:47:46 kn Exp $ FS= miniroot${OSrev}.img FSSIZE= 67584 @@ -49,7 +49,7 @@ bsd.rd: mr.fs bsd bsd: cd ${.CURDIR}/../../../sys/arch/${MACHINE}/compile/${RAMDISK} && \ - su ${BUILDUSER} -c '${MAKE} config && ${MAKE} clean && exec ${MAKE}' + su ${BUILDUSER} -c '${MAKE} config && ${MAKE} clean && exec ${MAKE} ${MFLAGS}' cp -p ${.CURDIR}/../../../sys/arch/${MACHINE}/compile/${RAMDISK}/obj/bsd bsd mr.fs: instbin @@ -70,7 +70,7 @@ instbin.mk instbin.cache instbin.c: instbin.conf -c instbin.c -e instbin -m instbin.mk instbin.conf instbin: instbin.mk instbin.cache instbin.c - ${MAKE} -f instbin.mk SRCLIBDIR=${.CURDIR}/../../../lib all + ${MAKE} ${MFLAGS} -f instbin.mk SRCLIBDIR=${.CURDIR}/../../../lib all instbin.conf: ${LISTS} awk -f ${UTILS}/makeconf.awk ${LISTS} > instbin.conf |