| version 1.129, 2001/09/21 21:01:13 |
version 1.130, 2001/09/22 05:37:17 |
|
|
| # buildstartmsg: displays the start time of the build. |
# buildstartmsg: displays the start time of the build. |
| # beforeinstall: creates the distribution directories. |
# beforeinstall: creates the distribution directories. |
| # do-force-domestic: check's that FORCE_DOMESTIC isn't set (deprecated.) |
# do-force-domestic: check's that FORCE_DOMESTIC isn't set (deprecated.) |
| # do-share-mk: installs /usr/share/mk files. |
|
| # do-cleandir: cleans the tree. |
# do-cleandir: cleans the tree. |
| # do-make-obj: creates object directories if required. |
# do-make-obj: creates object directories if required. |
| # do-make-tools: builds host toolchain. |
# do-make-tools: builds host toolchain. |
|
|
| _J= -j${NBUILDJOBS} |
_J= -j${NBUILDJOBS} |
| .endif |
.endif |
| |
|
| .if defined(DESTDIR) |
|
| _M=-m ${DESTDIR}/usr/share/mk |
|
| .endif |
|
| |
|
| # NOTE THAT etc *DOES NOT* BELONG IN THE LIST BELOW |
# NOTE THAT etc *DOES NOT* BELONG IN THE LIST BELOW |
| |
|
| SUBDIR+= lib include bin libexec sbin usr.bin usr.sbin share sys |
SUBDIR+= lib include bin libexec sbin usr.bin usr.sbin share sys |
|
|
| @echo -n "Build finished at: " |
@echo -n "Build finished at: " |
| @date |
@date |
| |
|
| # If sharesrc is around, use its share/mk files to bootstrap until the |
|
| # mk files are installed (first step of make build). If installing to |
|
| # DESTDIR, don't bother, since the build will fail later on anyway. |
|
| |
|
| beforeinstall: |
beforeinstall: |
| .ifndef NODISTRIBDIRS |
.ifndef NODISTRIBDIRS |
| .ifndef DESTDIR |
.ifndef DESTDIR |
| .if exists(share/mk) |
(cd ${.CURDIR}/etc && ${MAKE} ${_M} DESTDIR=/ distrib-dirs) |
| (cd ${.CURDIR}/etc && \ |
|
| ${MAKE} -m ${.CURDIR}/share/mk DESTDIR=/ distrib-dirs) |
|
| .else |
.else |
| (cd ${.CURDIR}/etc && ${MAKE} DESTDIR=/ distrib-dirs) |
(cd ${.CURDIR}/etc && ${MAKE} ${_M} DESTDIR=${DESTDIR} distrib-dirs) |
| .endif |
|
| .else |
|
| (cd ${.CURDIR}/etc && ${MAKE} DESTDIR=${DESTDIR} distrib-dirs) |
|
| .endif |
.endif |
| .endif |
.endif |
| |
|
|
|
| @${MAKE} ${_M} buildstartmsg |
@${MAKE} ${_M} buildstartmsg |
| @${MAKE} ${_M} beforeinstall |
@${MAKE} ${_M} beforeinstall |
| @${MAKE} ${_M} do-force-domestic |
@${MAKE} ${_M} do-force-domestic |
| @${MAKE} ${_M} do-share-mk |
|
| @${MAKE} ${_M} do-cleandir |
@${MAKE} ${_M} do-cleandir |
| @${MAKE} ${_M} do-make-obj |
@${MAKE} ${_M} do-make-obj |
| @${MAKE} ${_M} do-make-tools |
@${MAKE} ${_M} do-make-tools |
| Line 167 do-force-domestic: |
|
| Line 152 do-force-domestic: |
|
| @false |
@false |
| .endif |
.endif |
| |
|
| do-share-mk: |
|
| .if ${MKSHARE} != "no" |
|
| (cd ${.CURDIR}/share/mk && ${MAKE} install) |
|
| .endif |
|
| |
|
| do-cleandir: |
do-cleandir: |
| .if !defined(UPDATE) && !defined(NOCLEANDIR) |
.if !defined(UPDATE) && !defined(NOCLEANDIR) |
| ${MAKE} ${_J} ${_M} cleandir |
${MAKE} ${_J} ${_M} cleandir |
|
|
| do-make-obj: |
do-make-obj: |
| .if ${MKOBJDIRS} != "no" |
.if ${MKOBJDIRS} != "no" |
| ${MAKE} ${_J} ${_M} obj |
${MAKE} ${_J} ${_M} obj |
| .if defined(USE_NEW_TOOLCHAIN) |
|
| cd ${.CURDIR}/tools && ${MAKE} ${_M} obj |
cd ${.CURDIR}/tools && ${MAKE} ${_M} obj |
| .endif |
.endif |
| .endif |
|
| |
|
| do-make-tools: |
do-make-tools: |
| .if defined(USE_NEW_TOOLCHAIN) |
|
| cd ${.CURDIR}/tools && ${MAKE} ${_M} build |
cd ${.CURDIR}/tools && ${MAKE} ${_M} build |
| .endif |
|
| |
|
| do-make-includes: |
do-make-includes: |
| .if !defined(NOINCLUDES) |
.if !defined(NOINCLUDES) |
| Line 229 includes-bin includes-games includes-lib |
|
| Line 205 includes-bin includes-games includes-lib |
|
| includes-sbin includes-usr.sbin: |
includes-sbin includes-usr.sbin: |
| @${TRUE} |
@${TRUE} |
| |
|
| |
.if !exists(${.CURDIR}/share/mk) |
| |
.BEGIN: |
| |
@echo 'BUILD ABORTED: share/mk does not exist, cannot run make.' |
| |
@false |
| |
.endif |
| |
|
| .include <bsd.subdir.mk> |
.include <bsd.subdir.mk> |
| |
|
| |
_M:= -m ${.CURDIR}/share/mk |