From owner-svn-src-all@freebsd.org Fri Mar 11 23:44:29 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2357EACD003; Fri, 11 Mar 2016 23:44:29 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D6E61335; Fri, 11 Mar 2016 23:44:28 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u2BNiRHa010350; Fri, 11 Mar 2016 23:44:27 GMT (envelope-from bdrewery@FreeBSD.org) Received: (from bdrewery@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u2BNiR5j010348; Fri, 11 Mar 2016 23:44:27 GMT (envelope-from bdrewery@FreeBSD.org) Message-Id: <201603112344.u2BNiR5j010348@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bdrewery set sender to bdrewery@FreeBSD.org using -f From: Bryan Drewery Date: Fri, 11 Mar 2016 23:44:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r296690 - in head: include share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.21 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: Fri, 11 Mar 2016 23:44:29 -0000 Author: bdrewery Date: Fri Mar 11 23:44:27 2016 New Revision: 296690 URL: https://svnweb.freebsd.org/changeset/base/296690 Log: DIRDEPS_BUILD: Remove the cookie when target is out-of-date. The meta file may decide the target is out of date but nothing ensures that the *next* build will build this target if it fails this time for some reason; it is still out-of-date until it succeeds. Convert the include/ cookie usage to the global versions. Sponsored by: EMC / Isilon Storage Division Modified: head/include/Makefile head/share/mk/local.sys.mk Modified: head/include/Makefile ============================================================================== --- head/include/Makefile Fri Mar 11 23:24:04 2016 (r296689) +++ head/include/Makefile Fri Mar 11 23:44:27 2016 (r296690) @@ -131,6 +131,7 @@ _MARCHS+= x86 .if ${MK_STAGING} == "yes" # tell bsd.incs.mk that we have it covered NO_STAGE_INCLUDES= +META_COOKIES+= stage_prep stage_include compat copies symlinks .endif .include @@ -157,6 +158,7 @@ ${SHARED}: compat # Take care of stale directory-level symlinks. compat: + ${META_COOKIE_RM} .for i in ${LDIRS} ${LSUBDIRS} machine ${_MARCHS} crypto if [ -L ${DESTDIR}${INCLUDEDIR}/$i ]; then \ rm -f ${DESTDIR}${INCLUDEDIR}/$i; \ @@ -165,11 +167,10 @@ compat: mtree -deU ${MTREE_FOLLOWS_SYMLINKS} \ -f ${.CURDIR}/../etc/mtree/BSD.include.dist \ -p ${DESTDIR}${INCLUDEDIR} > /dev/null -.if ${MK_DIRDEPS_BUILD} == "yes" - @touch ${.TARGET} -.endif + ${META_COOKIE_TOUCH} copies: + ${META_COOKIE_RM} .for i in ${LDIRS} ${LSUBDIRS} ${LSUBSUBDIRS} crypto machine machine/pc \ ${_MARCHS} if [ -d ${DESTDIR}${INCLUDEDIR}/$i ]; then \ @@ -254,11 +255,10 @@ copies: cd ${.CURDIR}/../sys/teken; \ ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 teken.h \ ${DESTDIR}${INCLUDEDIR}/teken -.if ${MK_DIRDEPS_BUILD} == "yes" - @touch ${.OBJDIR}/${.TARGET} -.endif + ${META_COOKIE_TOUCH} symlinks: + ${META_COOKIE_RM} @${ECHO} "Setting up symlinks to kernel source tree..." .for i in ${LDIRS} cd ${.CURDIR}/../sys/$i; \ @@ -371,9 +371,7 @@ symlinks: ${INSTALL_SYMLINK} ../../../sys/rpc/$$h \ ${DESTDIR}${INCLUDEDIR}/rpc; \ done -.if ${MK_DIRDEPS_BUILD} == "yes" - @touch ${.OBJDIR}/${.TARGET} -.endif + ${META_COOKIE_TOUCH} .if ${MACHINE} == "host" && !defined(_SKIP_BUILD) # we're here because we are building a sysroot... Modified: head/share/mk/local.sys.mk ============================================================================== --- head/share/mk/local.sys.mk Fri Mar 11 23:24:04 2016 (r296689) +++ head/share/mk/local.sys.mk Fri Mar 11 23:44:27 2016 (r296690) @@ -28,10 +28,14 @@ MAKE_PRINT_VAR_ON_ERROR += .MAKE.MAKEFIL .if ${.MAKE.MODE:Mmeta*} != "" # we can afford to use cookies to prevent some targets # re-running needlessly -META_COOKIE_TOUCH= touch ${COOKIE.${.TARGET}:U${.OBJDIR}/${.TARGET}} +META_COOKIE= ${COOKIE.${.TARGET}:U${.OBJDIR}/${.TARGET}} +META_COOKIE_RM= @rm -f ${META_COOKIE} +META_COOKIE_TOUCH= @touch ${META_COOKIE} # some targets need to be .PHONY - but not in meta mode META_NOPHONY= +CLEANFILES+= ${META_COOKIES} .else +META_COOKIE_RM= META_COOKIE_TOUCH= META_NOPHONY= .PHONY .endif