common Makefile.common,1.57,1.58

Jesse Keating (jkeating) fedora-extras-commits at redhat.com
Fri May 18 18:25:32 UTC 2007


Author: jkeating

Update of /cvs/pkgs/common
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv16424

Modified Files:
	Makefile.common 
Log Message:
Add a 'local' target to build locally without having to guess the arch (#202225)



Index: Makefile.common
===================================================================
RCS file: /cvs/pkgs/common/Makefile.common,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -r1.57 -r1.58
--- Makefile.common	18 May 2007 18:04:13 -0000	1.57
+++ Makefile.common	18 May 2007 18:25:32 -0000	1.58
@@ -139,7 +139,7 @@
 PREP_ARCHES	= $(addprefix prep-,$(ARCHES))
 
 ## list all our bogus targets
-.PHONY :: $(ARCHES) sources uploadsource upload export check build-check plague koji build test-srpm srpm tag force-tag verrel new clean patch prep compile install-short compile-short FORCE
+.PHONY :: $(ARCHES) sources uploadsource upload export check build-check plague koji build test-srpm srpm tag force-tag verrel new clean patch prep compile install-short compile-short FORCE local
 
 # The TARGETS define is meant for local module targets that should be
 # made in addition to the SOURCEFILES whenever needed
@@ -281,6 +281,9 @@
 # empty target to force checking of md5sums in FULLSOURCEFILES
 FORCE:
 
+# build whatever's appropriate for the local architecture
+local: $(if $(shell grep -i '^BuildArch:.*noarch' $(SPECFILE)), noarch, $(shell uname -m))
+
 # attempt to apply all the patches, optionally only for a particular arch
 ifdef PREPARCH
 prep: sources $(TARGETS)
@@ -456,6 +459,7 @@
 	@echo "	upload FILES=<files>	Add <files> to CVS"
 	@echo "	new-sources FILES=<files>	Replace sources in CVS with <files>"
 	@echo "	<arch>			Local test rpmbuild binary"
+	@echo "	local			Local test rpmbuild binary"
 	@echo "	prep			Local test rpmbuild prep"
 	@echo "	compile			Local test rpmbuild compile"
 	@echo "	compile-short		Local test rpmbuild short-circuit compile"




More information about the fedora-extras-commits mailing list