diff options
| author | Sam Leffler <sam@FreeBSD.org> | 2008-10-19 06:58:31 +0000 |
|---|---|---|
| committer | Sam Leffler <sam@FreeBSD.org> | 2008-10-19 06:58:31 +0000 |
| commit | 8d1f54dbaa5ef5168b896f6562c06e9da6b23881 (patch) | |
| tree | 945dc303ebee7ffede9e384536cbb7181bf5cfb6 | |
| parent | 50d6e424348162df7ef871da1db76fab6681f414 (diff) | |
Notes
| -rw-r--r-- | tools/tools/nanobsd/nanobsd.sh | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/tools/tools/nanobsd/nanobsd.sh b/tools/tools/nanobsd/nanobsd.sh index 00ad156138ae..d1041a2c066a 100644 --- a/tools/tools/nanobsd/nanobsd.sh +++ b/tools/tools/nanobsd/nanobsd.sh @@ -665,6 +665,7 @@ usage () { echo " -b suppress builds (both kernel and world)" echo " -i suppress disk image build" echo " -k suppress buildkernel" + echo " -n add -DNO_CLEAN to buildworld, buildkernel, etc" echo " -q make output more quite" echo " -v make output more verbose" echo " -w suppress buildworld" @@ -676,12 +677,13 @@ usage () { ####################################################################### # Parse arguments +do_clean=true do_kernel=true do_world=true do_image=true set +e -args=`getopt bc:hikqvw $*` +args=`getopt bc:hiknqvw $*` if [ $? -ne 0 ] ; then usage exit 2 @@ -714,6 +716,10 @@ do do_image=false shift ;; + -n) + do_clean=false + shift + ;; -q) PPLEVEL=$(($PPLEVEL - 1)) shift @@ -763,6 +769,12 @@ else exit 1 fi +if $do_clean ; then + true +else + NANO_PMAKE="${NANO_PMAKE} -DNO_CLEAN" +fi + export MAKEOBJDIRPREFIX export NANO_ARCH @@ -793,7 +805,11 @@ export NANO_BOOTLOADER pprint 1 "NanoBSD image ${NANO_NAME} build starting" if $do_world ; then - clean_build + if $do_clean ; then + clean_build + else + pprint 2 "Using existing build tree (as instructed)" + fi make_conf_build build_world else |
