packages: Allow actually building individual world packages in parallel.

MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
This commit is contained in:
Bryan Drewery 2017-06-23 18:26:54 +00:00
parent 48c22674a8
commit f77b03aa2b

View File

@ -1572,22 +1572,32 @@ create-world-packages: _pkgbootstrap .PHONY
@for plist in ${WSTAGEDIR}/*.plist; do \
plist=$${plist##*/} ; \
pkgname=$${plist%.plist} ; \
sh ${SRCDIR}/release/packages/generate-ucl.sh -o $${pkgname} \
-s ${SRCDIR} -u ${WSTAGEDIR}/$${pkgname}.ucl ; \
done
@for plist in ${WSTAGEDIR}/*.plist; do \
plist=$${plist##*/} ; \
pkgname=$${plist%.plist} ; \
awk -F\" ' \
echo "_PKGS+= $${pkgname}" ; \
done > ${WSTAGEDIR}/packages.mk
${_+_}@cd ${.CURDIR}; \
${MAKE} -f Makefile.inc1 create-world-packages-jobs \
.MAKE.JOB.PREFIX=
.if make(create-world-packages-jobs)
.include "${WSTAGEDIR}/packages.mk"
.endif
create-world-packages-jobs: .PHONY
.for pkgname in ${_PKGS}
create-world-packages-jobs: create-world-package-${pkgname}
create-world-package-${pkgname}: .PHONY
@sh ${SRCDIR}/release/packages/generate-ucl.sh -o ${pkgname} \
-s ${SRCDIR} -u ${WSTAGEDIR}/${pkgname}.ucl
@awk -F\" ' \
/^name/ { printf("===> Creating %s-", $$2); next } \
/^version/ { print $$2; next } \
' ${WSTAGEDIR}/$${pkgname}.ucl ; \
' ${WSTAGEDIR}/${pkgname}.ucl ; \
${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh -o ALLOW_BASE_SHLIBS=yes \
create -M ${WSTAGEDIR}/$${pkgname}.ucl \
-p ${WSTAGEDIR}/$${pkgname}.plist \
create -M ${WSTAGEDIR}/${pkgname}.ucl \
-p ${WSTAGEDIR}/${pkgname}.plist \
-r ${WSTAGEDIR} \
-o ${REPODIR}/$$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI)/${PKG_VERSION} ; \
done
-o ${REPODIR}/$$(${PKG_CMD} -o ABI_FILE=${WSTAGEDIR}/bin/sh config ABI)/${PKG_VERSION}
.endfor
create-kernel-packages: _pkgbootstrap .PHONY
.if exists(${KSTAGEDIR}/kernel.meta)