adjust macros to get correct version

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
This commit is contained in:
Lokesh Mandvekar 2022-10-04 13:39:50 -04:00
parent 7b2c822c51
commit 52c20e5f2a

View File

@ -4,18 +4,20 @@
# debuginfo doesn't work yet # debuginfo doesn't work yet
%global debug_package %{nil} %global debug_package %{nil}
%global built_tag_strip 1.2.0 %global built_tag v1.2.0
%global built_tag_strip %(b=%{built_tag}; echo ${b:1})
%global gen_version %(b=%{built_tag_strip}; echo ${b/-/"~"})
Name: aardvark-dns Name: aardvark-dns
Version: 1.2.0 Version: %{gen_version}
License: ASL 2.0 and BSD and MIT License: ASL 2.0 and BSD and MIT
Release: %autorelease Release: %autorelease
ExclusiveArch: %{rust_arches} ExclusiveArch: %{rust_arches}
Summary: Authoritative DNS server for A/AAAA container records Summary: Authoritative DNS server for A/AAAA container records
URL: https://github.com/containers/%{name} URL: https://github.com/containers/%{name}
# Tarballs fetched from upstream's release page # Tarballs fetched from upstream's release page
Source0: %{url}/archive/v%{built_tag_strip}.tar.gz Source0: %{url}/archive/%{built_tag}.tar.gz
Source1: %{url}/releases/download/v%{built_tag_strip}/%{name}-v%{built_tag_strip}-vendor.tar.gz Source1: %{url}/releases/download/%{built_tag}/%{name}-%{built_tag}-vendor.tar.gz
BuildRequires: cargo BuildRequires: cargo
BuildRequires: git-core BuildRequires: git-core
BuildRequires: make BuildRequires: make