From 04005671421c2babe4a3591f661fac687fa09eb5 Mon Sep 17 00:00:00 2001 From: codestation Date: Mon, 16 Feb 2015 12:20:40 -0430 Subject: [PATCH] Updated spec files. --- rpmbuild/qcma-fedora.spec | 20 ++++++++++--------- ...{qcma-openSUSE.spec => qcma-opensuse.spec} | 20 ++++++++++--------- version_bump.sh | 4 ++-- 3 files changed, 24 insertions(+), 20 deletions(-) rename rpmbuild/{qcma-openSUSE.spec => qcma-opensuse.spec} (74%) diff --git a/rpmbuild/qcma-fedora.spec b/rpmbuild/qcma-fedora.spec index 9b96a3c..d6c81b7 100644 --- a/rpmbuild/qcma-fedora.spec +++ b/rpmbuild/qcma-fedora.spec @@ -2,18 +2,26 @@ # qcma spec file # +%define _version 0.3.7 + +%if "%{_version}" == "testing" || "%{_version}" == "master" +%define _verprefix +%else +%define _verprefix v +%endif + Name: qcma Summary: PSVita Content Manager Assistant License: GPL-3.0 Release: 1 -Version: 0.3.7 +Version: ${_version} URL: https://github.com/codestation/qcma -Source: https://github.com/codestation/qcma.git +Source: https://github.com/codestation/qcma/archive/%{_verprefix}%{_version}/qcma-%{_version}.tar.gz Group: Productivity/File utilities Requires: ffmpeg Requires: qt5-qtbase Requires: qt5-qtimageformats -Requires: libvitamtp4 >= 2.5.4 +Requires: libvitamtp4 >= 2.5.5 BuildRequires: pkgconfig BuildRequires: ffmpeg-devel BuildRequires: libvitamtp-devel @@ -25,12 +33,6 @@ QCMA is an cross-platform application to provide a Open Source implementation of the original Content Manager Assistant that comes with the PS Vita. QCMA is meant to be compatible with Linux, Windows and MAC OS X. -%prep -rm -rf $RPM_SOURCE_DIR/%{name}-%{version} -%{!?_qcma_repo:%define _qcma_repo https://github.com/codestation/qcma.git} -git clone "%{_qcma_repo}" $RPM_SOURCE_DIR/%{name}-%{version} -cp -r $RPM_SOURCE_DIR/%{name}-%{version} $RPM_BUILD_DIR/%{name}-%{version} - %setup -n %{name}-%{version} -DT %build diff --git a/rpmbuild/qcma-openSUSE.spec b/rpmbuild/qcma-opensuse.spec similarity index 74% rename from rpmbuild/qcma-openSUSE.spec rename to rpmbuild/qcma-opensuse.spec index dfcffbc..ff6213d 100644 --- a/rpmbuild/qcma-openSUSE.spec +++ b/rpmbuild/qcma-opensuse.spec @@ -2,18 +2,26 @@ # qcma spec file # +%define _version 0.3.7 + +%if "%{_version}" == "testing" || "%{_version}" == "master" +%define _verprefix +%else +%define _verprefix v +%endif + Name: qcma Summary: PSVita Content Manager Assistant License: GPL-3.0 Release: 1 -Version: 0.3.7 +Version: ${_version} URL: https://github.com/codestation/qcma -Source: https://github.com/codestation/qcma.git +Source: https://github.com/codestation/qcma/archive/%{_verprefix}%{_version}/qcma-%{_version}.tar.gz Group: Productivity/File utilities Requires: ffmpeg Requires: libqt5-qtbase Requires: libqt5-qtimageformats -Requires: libvitamtp4 >= 2.5.4 +Requires: libvitamtp4 >= 2.5.5 BuildRequires: pkg-config BuildRequires: ffmpeg-devel BuildRequires: libvitamtp-devel @@ -25,12 +33,6 @@ QCMA is an cross-platform application to provide a Open Source implementation of the original Content Manager Assistant that comes with the PS Vita. QCMA is meant to be compatible with Linux, Windows and MAC OS X. -%prep -rm -rf $RPM_SOURCE_DIR/%{name}-%{version} -%{!?_qcma_repo:%define _qcma_repo https://github.com/codestation/qcma.git} -git clone "%{_qcma_repo}" $RPM_SOURCE_DIR/%{name}-%{version} -cp -r $RPM_SOURCE_DIR/%{name}-%{version} $RPM_BUILD_DIR/%{name}-%{version} - %setup -n %{name}-%{version} -DT %build diff --git a/version_bump.sh b/version_bump.sh index c6b67b3..5a7bc45 100755 --- a/version_bump.sh +++ b/version_bump.sh @@ -2,7 +2,7 @@ [ $# -eq 0 ] && { echo "Usage: $0 "; exit 1; } -sed -i "s/Version:.*/Version: $1/" rpmbuild/qcma-fedora.spec -sed -i "s/Version:.*/Version: $1/" rpmbuild/qcma-openSUSE.spec +sed -i "s/%define _version.*/%define _version $1/" rpmbuild/qcma-fedora.spec +sed -i "s/%define _version.*/%define _version $1/" rpmbuild/qcma-opensuse.spec sed -i "s/VERSION = .*/VERSION = $1/" qcma_common.pri echo "Don't forget to update the changelog"