summaryrefslogtreecommitdiffstats
path: root/redhat
diff options
context:
space:
mode:
authorFrançois Andriot <albator78@libertysurf.fr>2024-02-01 20:52:01 +0100
committerFrançois Andriot <albator78@libertysurf.fr>2024-02-01 20:52:01 +0100
commit3ad9043330ccf595334680f9dc47fdeb91d17899 (patch)
treed5b72e327e147222b330a602a5bee2efdfbcb3f5 /redhat
parentfde218b082e405158c7c35381251ff324623411e (diff)
downloadtde-packaging-3ad9043330ccf595334680f9dc47fdeb91d17899.tar.gz
tde-packaging-3ad9043330ccf595334680f9dc47fdeb91d17899.zip
RPM: switch k9copy to cmake build
Signed-off-by: François Andriot <albator78@libertysurf.fr>
Diffstat (limited to 'redhat')
-rw-r--r--redhat/applications/multimedia/k9copy/k9copy.spec53
1 files changed, 29 insertions, 24 deletions
diff --git a/redhat/applications/multimedia/k9copy/k9copy.spec b/redhat/applications/multimedia/k9copy/k9copy.spec
index 4d429cdf9..effa0d194 100644
--- a/redhat/applications/multimedia/k9copy/k9copy.spec
+++ b/redhat/applications/multimedia/k9copy/k9copy.spec
@@ -63,7 +63,7 @@ BuildRequires: trinity-tdebase-devel >= %{tde_version}
BuildRequires: desktop-file-utils
BuildRequires: trinity-k3b-devel
-BuildRequires: autoconf automake libtool m4
+BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkgconfig
@@ -129,38 +129,43 @@ This is the Trinity version.
# Fix permissions on doc files
chmod -x AUTHORS COPYING
-%__cp -f "/usr/share/aclocal/libtool.m4" "admin/libtool.m4.in"
-%__cp -f "/usr/share/libtool/"*"/ltmain.sh" "admin/ltmain.sh" || %__cp -f "/usr/share/libtool/ltmain.sh" "admin/ltmain.sh"
-%__make -f "admin/Makefile.common"
-
%build
unset QTDIR QTINC QTLIB
export PATH="%{tde_bindir}:${PATH}"
+export PKG_CONFIG_PATH="%{tde_libdir}/pkgconfig"
# FFMPEG ...
if [ -d /usr/include/ffmpeg ]; then
- export CXXFLAGS="${RPM_OPT_FLAGS} -I/usr/include/ffmpeg"
+ RPM_OPT_FLAGS="${RPM_OPT_FLAGS} -I/usr/include/ffmpeg"
+fi
+
+if ! rpm -E %%cmake|grep -q "cd build"; then
+ %__mkdir_p build
+ cd build
fi
-
-# NOTICE: --enable-final causes FTBFS !
-%configure \
- --prefix=%{tde_prefix} \
- --exec-prefix=%{tde_prefix} \
- --bindir=%{tde_bindir} \
- --datadir=%{tde_datadir} \
- --includedir=%{tde_tdeincludedir} \
- --mandir=%{tde_mandir} \
+
+%cmake \
+ -DCMAKE_BUILD_TYPE="RelWithDebInfo" \
+ -DCMAKE_C_FLAGS="${RPM_OPT_FLAGS}" \
+ -DCMAKE_CXX_FLAGS="${RPM_OPT_FLAGS}" \
+ -DCMAKE_SKIP_RPATH=OFF \
+ -DCMAKE_SKIP_INSTALL_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}" \
+ -DINCLUDE_INSTALL_DIR="%{tde_includedir}" \
+ -DLIB_INSTALL_DIR="%{tde_libdir}" \
\
- --disable-dependency-tracking \
- --disable-debug \
- --disable-final \
- --enable-new-ldflags \
- --enable-closure \
- --enable-rpath \
- --disable-gcc-hidden-visibility \
+ -DWITH_ALL_OPTIONS=ON \
+ -DWITH_GCC_VISIBILITY=ON \
\
- --enable-k3bdevices
+ -DBUILD_ALL=ON \
+ -DWITH_ALL_OPTIONS=ON \
+ ..
%__make %{?_smp_mflags} || %__make
@@ -168,7 +173,7 @@ fi
%install
export PATH="%{tde_bindir}:${PATH}"
%__rm -rf %{buildroot}
-%__make install DESTDIR=%{buildroot}
+%__make -C build install DESTDIR=%{buildroot}
%find_lang %{tde_pkg}