Index: Makefile =================================================================== --- Makefile +++ Makefile @@ -133,7 +133,7 @@ xdev-links native-xtools stageworld stagekernel stage-packages \ create-world-packages create-kernel-packages create-packages \ packages installconfig real-packages sign-packages package-pkg \ - print-dir test-system-compiler + print-dir test-system-compiler showitools # XXX: r156740: This can't work since bsd.subdir.mk is not included ever. # It will only work for SUBDIR_TARGETS in make.conf. Index: Makefile.inc1 =================================================================== --- Makefile.inc1 +++ Makefile.inc1 @@ -948,17 +948,19 @@ MTREE_MAGIC?= mtree 2.0 -distributeworld installworld stageworld: _installcheck_world .PHONY - mkdir -p ${INSTALLTMP} - progs=$$(for prog in ${ITOOLS}; do \ +.if make(distributeworld) || make (installworld) || make (stageworld) || \ + make (showitools) +ITOOLS_PROGS!=\ + for prog in ${ITOOLS}; do \ if progpath=`which $$prog`; then \ echo $$progpath; \ else \ echo "Required tool $$prog not found in PATH." >&2; \ exit 1; \ fi; \ - done); \ - libs=$$(ldd -f "%o %p\n" -f "%o %p\n" $$progs 2>/dev/null | sort -u | \ + done +ITOOLS_LIBS!=\ + ldd -f "%o %p\n" -f "%o %p\n" ${ITOOLS_PROGS} 2>/dev/null | sort -u | \ while read line; do \ set -- $$line; \ if [ "$$2 $$3" != "not found" ]; then \ @@ -967,8 +969,18 @@ echo "Required library $$1 not found." >&2; \ exit 1; \ fi; \ - done); \ - cp $$libs $$progs ${INSTALLTMP} + done +.endif + +showitools: .PHONY + @echo "Install tools:" + @echo ${ITOOLS_PROGS} + @echo "Libraries:" + @echo ${ITOOLS_LIBS} + +distributeworld installworld stageworld: _installcheck_world .PHONY + mkdir -p ${INSTALLTMP} + cp ${ITOOLS_LIBS} ${ITOOLS_PROGS} ${INSTALLTMP} cp -R $${PATH_LOCALE:-"/usr/share/locale"} ${INSTALLTMP}/locale .if defined(NO_ROOT) -mkdir -p ${METALOG:H}