From owner-svn-src-head@FreeBSD.ORG Sun Sep 15 20:16:41 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id AA94BF60; Sun, 15 Sep 2013 20:16:41 +0000 (UTC) (envelope-from jilles@stack.nl) Received: from mx1.stack.nl (unknown [IPv6:2001:610:1108:5012::107]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 67F682396; Sun, 15 Sep 2013 20:16:41 +0000 (UTC) Received: from turtle.stack.nl (turtle.stack.nl [IPv6:2001:610:1108:5010::132]) by mx1.stack.nl (Postfix) with ESMTP id 0961D1203C2; Sun, 15 Sep 2013 22:16:24 +0200 (CEST) Received: by turtle.stack.nl (Postfix, from userid 1677) id 00743CB4E; Sun, 15 Sep 2013 22:16:23 +0200 (CEST) Date: Sun, 15 Sep 2013 22:16:23 +0200 From: Jilles Tjoelker To: Joel Dahl Subject: Re: svn commit: r254273 - in head: . include lib lib/libc/iconv lib/libiconv_compat lib/libkiconv share/mk sys/sys tools/build/mk Message-ID: <20130915201623.GA28602@stack.nl> References: <201308130715.r7D7F1nu076335@svn.freebsd.org> <20130822155835.GA52789@devbox.vnode.local> <20130903195241.GA93218@devbox.vnode.local> <201309051013.35286.jhb@freebsd.org> <20130905201540.GA23637@devbox.vnode.local> <20130912221927.GA473@stack.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20130912221927.GA473@stack.nl> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: src-committers@freebsd.org, John Baldwin , Peter Wemm , svn-src-all@freebsd.org, Dimitry Andric , gabor@freebsd.org, svn-src-head@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Sep 2013 20:16:41 -0000 On Fri, Sep 13, 2013 at 12:19:27AM +0200, Jilles Tjoelker wrote: > On Thu, Sep 05, 2013 at 10:15:40PM +0200, Joel Dahl wrote: > > Installworld is still broken on systems with readonly /usr/obj. > I use this. It makes the mapper.dir and similar files depend on their > actual sources instead of phony targets, and therefore only rebuilt when > needed. The previous patch had some problems (two makes in parallel in the same directory, no rebuild when the sources of the $i/foo.$i files changed in -DNOCLEAN mode). This patch should work better. It avoids changing the targets and instead leaves the destination file untouched if the content remains the same. Index: share/i18n/csmapper/Makefile =================================================================== --- share/i18n/csmapper/Makefile (revision 255570) +++ share/i18n/csmapper/Makefile (working copy) @@ -7,10 +7,11 @@ KAZAKH KOI KS MISC TCVN mapper.dir: ${SUBDIR} - > ${.TARGET} -.for i in ${SUBDIR} - cat ${i}/mapper.dir.${i} >> ${.TARGET} -.endfor + newfile=$$(for i in ${SUBDIR}; do \ + cat $$i/mapper.dir.$$i; \ + done); \ + [ "$$newfile" = "$$(cat ${.TARGET} 2>/dev/null)" ] || \ + printf '%s\n' "$$newfile" >${.TARGET} mapper.dir.db: mapper.dir ${MKCSMAPPER} -m -o ${.TARGET} ${.ALLSRC} @@ -18,10 +19,11 @@ CLEANFILES+= mapper.dir mapper.dir.db charset.pivot: ${SUBDIR} - > ${.TARGET} -.for i in ${SUBDIR} - cat ${i}/charset.pivot.${i} >> ${.TARGET} -.endfor + newfile=$$(for i in ${SUBDIR}; do \ + cat $$i/charset.pivot.$$i; \ + done); \ + [ "$$newfile" = "$$(cat ${.TARGET} 2>/dev/null)" ] || \ + printf '%s\n' "$$newfile" >${.TARGET} charset.pivot.pvdb: charset.pivot ${MKCSMAPPER} -p -o ${.TARGET} ${.ALLSRC} Index: share/i18n/esdb/Makefile =================================================================== --- share/i18n/esdb/Makefile (revision 255570) +++ share/i18n/esdb/Makefile (working copy) @@ -10,18 +10,20 @@ CLEANFILES= ${FILES} esdb.dir: ${SUBDIR} - > $@ -.for i in ${SUBDIR} - cat ${i}/esdb.dir.${i} >>${.TARGET} -.endfor + newfile=$$(for i in ${SUBDIR}; do \ + cat $$i/esdb.dir.$$i; \ + done); \ + [ "$$newfile" = "$$(cat ${.TARGET} 2>/dev/null)" ] || \ + printf '%s\n' "$$newfile" >${.TARGET} esdb.dir.db: esdb.dir ${MKESDB} -m -o ${.TARGET} ${.ALLSRC} esdb.alias: ${SUBDIR} - > $@ -.for i in ${SUBDIR} - cat ${i}/esdb.alias.${i} >>${.TARGET} -.endfor + newfile=$$(for i in ${SUBDIR}; do \ + cat $$i/esdb.alias.$$i; \ + done); \ + [ "$$newfile" = "$$(cat ${.TARGET} 2>/dev/null)" ] || \ + printf '%s\n' "$$newfile" >${.TARGET} esdb.alias.db: esdb.alias ${MKESDB} -m -o ${.TARGET} ${.ALLSRC} -- Jilles Tjoelker