From owner-svn-src-all@FreeBSD.ORG Wed Mar 2 14:39:26 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CF45F1065672; Wed, 2 Mar 2011 14:39:26 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BCA228FC13; Wed, 2 Mar 2011 14:39:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p22EdQEQ015429; Wed, 2 Mar 2011 14:39:26 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p22EdQsU015424; Wed, 2 Mar 2011 14:39:26 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201103021439.p22EdQsU015424@svn.freebsd.org> From: Nathan Whitehorn Date: Wed, 2 Mar 2011 14:39:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r219177 - in head: . games release release/scripts X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Mar 2011 14:39:26 -0000 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 ============================================================================== --- head/Makefile Wed Mar 2 13:06:47 2011 (r219176) +++ head/Makefile Wed Mar 2 14:39:26 2011 (r219177) @@ -89,9 +89,11 @@ TGTS= all all-man buildenv buildenvvars check-old check-old-dirs check-old-files check-old-libs \ checkdpadd clean cleandepend cleandir \ delete-old delete-old-dirs delete-old-files delete-old-libs \ - depend distribute distributeworld distrib-dirs distribution doxygen \ + depend distribute distributekernel distributekernel.debug \ + distributeworld distrib-dirs distribution doxygen \ everything hierarchy install installcheck installkernel \ - installkernel.debug reinstallkernel reinstallkernel.debug \ + installkernel.debug packagekernel packageworld \ + reinstallkernel reinstallkernel.debug \ installworld kernel-toolchain libraries lint maninstall \ obj objlink regress rerelease showconfig tags toolchain update \ _worldtmp _legacy _bootstrap-tools _cleanobj _obj \ 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 # # Installs everything compiled by a 'buildworld'. # + +# Non-base distributions produced by the base system +EXTRA_DISTRIBUTIONS= doc games +.if defined(LIB32TMP) && ${MK_LIB32} != "no" +EXTRA_DISTRIBUTIONS+= lib32 +.endif + distributeworld installworld: installcheck mkdir -p ${INSTALLTMP} progs=$$(for prog in ${ITOOLS}; do \ @@ -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 # Modified: head/games/Makefile.inc ============================================================================== --- head/games/Makefile.inc Wed Mar 2 13:06:47 2011 (r219176) +++ head/games/Makefile.inc Wed Mar 2 14:39:26 2011 (r219177) @@ -4,3 +4,4 @@ BINDIR?= /usr/games FILESDIR?= ${SHAREDIR}/games WARNS?= 6 +DISTRIBUTION?= games Modified: head/release/Makefile ============================================================================== --- head/release/Makefile Wed Mar 2 13:06:47 2011 (r219176) +++ head/release/Makefile Wed Mar 2 14:39:26 2011 (r219177) @@ -194,8 +194,8 @@ DIST_DOCS_ARCH_DEP= # Things which without too much trouble can be considered variables # BASE_DISTS are special in that they get full /etc installation sets. # -OTHER_DISTS?= catpages manpages games proflibs dict info doc ${ARCH_DISTS} -BASE_DISTS?= base +OTHER_DISTS?= catpages manpages proflibs dict info +BASE_DISTS?= base doc games ${ARCH_DISTS} .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" ARCH_DISTS?= lib32 .endif @@ -647,9 +647,7 @@ release.1: mtree -deU -f ${MTREEFILES}/BSD.usr.dist \ -p ${RD}/trees/$$i/usr > /dev/null && \ mtree -deU -f ${MTREEFILES}/BSD.include.dist \ - -p ${RD}/trees/$$i/usr/include > /dev/null && \ - mtree -deU -f ${MTREEFILES}/BSD.var.dist \ - -p ${RD}/trees/$$i/var > /dev/null ; \ + -p ${RD}/trees/$$i/usr/include > /dev/null; \ done mkdir ${RD}/kernels for i in ${KERNELS_BASE} ${KERNELS}; do \