From 3724ff7100efbc2ba0af403c6d76d3716a6ecfcb Mon Sep 17 00:00:00 2001 From: phk Date: Sun, 28 Nov 2004 17:12:15 +0000 Subject: Make it possible to specify a list of customize scripts. Look for them in ./Customize first, then relative to . and then absolute. --- tools/tools/nanobsd/Makefile | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'tools') diff --git a/tools/tools/nanobsd/Makefile b/tools/tools/nanobsd/Makefile index 21e05c1..d5379c9 100644 --- a/tools/tools/nanobsd/Makefile +++ b/tools/tools/nanobsd/Makefile @@ -47,7 +47,7 @@ WD?= ${.OBJDIR}/_.w # configuration slice. #CFGMASTER?= ${.CURDIR}/cfgmaster -.for cust in CUSTOMIZE CFGMASTER +.for cust in CFGMASTER .if !empty(${cust}) .if exists(${.CURDIR}/${${cust}}) ${cust}_PATH= ${.CURDIR}/${${cust}} @@ -71,14 +71,15 @@ all: buildworld installworld buildimage # Customize: _.cs _.cs: _.iw _.di _.ik _.di -.if empty(CUSTOMIZE_PATH) - # useful stuff for diskless boot - sed -i "" -e /beastie/d ${WD}/boot/loader.rc - sed -i "" -e /ttyd0/s/off/on/ ${WD}/etc/ttys - echo " -h" > ${WD}/boot.config +.for cust in ${CUSTOMIZE} +.if exists(${.CURDIR}/Customize/${${cust}}) + sh -e ${.CURDIR}/Customize/${cust} ${WD} ${WORLDDIR} ${.CURDIR} ${CUSTOMIZE_ARGS} +.elif exists(${.CURDIR}/${${cust}}) + sh -e ${.CURDIR}/${cust} ${WD} ${WORLDDIR} ${.CURDIR} ${CUSTOMIZE_ARGS} .else - sh -e ${CUSTOMIZE_PATH} ${WD} ${WORLDDIR} ${.CURDIR} ${CUSTOMIZE_ARGS} + sh -e ${cust} ${WD} ${WORLDDIR} ${.CURDIR} ${CUSTOMIZE_ARGS} .endif +.endfor touch _.cs ########################################################################### -- cgit v1.1