svn commit: r219177 - in head: . games release release/scripts
Nathan Whitehorn
nwhitehorn at freebsd.org
Wed Jul 23 16:53:44 UTC 2014
On 07/23/14 09:34, Bjoern A. Zeeb wrote:
> On 02 Mar 2011, at 14:39 , Nathan Whitehorn <nwhitehorn at freebsd.org> wrote:
>
>> Author: nwhitehorn
>> Date: Wed Mar 2 14:39:26 2011
>> New Revision: 219177
>> URL: http://svn.freebsd.org/changeset/base/219177
>>
>> Log:
>> Improve the distributeworld target in Makefile.inc1 and update the release
>> infrastructure to use it. make distributeworld can now be used without
>> preparing its environment first and installs games into its distribution
>> using the regular make distribute logic instead of post-processing with
>> a script.
>>
>> Also add two new targets, packageworld and packagekernel, that tar up the
>> results of distributeworld and distributekernel (also new), respectively.
>>
>> Deleted:
>> head/release/scripts/games-make.sh
>> head/release/scripts/lib32-make.sh
>> Modified:
>> head/Makefile
>> head/Makefile.inc1
>> head/games/Makefile.inc
>> head/release/Makefile
> ..
>
>> Modified: head/Makefile.inc1
>> ==============================================================================
>> --- head/Makefile.inc1 Wed Mar 2 13:06:47 2011 (r219176)
>> +++ head/Makefile.inc1 Wed Mar 2 14:39:26 2011 (r219177)
>> @@ -631,6 +631,13 @@ ITOOLS= [ awk cap_mkdb cat chflags chmod
>> …
>
>> @@ -653,8 +660,33 @@ distributeworld installworld: installche
>> done); \
>> cp $$libs $$progs ${INSTALLTMP}
>> cp -R $${PATH_LOCALE:-"/usr/share/locale"} ${INSTALLTMP}/locale
>> +.if make(distributeworld)
>> +.for dist in ${EXTRA_DISTRIBUTIONS}
>> + -mkdir ${DESTDIR}/${DISTDIR}/${dist}
>> + mtree -deU -f ${.CURDIR}/etc/mtree/BSD.root.dist \
>> + -p ${DESTDIR}/${DISTDIR}/${dist} >/dev/null
>> + mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \
>> + -p ${DESTDIR}/${DISTDIR}/${dist}/usr >/dev/null
>> + mtree -deU -f ${.CURDIR}/etc/mtree/BSD.include.dist \
>> + -p ${DESTDIR}/${DISTDIR}/${dist}/usr/include >/dev/null
>> +.endfor
>> + -mkdir ${DESTDIR}/${DISTDIR}/base
>> + ${_+_}cd ${.CURDIR}; ${IMAKE} distrib-dirs \
>> + DESTDIR=${DESTDIR}/${DISTDIR}/base
>> +.endif
>> ${_+_}cd ${.CURDIR}; ${IMAKE} re${.TARGET:S/world$//}; \
>> ${IMAKEENV} rm -rf ${INSTALLTMP}
>> +.if make(distributeworld)
>> +.for dist in ${EXTRA_DISTRIBUTIONS}
>> + find ${DESTDIR}/${DISTDIR}/${dist} -empty -delete
>> +.endfor
>> +.endif
>> +
>> +packageworld:
>> +.for dist in base ${EXTRA_DISTRIBUTIONS}
>> + ${_+_}cd ${DESTDIR}/${DISTDIR}/${dist}; \
>> + tar cvJf ${DESTDIR}/${DISTDIR}/${dist}.txz .
>> +.endfor
>>
>> #
>> # reinstall
>> @@ -840,6 +872,20 @@ reinstallkernel reinstallkernel.debug: i
>> ${CROSSENV} PATH=${TMPPATH} \
>> ${MAKE} KERNEL=${INSTKERNNAME} ${.TARGET:S/kernel//}
>>
>> +distributekernel distributekernel.debug:
>> +.if empty(INSTALLKERNEL)
>> + @echo "ERROR: No kernel \"${KERNCONF}\" to install."; \
>> + false
>> +.endif
>> + cd ${KRNLOBJDIR}/${INSTALLKERNEL}; \
>> + ${CROSSENV} PATH=${TMPPATH} ${MAKE} KERNEL=${INSTKERNNAME} \
>> + DESTDIR=${DESTDIR}/${DISTDIR}/kernel \
>> + ${.TARGET:S/distributekernel/install/}
>> +
>> +packagekernel:
>> + ${_+_}cd ${DESTDIR}/${DISTDIR}/kernel; \
>> + tar cvJf ${DESTDIR}/${DISTDIR}/kernel.txz .
>> +
>> #
>> # doxygen
>> #
> This is where DISTDIR was introduced it seems. I guess it only became a real issue for me with NO_ROOT changes I use. In addition it probably doesn’t help that (not on the currently observed system) I also build world images from ports.
>
> Unfortunately this collides with:
>
> /usr/ports/Mk/bsd.port.mk:# DISTDIR - Where to search for and store copies of original sources
> /usr/ports/Mk/bsd.port.mk:DISTDIR?= ${PORTSDIR}/distfiles
>
> That a lot of people I know have set in their environment, and done so in a decade.
>
> Just wondering if it’s worth avoiding the obvious by renaming it in base?
>
Yes, I think you're right. Could you rename it? It's used only in the
scripts in this commit, so far as I know.
-Nathan
More information about the svn-src-head
mailing list