summaryrefslogtreecommitdiffstats
path: root/redhat/applications/kstreamripper
diff options
context:
space:
mode:
Diffstat (limited to 'redhat/applications/kstreamripper')
-rw-r--r--redhat/applications/kstreamripper/kstreamripper.spec67
1 files changed, 40 insertions, 27 deletions
diff --git a/redhat/applications/kstreamripper/kstreamripper.spec b/redhat/applications/kstreamripper/kstreamripper.spec
index e62b19867..e25b14176 100644
--- a/redhat/applications/kstreamripper/kstreamripper.spec
+++ b/redhat/applications/kstreamripper/kstreamripper.spec
@@ -15,10 +15,6 @@
# Please submit bugfixes or comments via http://www.trinitydesktop.org/
#
-%if 0%{?fedora} >= 28 || 0%{?mgaversion} >= 7 || 0%{?rhel} >= 8
-%global debug_package %{nil}
-%endif
-
# TDE variables
%define tde_epoch 2
%if "%{?tde_version}" == ""
@@ -59,7 +55,6 @@ Prefix: %{tde_prefix}
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source0: %{name}-%{tde_version}%{?preversion:~%{preversion}}.tar.gz
-Source1: scons-local-2.5.1.tar.gz
BuildRequires: trinity-tdelibs-devel >= %{tde_version}
BuildRequires: trinity-tdebase-devel >= %{tde_version}
@@ -80,19 +75,7 @@ BuildRequires: update-desktop-files
BuildRequires: brp-check-trinity
%endif
-#BuildRequires: scons
-
-# PYTHON support
-%if 0%{?rhel} >= 8 || 0%{?fedora} >= 31 || 0%{?suse_version} >= 1550
-%global python python2
-%global __python %__python2
-%global python_sitearch %{python2_sitearch}
-%else
-%global python python
-%endif
-%{!?python_sitearch:%global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
-BuildRequires: %{python}
-BuildRequires: %{python}-devel
+BuildRequires: cmake
%description
@@ -112,23 +95,49 @@ you with managing/ripping your preferred streams.
%prep
-%setup -q -n %{name}-%{tde_version}%{?preversion:~%{preversion}} -a 1
-%__rm -f kde.py
+%setup -q -n %{name}-%{tde_version}%{?preversion:~%{preversion}}
%build
unset QTDIR QTINC QTLIB
export PATH="%{tde_bindir}:${PATH}"
-
-export QTDIR=/usr
-%__python ./scons.py configure prefix="%{_prefix}"
-%__python ./scons.py %{?_smp_mflags}
-
+export PKG_CONFIG_PATH="%{tde_libdir}/pkgconfig"
+
+if ! rpm -E %%cmake|grep -q "cd build"; then
+ %__mkdir_p build
+ cd build
+fi
+
+%cmake \
+ -DCMAKE_BUILD_TYPE="RelWithDebInfo" \
+ -DCMAKE_C_FLAGS="${RPM_OPT_FLAGS} -DNDEBUG" \
+ -DCMAKE_CXX_FLAGS="${RPM_OPT_FLAGS} -DNDEBUG" \
+ -DCMAKE_SKIP_RPATH=OFF \
+ -DCMAKE_INSTALL_RPATH="%{tde_libdir}" \
+ -DCMAKE_VERBOSE_MAKEFILE=ON \
+ -DWITH_GCC_VISIBILITY=OFF \
+ \
+ -DCMAKE_INSTALL_PREFIX="%{tde_prefix}" \
+ -DSHARE_INSTALL_PREFIX="%{tde_datadir}" \
+ -DLIB_INSTALL_DIR="%{tde_libdir}" \
+ -DPLUGIN_INSTALL_DIR="%{tde_tdelibdir}" \
+ \
+ -DWITH_ALL_OPTIONS=ON \
+ -DWITH_GCC_VISIBILITY=ON \
+ -DWITH_NVCONTROL=OFF \
+ \
+ -DBUILD_ALL=ON \
+ -DBUILD_DOC=ON \
+ -DBUILD_TRANSLATIONS=ON \
+ \
+ ..
+
+%__make %{?_smp_mflags} || %__make
%install
export PATH="%{tde_bindir}:${PATH}"
%__rm -rf %{buildroot}
-DESTDIR="%{?buildroot}" %__python ./scons.py install
+%__make install DESTDIR=%{buildroot} -C build
# Missing icon file will make this fail.
echo "OnlyShowIn=TDE;" >>"%{?buildroot}%{tde_tdeappdir}/%{tde_pkg}.desktop"
@@ -138,17 +147,21 @@ echo "OnlyShowIn=TDE;" >>"%{?buildroot}%{tde_tdeappdir}/%{tde_pkg}.desktop"
%suse_update_desktop_file kstreamripper Audio Recorder
%endif
+%find_lang %{tde_pkg}
+
%clean
%__rm -rf %{buildroot}
-%files
+%files -f %{tde_pkg}.lang
%defattr(-,root,root,-)
%{tde_bindir}/kstreamripper
%{tde_tdeappdir}/kstreamripper.desktop
%{tde_datadir}/apps/kstreamripper/
+%{tde_datadir}/icons/hicolor/*/apps/kstreamripper.png
%{tde_tdedocdir}/HTML/en/kstreamripper/
+%{tde_mandir}/man*/kstreamripper.*
%changelog