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

dmichelsen at users.sourceforge.net dmichelsen at users.sourceforge.net
Fri Feb 26 09:51:26 CET 2010


Revision: 8830
          http://gar.svn.sourceforge.net/gar/?rev=8830&view=rev
Author:   dmichelsen
Date:     2010-02-26 08:51:26 +0000 (Fri, 26 Feb 2010)

Log Message:
-----------
mGAR v2: Bail out if given alternative is empty

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

Modified: csw/mgar/gar/v2/gar.pkg.mk
===================================================================
--- csw/mgar/gar/v2/gar.pkg.mk	2010-02-25 19:15:45 UTC (rev 8829)
+++ csw/mgar/gar/v2/gar.pkg.mk	2010-02-26 08:51:26 UTC (rev 8830)
@@ -692,8 +692,11 @@
 merge-alternatives-%:
 	@echo "[ Generating alternatives for package $* ]"
 	$(_DBG)ginstall -d $(PKGROOT)/opt/csw/share/alternatives
-	$(_DBG)($(foreach A,$(or $(ALTERNATIVES_$*),$(ALTERNATIVES)),echo "$(ALTERNATIVE_$A)";)) \
-		> $(PKGROOT)/opt/csw/share/alternatives/$(call catalogname,$*)
+	$(_DBG)($(foreach A,$(or $(ALTERNATIVES_$*),$(ALTERNATIVES)), \
+		$(if $(ALTERNATIVE_$A), \
+			echo "$(ALTERNATIVE_$A)";, \
+			$(error The variable 'ALTERNATIVE_$A' is empty, but must contain an alternative) \
+		))) > $(PKGROOT)/opt/csw/share/alternatives/$(call catalogname,$*)
 	@$(MAKECOOKIE)
 
 merge-alternatives: $(foreach S,$(SPKG_SPECS),$(if $(or $(ALTERNATIVES_$S),$(ALTERNATIVES)),merge-alternatives-$S))


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