Provide knob NO_INSTALLEXTRAKERNELS. If defined, extra kernels in KERNCONF

won't be installed, only the first one would.
This commit is contained in:
Gleb Smirnoff 2016-01-06 21:58:45 +00:00
parent 2332dd9492
commit b46e917554

View File

@ -1230,7 +1230,7 @@ reinstallkernel reinstallkernel.debug: _installcheck_kernel
${CROSSENV} PATH=${TMPPATH} \
${MAKE} ${IMAKE_INSTALL} KERNEL=${INSTKERNNAME} ${.TARGET:S/kernel//}
.endif
.if ${BUILDKERNELS:[#]} > 1
.if ${BUILDKERNELS:[#]} > 1 && !defined(NO_INSTALLEXTRAKERNELS)
.for _kernel in ${BUILDKERNELS:[2..-1]}
@echo "--------------------------------------------------------------"
@echo ">>> Installing kernel ${_kernel}"
@ -1261,7 +1261,7 @@ distributekernel distributekernel.debug:
${DESTDIR}/${DISTDIR}/kernel.meta
.endif
.endif
.if ${BUILDKERNELS:[#]} > 1
.if ${BUILDKERNELS:[#]} > 1 && !defined(NO_INSTALLEXTRAKERNELS)
.for _kernel in ${BUILDKERNELS:[2..-1]}
.if defined(NO_ROOT)
echo "#${MTREE_MAGIC}" > ${DESTDIR}/${DISTDIR}/kernel.${_kernel}.premeta
@ -1292,7 +1292,7 @@ packagekernel:
tar cvf - --include '*/*/*.debug' \
@${DESTDIR}/${DISTDIR}/kernel.meta | \
${XZ_CMD} > ${DESTDIR}/${DISTDIR}/kernel-dbg.txz
.if ${BUILDKERNELS:[#]} > 1
.if ${BUILDKERNELS:[#]} > 1 && !defined(NO_INSTALLEXTRAKERNELS)
.for _kernel in ${BUILDKERNELS:[2..-1]}
cd ${DESTDIR}/${DISTDIR}/kernel.${_kernel}; \
tar cvf - --exclude '*.debug' \
@ -1313,7 +1313,7 @@ packagekernel:
cd ${DESTDIR}/${DISTDIR}/kernel; \
tar cvf - --include '*/*/*.debug' $$(eval find .) | \
${XZ_CMD} > ${DESTDIR}/${DISTDIR}/kernel-dbg.txz
.if ${BUILDKERNELS:[#]} > 1
.if ${BUILDKERNELS:[#]} > 1 && !defined(NO_INSTALLEXTRAKERNELS)
.for _kernel in ${BUILDKERNELS:[2..-1]}
cd ${DESTDIR}/${DISTDIR}/kernel.${_kernel}; \
tar cvf - --exclude '*.debug' . | \