[Ovirt-devel] [PATCH] added make recipe target
David Huff
dhuff at redhat.com
Wed Jul 29 00:14:51 UTC 2009
---
Makefile.am | 34 +++++++++++++++++++++++++++++++---
1 files changed, 31 insertions(+), 3 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 2be9146..5cefa83 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -32,14 +32,16 @@ ARCH = $(shell rpm --eval '%{_arch}')
CUR_PREVIEW = 11
PREVIEW_URL ?= http://markmc.fedorapeople.org/virt-preview/f$(CUR_PREVIEW)/$(ARCH)
+RECIPE = ovirt-node-recipe
NVR = $(PACKAGE)-$(VERSION)-$(ARCH)
+RECIPE_PACKAGE = $(RECIPE)-$(VERSION)
EXTRA_DIST = \
.gitignore \
$(PACKAGE).spec \
$(PACKAGE).spec.in \
- ovirt-node-recipe.spec \
- ovirt-node-recipe.spec.in \
+ $(RECIPE).spec \
+ $(RECIPE).spec.in \
common-blacklist.ks \
common-install.ks \
common-pkgs.ks \
@@ -186,14 +188,40 @@ source: src.ks
> $(PACKAGE)-source-$(VERSION).$(SRC_FMT).$(SUM)
rpms: dist node
+# fixme hack two specs
+ ( \
+ gunzip $(distdir).tar.gz; \
+ tar --delete $(PACKAGE)-$(VERSION)/$(RECIPE).spec -f $(distdir).tar; \
+ gzip $(distdir).tar; \
+ )
+# fixme hack two specs
rpmbuild $(RPM_FLAGS) -ts $(distdir).tar.gz
rpmbuild $(RPM_FLAGS) --define "source_iso 1" -tb $(distdir).tar.gz
+
+recipe: dist node
+
+ ksflatten $(PACKAGE).ks --output $(RECIPE).ks
+ tar -zcvf $(RECIPE_PACKAGE).tar.gz tools $(PACKAGE)-manifests.tar $(RECIPE).ks $(RECIPE).spec
+ rpmbuild $(RPM_FLAGS) -ta $(RECIPE_PACKAGE).tar.gz
srpms: dist
- rpmbuild $(RPM_FLAGS) -ts $(distdir).tar.gz
+# fixme hack two specs
+ ( \
+ gunzip $(distdir).tar.gz; \
+ tar --delete $(PACKAGE)-$(VERSION)/$(RECIPE).spec -f $(distdir).tar; \
+ gzip $(distdir).tar; \
+ )
+# fixme hack two specs rpmbuild $(RPM_FLAGS) -ts $(distdir).tar.gz
$(MAKE) _publish
iso_srpms: dist
+# fixme hack two specs
+ ( \
+ gunzip $(distdir).tar.gz; \
+ tar --delete $(PACKAGE)-$(VERSION)/$(RECIPE).spec -f $(distdir).tar; \
+ gzip $(distdir).tar; \
+ )
+# fixme hack two specs
rpmbuild $(RPM_FLAGS) --define "source_iso 1" -ts $(distdir).tar.gz
$(MAKE) _publish
--
1.6.0.6
More information about the ovirt-devel
mailing list