From 9a1a7e8fed696cb45d23ece1e6b46a94f130bcdb Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Mon, 16 May 2016 17:37:54 +0200 Subject: [PATCH] Try to fix the %nil in stable builds --- .../templates/client/v2_2_0/SHORTNAME-client.spec.in | 6 +++--- .../templates/client/v2_2_1/SHORTNAME-client.spec.in | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/jenkins/obs_integration/templates/client/v2_2_0/SHORTNAME-client.spec.in b/jenkins/obs_integration/templates/client/v2_2_0/SHORTNAME-client.spec.in index c099117d..db3bc269 100644 --- a/jenkins/obs_integration/templates/client/v2_2_0/SHORTNAME-client.spec.in +++ b/jenkins/obs_integration/templates/client/v2_2_0/SHORTNAME-client.spec.in @@ -48,14 +48,14 @@ Name: [% shortname %]-client # Use translations from an external tarball in the package, or build them # using the Qt tools? For distros where we do not have the tools, disable. -%if 0%{?centos_version} == 600 || 0%{?rhel_version} == 600 || 0%{?fedora_version} || "%{prerelease}" == "" +%if 0%{?centos_version} == 600 || 0%{?rhel_version} == 600 || 0%{?fedora_version} || 0%{?prerelease} # For beta and rc versions we use the ~ notation, as documented in # http://en.opensuse.org/openSUSE:Package_naming_guidelines # Some distro's (centos_6) don't allow ~ characters. There we follow the Fedora guidelines, # which suggests massaging the buildrelease number. # Otoh: for openSUSE, this technique is discouraged by the package naming guidelines. Version: %{base_version} -%if "%{prerelease}" == "" +%if 0%{?prerelease} Release: 0 %else Release: 0...%{prerelease} @@ -405,7 +405,7 @@ mkdir build pushd build # http://www.cmake.org/Wiki/CMake_RPATH_handling#Default_RPATH_settings cmake .. -DWITH_DOC=TRUE \ -%if "%{prerelease}" != "" +%if 0%{?prerelease} -DMIRALL_VERSION_SUFFIX="%{prerelease}" \ -DMIRALL_VERSION_BUILD="[% buildjobid %]" \ %endif diff --git a/jenkins/obs_integration/templates/client/v2_2_1/SHORTNAME-client.spec.in b/jenkins/obs_integration/templates/client/v2_2_1/SHORTNAME-client.spec.in index c099117d..db3bc269 100644 --- a/jenkins/obs_integration/templates/client/v2_2_1/SHORTNAME-client.spec.in +++ b/jenkins/obs_integration/templates/client/v2_2_1/SHORTNAME-client.spec.in @@ -48,14 +48,14 @@ Name: [% shortname %]-client # Use translations from an external tarball in the package, or build them # using the Qt tools? For distros where we do not have the tools, disable. -%if 0%{?centos_version} == 600 || 0%{?rhel_version} == 600 || 0%{?fedora_version} || "%{prerelease}" == "" +%if 0%{?centos_version} == 600 || 0%{?rhel_version} == 600 || 0%{?fedora_version} || 0%{?prerelease} # For beta and rc versions we use the ~ notation, as documented in # http://en.opensuse.org/openSUSE:Package_naming_guidelines # Some distro's (centos_6) don't allow ~ characters. There we follow the Fedora guidelines, # which suggests massaging the buildrelease number. # Otoh: for openSUSE, this technique is discouraged by the package naming guidelines. Version: %{base_version} -%if "%{prerelease}" == "" +%if 0%{?prerelease} Release: 0 %else Release: 0...%{prerelease} @@ -405,7 +405,7 @@ mkdir build pushd build # http://www.cmake.org/Wiki/CMake_RPATH_handling#Default_RPATH_settings cmake .. -DWITH_DOC=TRUE \ -%if "%{prerelease}" != "" +%if 0%{?prerelease} -DMIRALL_VERSION_SUFFIX="%{prerelease}" \ -DMIRALL_VERSION_BUILD="[% buildjobid %]" \ %endif