Clean up spec file, autodetect stable/unstable download folder

epel9
Dan Vrátil 10 years ago
parent 85838c8e12
commit 972c117e58

@ -7,11 +7,14 @@ Summary: KDE Frameworks 5 Tier 2 module providing Pty abstraction
License: LGPLv2+ and GPLv2+ License: LGPLv2+ and GPLv2+
URL: http://www.kde.org URL: http://www.kde.org
# git archive --format=tar --prefix=%{framework}-%{version}/ \
# --remote=git://anongit.kde.org/%{framework}.git master | \ %global revision %(echo %{version} | cut -d. -f3)
# bzip2 -c > %{name}-%{version}-%{snapshot}git.tar.bz2 %if %{revision} >= 50
#Source0: %{name}-%{version}-%{snapshot}git.tar.bz2 %global stable unstable
Source0: http://download.kde.org/stable/frameworks/%{version}/%{framework}-%{version}.tar.xz %else
%global stable stable
%endif
Source0: http://download.kde.org/%{stable}/frameworks/%{version}/%{framework}-%{version}.tar.xz
BuildRequires: kf5-rpm-macros BuildRequires: kf5-rpm-macros
BuildRequires: extra-cmake-modules BuildRequires: extra-cmake-modules
@ -25,18 +28,17 @@ Requires: kf5-filesystem
%description %description
KDE Frameworks 5 tier 2 module providing Pty abstraction. KDE Frameworks 5 tier 2 module providing Pty abstraction.
%package devel %package devel
Summary: Development files for %{name} Summary: Development files for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: kf5-kcoreaddons-devel Requires: kf5-kcoreaddons-devel
Requires: kf5-ki18n-devel Requires: kf5-ki18n-devel
%description devel %description devel
The %{name}-devel package contains libraries and header files for The %{name}-devel package contains libraries and header files for
developing applications that use %{name}. developing applications that use %{name}.
%prep %prep
%setup -q -n %{framework}-%{version} %setup -q -n %{framework}-%{version}
@ -52,11 +54,10 @@ make %{?_smp_mflags} -C %{_target_platform}
%make_install -C %{_target_platform} %make_install -C %{_target_platform}
%find_lang kpty5_qt --with-qt --all-name %find_lang kpty5_qt --with-qt --all-name
%post -p /sbin/ldconfig
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig %postun -p /sbin/ldconfig
%files -f kpty5_qt.lang %files -f kpty5_qt.lang
%doc COPYING COPYING.LIB README.md %doc COPYING COPYING.LIB README.md
%{_kf5_libdir}/libKF5Pty.so.* %{_kf5_libdir}/libKF5Pty.so.*

Loading…
Cancel
Save