From 99e9e0351d741dac5a274d236f930108ef3ad98d Mon Sep 17 00:00:00 2001 From: Marek Marczykowski Date: Sun, 24 Feb 2013 13:33:57 +0100 Subject: [PATCH] makefile: Fix building many different template rpm packages at the same time Store build_timestamp for each built template to not mix them up in update-repo-installer. --- Makefile | 2 +- build_template_rpm | 1 + templates.spec | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index e3cfc4a..dac7b21 100644 --- a/Makefile +++ b/Makefile @@ -15,7 +15,7 @@ help: rpms: - @echo $(TIMESTAMP) > build_timestamp + @echo $(TIMESTAMP) > build_timestamp_$(DIST) @echo "Building template: $(TEMPLATE_NAME)" @createrepo -q -g $$PWD/comps-qubes-template.xml yum_repo_qubes/$(DIST) -o yum_repo_qubes/$(DIST) && \ sudo -E ./fedorize_image fedorized_images/$(TEMPLATE_NAME).img $(PKGLISTFILE) && \ diff --git a/build_template_rpm b/build_template_rpm index c63c8e1..c98a1c9 100755 --- a/build_template_rpm +++ b/build_template_rpm @@ -8,6 +8,7 @@ fi rpmbuild --target noarch \ --define "template_name $NAME" \ + --define "DIST $DIST" \ --define "_topdir $PWD/rpmbuild" \ --define "_tmppath $PWD/rpmbuild/tmp" \ -bb templates.spec diff --git a/templates.spec b/templates.spec index 3b3a99e..c0fc040 100644 --- a/templates.spec +++ b/templates.spec @@ -4,7 +4,7 @@ # %{!?version: %define version %(cat version)} -%{!?rel: %define rel %(cat build_timestamp)} +%{!?rel: %define rel %(cat build_timestamp_%{DIST})} Name: qubes-template-%{template_name} Version: %{version}