svn commit: r222074 - head/release

Nathan Whitehorn nwhitehorn at FreeBSD.org
Wed May 18 17:39:29 UTC 2011


Author: nwhitehorn
Date: Wed May 18 17:39:28 2011
New Revision: 222074
URL: http://svn.freebsd.org/changeset/base/222074

Log:
  As requested by many people, with final prodding from Jason Hall, fix this
  so that running make release causes make obj to be run before doing
  anything. This fixes a bug wherein, when run for the first time, and
  without -DNOSRC, make release would attempt to recursively tar up the src
  directory including its own output and enter an infinite loop.
  
  While here, make the cross-building stuff work a little more the way it
  should if only one of TARGET/TARGET_ARCH is specified.

Modified:
  head/release/Makefile
  head/release/generate-release.sh

Modified: head/release/Makefile
==============================================================================
--- head/release/Makefile	Wed May 18 17:18:44 2011	(r222073)
+++ head/release/Makefile	Wed May 18 17:39:28 2011	(r222074)
@@ -25,11 +25,11 @@ PORTSDIR?=	/usr/ports
 DOCDIR?=	/usr/doc
 RELNOTES_LANG?= en_US.ISO8859-1
 
-TARGET_ARCH?=	${MACHINE_ARCH}
-.if ${TARGET_ARCH} == ${MACHINE_ARCH}
 TARGET?=	${MACHINE}
+.if ${TARGET} == ${MACHINE}
+TARGET_ARCH?=	${MACHINE_ARCH}
 .else
-TARGET?=	${TARGET_ARCH}
+TARGET_ARCH?=	${TARGET}
 .endif
 IMAKE=		${MAKE} TARGET_ARCH=${TARGET_ARCH} TARGET=${TARGET}
 DISTDIR=	${.OBJDIR}/dist
@@ -169,7 +169,9 @@ ftp: packagesystem
 	mkdir ftp
 	cp *.txz MANIFEST ftp
 
-release: obj ${RELEASE_TARGETS}
+release:
+	${MAKE} -C ${.CURDIR} ${.MAKEFLAGS} obj
+	${MAKE} -C ${.CURDIR} ${.MAKEFLAGS} ${RELEASE_TARGETS}
 
 clean:
 	chflags -R noschg ${.OBJDIR}

Modified: head/release/generate-release.sh
==============================================================================
--- head/release/generate-release.sh	Wed May 18 17:18:44 2011	(r222073)
+++ head/release/generate-release.sh	Wed May 18 17:39:28 2011	(r222074)
@@ -63,7 +63,6 @@ if [ -d $2/usr/doc ]; then 
 fi
 
 chroot $2 make -C /usr/src $MAKE_FLAGS buildworld buildkernel
-chroot $2 make -C /usr/src/release obj
 chroot $2 make -C /usr/src/release release
 chroot $2 make -C /usr/src/release install DESTDIR=/R
 


More information about the svn-src-head mailing list