Date: Tue, 16 Jun 2015 23:06:43 +0000 (UTC) From: "Simon J. Gerraty" <sjg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r284478 - head/share/mk Message-ID: <201506162306.t5GN6hMD060891@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: sjg Date: Tue Jun 16 23:06:43 2015 New Revision: 284478 URL: https://svnweb.freebsd.org/changeset/base/284478 Log: Normally a staging conflict causes an error. When bootstrapping different options, it is handy to be able to make those warnings. Modified: head/share/mk/meta.stage.mk Modified: head/share/mk/meta.stage.mk ============================================================================== --- head/share/mk/meta.stage.mk Tue Jun 16 23:03:15 2015 (r284477) +++ head/share/mk/meta.stage.mk Tue Jun 16 23:06:43 2015 (r284478) @@ -60,14 +60,23 @@ LN_CP_SCRIPT = LnCp() { \ ln $$1 $$2 2> /dev/null || \ cp -p $$1 $$2; } +# a staging conflict should cause an error +# a warning is handy when bootstapping different options. +STAGE_CONFLICT?= ERROR +.if ${STAGE_CONFLICT:tl} == "error" +STAGE_CONFLICT_ACTION= exit 1; +.else +STAGE_CONFLICT_ACTION= +.endif + # it is an error for more than one src dir to try and stage # the same file STAGE_DIRDEP_SCRIPT = ${LN_CP_SCRIPT}; StageDirdep() { \ t=$$1; \ if [ -s $$t.dirdep ]; then \ cmp -s .dirdep $$t.dirdep && return; \ - echo "ERROR: $$t installed by `cat $$t.dirdep` not ${_dirdep}" >&2; \ - exit 1; \ + echo "${STAGE_CONFLICT}: $$t installed by `cat $$t.dirdep` not ${_dirdep}" >&2; \ + ${STAGE_CONFLICT_ACTION} \ fi; \ LnCp .dirdep $$t.dirdep || exit 1; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201506162306.t5GN6hMD060891>