Pretend the template rpm is build the standard way

This allows to reuse standard update-repo-* and sign-* make targets.

QubesOS/qubes-issues#3935
This commit is contained in:
Marek Marczykowski-Górecki 2018-06-04 02:19:32 +02:00
parent ee42db95ec
commit a78fc2ddbb
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724
2 changed files with 9 additions and 2 deletions

5
Makefile.builder Normal file
View File

@ -0,0 +1,5 @@
# pretend that normal package is built from this repo, to reuse update-repo-*
ifeq ($(PACKAGE_SET),vm)
OUTPUT_DIR = rpm
RPM_SPEC_FILES = templates.spec
endif

View File

@ -3,8 +3,9 @@
# This includes the VM's root image, patched with all qubes rpms, etc # This includes the VM's root image, patched with all qubes rpms, etc
# #
%{!?version: %define version %(cat version)} %{!?template_name: %global template_name %{getenv:TEMPLATE_NAME}}
%{!?rel: %define rel %(cat build_timestamp_%{template_name})} %{!?version: %global version %(cat version)}
%{!?rel: %global rel %(cat build_timestamp_%{template_name} || echo unavailable)}
Name: qubes-template-%{template_name} Name: qubes-template-%{template_name}
Version: %{version} Version: %{version}
@ -17,6 +18,7 @@ Source: .
Requires: xdg-utils Requires: xdg-utils
Requires(post): tar Requires(post): tar
BuildArch: noarch
Provides: qubes-template Provides: qubes-template
Obsoletes: %{name} > %{version}-%{release} Obsoletes: %{name} > %{version}-%{release}