diff options
author | François Andriot <albator78@libertysurf.fr> | 2019-03-10 20:22:48 +0100 |
---|---|---|
committer | François Andriot <albator78@libertysurf.fr> | 2019-03-10 20:26:35 +0100 |
commit | d6f47b905ee995b58fcb8388f683971ce9a2c7ed (patch) | |
tree | 576c5cd7b487b1bfb07e70649d4f3fe6c9c461fd /redhat/main/tdeadmin | |
parent | 75c851fb864c4eacac9b6f27b77186a5d7f4f48b (diff) | |
download | tde-packaging-d6f47b905ee995b58fcb8388f683971ce9a2c7ed.tar.gz tde-packaging-d6f47b905ee995b58fcb8388f683971ce9a2c7ed.zip |
RPM: switch many packages to cmake
Diffstat (limited to 'redhat/main/tdeadmin')
-rw-r--r-- | redhat/main/tdeadmin/tdeadmin.spec | 75 |
1 files changed, 42 insertions, 33 deletions
diff --git a/redhat/main/tdeadmin/tdeadmin.spec b/redhat/main/tdeadmin/tdeadmin.spec index f2fad4484..58e5e12ce 100644 --- a/redhat/main/tdeadmin/tdeadmin.spec +++ b/redhat/main/tdeadmin/tdeadmin.spec @@ -72,10 +72,8 @@ Provides: trinity-kdeadmin = %{version}-%{release} BuildRequires: trinity-arts-devel >= %{tde_epoch}:1.5.10 BuildRequires: trinity-tdelibs-devel >= %{tde_version} -BuildRequires: autoconf -BuildRequires: automake +BuildRequires: cmake >= 2.8 BuildRequires: libtool -BuildRequires: m4 BuildRequires: fdupes BuildRequires: gcc-c++ @@ -339,46 +337,57 @@ touch /etc/lilo.conf %prep %setup -q -n %{name}-%{version}%{?preversion:~%{preversion}} -%__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 QTLIB QTINC export PATH="%{tde_bindir}:${PATH}" -export kde_confdir="%{tde_confdir}" -# Specific path for RHEL4 -if [ -d /usr/X11R6 ]; then - export RPM_OPT_FLAGS="${RPM_OPT_FLAGS} -I/usr/X11R6/include -L/usr/X11R6/%{_lib}" +if ! rpm -E %%cmake|grep -q "cd build"; then + %__mkdir_p build + cd build fi -%configure \ - --prefix=%{tde_prefix} \ - --exec-prefix=%{tde_prefix} \ - --bindir=%{tde_bindir} \ - --sbindir=%{tde_sbindir} \ - --libdir=%{tde_libdir} \ - --datadir=%{tde_datadir} \ - --includedir=%{tde_tdeincludedir} \ +%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}" \ + -DBIN_INSTALL_DIR="%{tde_bindir}" \ + -DDOC_INSTALL_DIR="%{tde_docdir}" \ + -DINCLUDE_INSTALL_DIR="%{tde_tdeincludedir}" \ + -DLIB_INSTALL_DIR="%{tde_libdir}" \ + -DPKGCONFIG_INSTALL_DIR="%{tde_libdir}/pkgconfig" \ + -DSYSCONF_INSTALL_DIR="%{_sysconfdir}/trinity" \ + -DSHARE_INSTALL_PREFIX="%{tde_datadir}" \ \ - --disable-dependency-tracking \ - --disable-debug \ - --enable-new-ldflags \ - --enable-final \ - --enable-closure \ - --enable-rpath \ - --disable-gcc-hidden-visibility \ + -DBUILD_ALL=ON \ + -DBUILD_DOC=ON \ + -DBUILD_KCRON=ON \ + -DBUILD_KDAT=ON \ + -DBUILD_KNETWORKCONF=ON \ + -DBUILD_KPACKAGE=ON \ + -DBUILD_KSYSV=ON \ + -DBUILD_KUSER=ON \ + -DBUILD_LILO_CONFIG=ON \ + -DBUILD_SECPOLICY=ON \ + -DBUILD_TDEFILE_PLUGINS=ON \ \ - --with-rpm \ - --with-pam=kde \ - --with-shadow \ - --with-private-groups \ %if 0%{?fedora} >= 16 || 0%{?suse_version} >= 1210 || 0%{?rhel} >= 7 || 0%{?mageia} >= 4 - --with-first-uid=1000 \ - --with-first-gid=1000 \ + -DKU_FIRSTUID="1000" \ + -DKU_FIRSTGID="1000" \ %endif + -DKU_USERPRIVATEGROUP=false \ + -DKU_HOMEDIR_PERM="0700" \ + -DKU_HOMETEMPLATE="/home/%U" \ + -DKU_MAILBOX_GID="0" \ + -DKU_MAILBOX_PERM="0660" \ + \ + .. %__make %{?_smp_mflags} || %__make @@ -386,7 +395,7 @@ fi %install export PATH="%{tde_bindir}:${PATH}" %__rm -rf %{buildroot} -%__make install DESTDIR=%{buildroot} +%__make install DESTDIR=%{buildroot} -C build comps="kcron kdat knetworkconf kpackage ksysv kuser" %__mkdir_p %{buildroot}%{tde_datadir}/config \ |