diff options
author | Bryan Drewery <bdrewery@FreeBSD.org> | 2017-05-09 20:21:38 +0000 |
---|---|---|
committer | Bryan Drewery <bdrewery@FreeBSD.org> | 2017-05-09 20:21:38 +0000 |
commit | 6d75a7a852fe046e3866858ff995447498904e95 (patch) | |
tree | 2de2b48df47a89f71f0060708b509a62d4f384a2 /Makefile.inc1 | |
parent | e9b7132b30b52817896360c59523c38464c4643f (diff) | |
download | src-test2-6d75a7a852fe046e3866858ff995447498904e95.tar.gz src-test2-6d75a7a852fe046e3866858ff995447498904e95.zip |
Support skipping 'make obj' tree-walk.
This is part of a larger effort for WITH_AUTO_OBJ and a WORLDFAST
option.
Sponsored by: Dell EMC Isilon
Notes
Notes:
svn path=/head/; revision=318105
Diffstat (limited to 'Makefile.inc1')
-rw-r--r-- | Makefile.inc1 | 35 |
1 files changed, 23 insertions, 12 deletions
diff --git a/Makefile.inc1 b/Makefile.inc1 index 34e55d7448f5..ba3d07c2fac7 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -310,6 +310,13 @@ CLEANDIR= cleandir NO_CLEAN= t .endif .endif +.if defined(NO_OBJ) || ${MK_AUTO_OBJ} == "yes" +NO_OBJ= t +NO_KERNELOBJ= t +.endif +.if !defined(NO_OBJ) +_obj= obj +.endif LOCAL_TOOL_DIRS?= PACKAGEDIR?= ${DESTDIR}/${DISTDIR} @@ -828,7 +835,11 @@ WMAKE_TGTS+= _worldtmp _legacy .if empty(SUBDIR_OVERRIDE) WMAKE_TGTS+= _bootstrap-tools .endif -WMAKE_TGTS+= _cleanobj _obj _build-tools _cross-tools +WMAKE_TGTS+= _cleanobj +.if !defined(NO_OBJ) +WMAKE_TGTS+= _obj +.endif +WMAKE_TGTS+= _build-tools _cross-tools WMAKE_TGTS+= _compiler-metadata WMAKE_TGTS+= _includes _libraries WMAKE_TGTS+= everything @@ -1610,7 +1621,7 @@ legacy: .PHONY .for _tool in tools/build ${_elftoolchain_libs} ${_+_}@${ECHODIR} "===> ${_tool} (obj,includes,all,install)"; \ cd ${.CURDIR}/${_tool}; \ - ${MAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} DIRPRFX=${_tool}/ obj; fi; \ ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX}/legacy includes; \ ${MAKE} DIRPRFX=${_tool}/ MK_INCLUDES=no all; \ ${MAKE} DIRPRFX=${_tool}/ MK_INCLUDES=no \ @@ -1766,7 +1777,7 @@ bootstrap-tools: .PHONY ${_bt}-${_tool}: .PHONY .MAKE ${_+_}@${ECHODIR} "===> ${_tool} (obj,all,install)"; \ cd ${.CURDIR}/${_tool}; \ - ${MAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} DIRPRFX=${_tool}/ obj; fi; \ ${MAKE} DIRPRFX=${_tool}/ all; \ ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX}/legacy install @@ -1805,7 +1816,7 @@ _rescue=rescue/rescue build-tools_${_tool}: .PHONY ${_+_}@${ECHODIR} "===> ${_tool} (obj,build-tools)"; \ cd ${.CURDIR}/${_tool}; \ - ${MAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} DIRPRFX=${_tool}/ obj; fi; \ ${MAKE} DIRPRFX=${_tool}/ build-tools build-tools: build-tools_${_tool} .endfor @@ -1814,7 +1825,7 @@ build-tools: build-tools_${_tool} build-tools_${_tool}: .PHONY ${_+_}@${ECHODIR} "===> ${_tool} (obj,all)"; \ cd ${.CURDIR}/${_tool}; \ - ${MAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} DIRPRFX=${_tool}/ obj; fi; \ ${MAKE} DIRPRFX=${_tool}/ all build-tools: build-tools_${_tool} .endfor @@ -1899,7 +1910,7 @@ cross-tools: .MAKE .PHONY ${_usb_tools} ${_+_}@${ECHODIR} "===> ${_tool} (obj,all,install)"; \ cd ${.CURDIR}/${_tool}; \ - ${MAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} DIRPRFX=${_tool}/ obj; fi; \ ${MAKE} DIRPRFX=${_tool}/ all; \ ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX} install .endfor @@ -1931,7 +1942,7 @@ native-xtools: .PHONY mkdir -p ${OBJTREE}/gperf_for_gcc/usr/bin ${_+_}@${ECHODIR} "===> ${_gperf} (obj,all,install)"; \ cd ${.CURDIR}/${_gperf}; \ - ${NXBMAKE} DIRPRFX=${_gperf}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${NXBMAKE} DIRPRFX=${_gperf}/ obj; fi; \ ${NXBMAKE} DIRPRFX=${_gperf}/ all; \ ${NXBMAKE} DIRPRFX=${_gperf}/ DESTDIR=${OBJTREE}/gperf_for_gcc install .endif @@ -2007,7 +2018,7 @@ native-xtools: .PHONY usr.sbin/chown ${_+_}@${ECHODIR} "===> ${_tool} (obj,all,install)"; \ cd ${.CURDIR}/${_tool}; \ - ${NXBMAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${NXBMAKE} DIRPRFX=${_tool}/ obj; fi; \ ${NXBMAKE} DIRPRFX=${_tool}/ all; \ ${NXBMAKE} DIRPRFX=${_tool}/ DESTDIR=${NXBDESTDIR} install .endfor @@ -2269,7 +2280,7 @@ ${_lib}__PL: .PHONY .MAKE .if exists(${.CURDIR}/${_lib}) ${_+_}@${ECHODIR} "===> ${_lib} (obj,all,install)"; \ cd ${.CURDIR}/${_lib}; \ - ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ obj; fi; \ ${MAKE} MK_TESTS=no MK_PROFILE=no -DNO_PIC \ DIRPRFX=${_lib}/ all; \ ${MAKE} MK_TESTS=no MK_PROFILE=no -DNO_PIC \ @@ -2282,7 +2293,7 @@ ${_lib}__L: .PHONY .MAKE .if exists(${.CURDIR}/${_lib}) ${_+_}@${ECHODIR} "===> ${_lib} (obj,all,install)"; \ cd ${.CURDIR}/${_lib}; \ - ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ obj; fi; \ ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ all; \ ${MAKE} MK_TESTS=no DIRPRFX=${_lib}/ install .endif @@ -2609,7 +2620,7 @@ _xb-bootstrap-tools: .PHONY ${_yacc} ${_+_}@${ECHODIR} "===> ${_tool} (obj,all,install)"; \ cd ${.CURDIR}/${_tool}; \ - ${CDMAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${CDMAKE} DIRPRFX=${_tool}/ obj; fi; \ ${CDMAKE} DIRPRFX=${_tool}/ all; \ ${CDMAKE} DIRPRFX=${_tool}/ DESTDIR=${CDTMP} install .endfor @@ -2628,7 +2639,7 @@ _xb-cross-tools: .PHONY ${_gcc} ${_+_}@${ECHODIR} "===> xdev ${_tool} (obj,all)"; \ cd ${.CURDIR}/${_tool}; \ - ${CDMAKE} DIRPRFX=${_tool}/ obj; \ + if [ -z "${NO_OBJ}" ]; then ${CDMAKE} DIRPRFX=${_tool}/ obj; fi; \ ${CDMAKE} DIRPRFX=${_tool}/ all .endfor |