[csw-devel] SF.net SVN: gar:[15797] csw/mgar/gar/v2/gar.mk

skayser at users.sourceforge.net skayser at users.sourceforge.net
Wed Sep 28 23:36:19 CEST 2011


Revision: 15797
          http://gar.svn.sourceforge.net/gar/?rev=15797&view=rev
Author:   skayser
Date:     2011-09-28 21:36:19 +0000 (Wed, 28 Sep 2011)
Log Message:
-----------
gar/v2: prevent gmake's -I to leak into upstream builds

Modified Paths:
--------------
    csw/mgar/gar/v2/gar.mk

Modified: csw/mgar/gar/v2/gar.mk
===================================================================
--- csw/mgar/gar/v2/gar.mk	2011-09-28 19:16:27 UTC (rev 15796)
+++ csw/mgar/gar/v2/gar.mk	2011-09-28 21:36:19 UTC (rev 15797)
@@ -33,7 +33,12 @@
 #meant to take a git url and return just the $proj.git part
 GITPROJ = $(lastword $(subst /, ,$(1)))
 
-PARALLELMFLAGS ?= $(MFLAGS)
+# GAR uses PARALLELMFLAGS to propagate make options (judging by the name, mainly
+# intended for -j). Options are determined via MFLAGS which also contains other
+# options, thus we need to filter harmful ones. e.g. -I breaks upstream builds
+# that use non-gnu make (Fatal error: Unknown option `-I'). Info on M*FLAGS:
+# http://www.gnu.org/s/hello/manual/make/Options_002fRecursion.html
+PARALLELMFLAGS ?= $(shell echo $(MFLAGS) | gsed 's,-I [^ ]*,,g' )
 export PARALLELMFLAGS
 
 DISTNAME ?= $(NAME)-$(VERSION)

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list