summaryrefslogtreecommitdiffstats
path: root/redhat/applications/ksystemlog
diff options
context:
space:
mode:
authorFrançois Andriot <albator78@libertysurf.fr>2021-11-01 10:18:32 +0100
committerFrançois Andriot <albator78@libertysurf.fr>2021-11-01 21:51:39 +0100
commit4cf5744a3c281bba358ab1a5e00d3c5cf333f7d3 (patch)
tree4644b22a6c21d70d229eeb31539c848520e27bd7 /redhat/applications/ksystemlog
parent52e9b2772429582475ad0ac0a99b5b0960359c56 (diff)
downloadtde-packaging-4cf5744a3c281bba358ab1a5e00d3c5cf333f7d3.tar.gz
tde-packaging-4cf5744a3c281bba358ab1a5e00d3c5cf333f7d3.zip
RPM: switch ksystemlog to cmake build
Signed-off-by: François Andriot <albator78@libertysurf.fr>
Diffstat (limited to 'redhat/applications/ksystemlog')
-rw-r--r--redhat/applications/ksystemlog/ksystemlog.spec54
1 files changed, 31 insertions, 23 deletions
diff --git a/redhat/applications/ksystemlog/ksystemlog.spec b/redhat/applications/ksystemlog/ksystemlog.spec
index 846ac2f75..eb8bc66e0 100644
--- a/redhat/applications/ksystemlog/ksystemlog.spec
+++ b/redhat/applications/ksystemlog/ksystemlog.spec
@@ -60,7 +60,7 @@ BuildRequires: trinity-tdelibs-devel >= %{tde_version}
BuildRequires: trinity-tdebase-devel >= %{tde_version}
BuildRequires: desktop-file-utils
-BuildRequires: autoconf automake libtool m4
+BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkgconfig
BuildRequires: fdupes
@@ -97,39 +97,45 @@ quickly see problems occuring on their server.
%prep
%setup -q -n %{name}-%{tde_version}%{?preversion:~%{preversion}}
-%__cp "/usr/share/aclocal/libtool.m4" "admin/libtool.m4.in"
-%__cp "/usr/share/libtool/"*"/ltmain.sh" "admin/ltmain.sh" || %__cp "/usr/share/libtool/ltmain.sh" "admin/ltmain.sh"
-%__make -f "admin/Makefile.common"
-
%build
unset QTDIR QTINC QTLIB
export PATH="%{tde_bindir}:${PATH}"
-
-%configure \
- --prefix=%{tde_prefix} \
- --exec-prefix=%{tde_prefix} \
- --bindir=%{tde_bindir} \
- --datadir=%{tde_datadir} \
- --libdir=%{tde_libdir} \
- --mandir=%{tde_mandir} \
- --includedir=%{tde_tdeincludedir} \
+export PKG_CONFIG_PATH="%{tde_libdir}/pkgconfig"
+
+if ! rpm -E %%cmake|grep -q "cd build"; then
+ %__mkdir_p build
+ cd build
+fi
+
+# Warning: GCC visibility causes FTBFS [Bug #1285]
+%cmake \
+ -DCMAKE_BUILD_TYPE="RelWithDebInfo" \
+ -DCMAKE_C_FLAGS="${RPM_OPT_FLAGS}" \
+ -DCMAKE_CXX_FLAGS="${RPM_OPT_FLAGS}" \
+ -DCMAKE_SKIP_RPATH=OFF \
+ -DCMAKE_INSTALL_RPATH="%{tde_libdir}" \
+ -DCMAKE_NO_BUILTIN_CHRPATH=ON \
+ -DCMAKE_VERBOSE_MAKEFILE=ON \
+ -DWITH_GCC_VISIBILITY=OFF \
\
- --disable-dependency-tracking \
- --disable-debug \
- --enable-new-ldflags \
- --enable-final \
- --enable-closure \
- --enable-rpath \
- --disable-gcc-hidden-visibility
+ -DBIN_INSTALL_DIR=%{tde_bindir} \
+ -DCONFIG_INSTALL_DIR="%{tde_confdir}" \
+ -DINCLUDE_INSTALL_DIR=%{tde_tdeincludedir} \
+ -DLIB_INSTALL_DIR=%{tde_libdir} \
+ -DSHARE_INSTALL_PREFIX=%{tde_datadir} \
+ \
+ -DWITH_ALL_OPTIONS=ON \
+ -DBUILD_ALL=ON \
+ ..
-%__make %{?_smp_mflags}
+%__make %{?_smp_mflags} || %__make
%install
export PATH="%{tde_bindir}:${PATH}"
%__rm -rf %{buildroot}
-%__make install DESTDIR=%{buildroot}
+%__make install DESTDIR=%{buildroot} -C build
# Missing category will make this fail.
echo "OnlyShowIn=TDE;" >>"%{?buildroot}%{tde_tdeappdir}/%{tde_pkg}.desktop"
@@ -151,5 +157,7 @@ echo "OnlyShowIn=TDE;" >>"%{?buildroot}%{tde_tdeappdir}/%{tde_pkg}.desktop"
%{tde_datadir}/icons/hicolor/*/apps/ksystemlog.png
%{tde_datadir}/icons/hicolor/*/apps/ksystemlog.svgz
%{tde_tdedocdir}/HTML/en/ksystemlog/
+%{tde_mandir}/man1/ksystemlog.1*
+
%changelog