From 23ea608188ec57ea4e03ef004809990a4867799c Mon Sep 17 00:00:00 2001 From: Pier Luigi Fiorini Date: Sat, 10 Oct 2020 19:00:05 +0200 Subject: [PATCH] Use new CMake macros everywhere And update %cmake_liri. --- fluid/fluid.spec | 11 +++++------ libliri/libliri.spec | 11 +++++------ liri-appcenter/liri-appcenter.spec | 11 +++++------ liri-browser/liri-browser.spec | 11 +++++------ .../liri-calamares-branding.spec | 11 +++++------ liri-calculator/liri-calculator.spec | 11 +++++------ liri-cmake-shared/liri-cmake-shared.spec | 15 ++------------- liri-cmake-shared/macros.liri | 7 +++++-- liri-eglfs/liri-eglfs.spec | 11 +++++------ liri-files/liri-files.spec | 11 +++++------ .../liri-materialdecoration.spec | 11 +++++------ liri-networkmanager/liri-networkmanager.spec | 11 +++++------ liri-platformtheme/liri-platformtheme.spec | 11 +++++------ liri-power-manager/liri-power-manager.spec | 14 ++++++-------- liri-pulseaudio/liri-pulseaudio.spec | 11 +++++------ liri-screencast/liri-screencast.spec | 11 +++++------ liri-screenshot/liri-screenshot.spec | 11 +++++------ liri-session/liri-session.spec | 14 ++++++-------- liri-settings/liri-settings.spec | 11 +++++------ liri-shell/liri-shell.spec | 14 ++++++-------- liri-terminal/liri-terminal.spec | 11 +++++------ liri-text/liri-text.spec | 11 +++++------ liri-themes/liri-themes.spec | 11 +++++------ liri-wallpapers/liri-wallpapers.spec | 11 +++++------ liri-wayland/liri-wayland.spec | 11 +++++------ qml-xwayland/qml-xwayland.spec | 11 +++++------ qt5-qtaccountsservice/qt5-qtaccountsservice.spec | 11 +++++------ qt5-qtgsettings/qt5-qtgsettings.spec | 11 +++++------ qt5-qtudev/qt5-qtudev.spec | 11 +++++------ .../xdg-desktop-portal-liri.spec | 14 ++++++-------- 30 files changed, 151 insertions(+), 191 deletions(-) diff --git a/fluid/fluid.spec b/fluid/fluid.spec index b2b9fdc..c5fc6f9 100644 --- a/fluid/fluid.spec +++ b/fluid/fluid.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -39,15 +41,12 @@ with the Material Design language. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} -DFLUID_USE_SYSTEM_LCS:BOOL=ON .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri -DFLUID_USE_SYSTEM_LCS:BOOL=ON +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/libliri/libliri.spec b/libliri/libliri.spec index 0e117a2..237ec56 100644 --- a/libliri/libliri.spec +++ b/libliri/libliri.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -40,15 +42,12 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-appcenter/liri-appcenter.spec b/liri-appcenter/liri-appcenter.spec index 2542a54..076de37 100644 --- a/liri-appcenter/liri-appcenter.spec +++ b/liri-appcenter/liri-appcenter.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -47,15 +49,12 @@ Files for development of Liri AppCenter plugins. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-browser/liri-browser.spec b/liri-browser/liri-browser.spec index a3062db..ac62abf 100644 --- a/liri-browser/liri-browser.spec +++ b/liri-browser/liri-browser.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -39,15 +41,12 @@ the Liri desktop. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-calamares-branding/liri-calamares-branding.spec b/liri-calamares-branding/liri-calamares-branding.spec index db242dd..f737abe 100644 --- a/liri-calamares-branding/liri-calamares-branding.spec +++ b/liri-calamares-branding/liri-calamares-branding.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -33,15 +35,12 @@ Liri OS branding and customizations for Calamares. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-calculator/liri-calculator.spec b/liri-calculator/liri-calculator.spec index bcf3335..0f12e51 100644 --- a/liri-calculator/liri-calculator.spec +++ b/liri-calculator/liri-calculator.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -34,15 +36,12 @@ Material Design calculator. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-cmake-shared/liri-cmake-shared.spec b/liri-cmake-shared/liri-cmake-shared.spec index c05a2c9..fde12da 100644 --- a/liri-cmake-shared/liri-cmake-shared.spec +++ b/liri-cmake-shared/liri-cmake-shared.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -38,25 +40,12 @@ RPM macros for building Liri packages. %build -%if 0%{?fedora} >= 33 %cmake %cmake_build -%else -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake} .. -popd -make %{?_smp_mflags} -C %{_target_platform} -%endif %install -%if 0%{?fedora} >= 33 %cmake_install -%else -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} -%endif - install -Dpm644 %{_sourcedir}/macros.liri %{buildroot}%{_rpmconfigdir}/macros.d/macros.liri diff --git a/liri-cmake-shared/macros.liri b/liri-cmake-shared/macros.liri index 6823a8e..9ccaec6 100644 --- a/liri-cmake-shared/macros.liri +++ b/liri-cmake-shared/macros.liri @@ -2,14 +2,17 @@ %_liri_libexecdir %_libexecdir/liri %_liri_buildtype release -%cmake_liri \ +%cmake_liri \\\ + %undefine __cmake_in_source_build \ QTDIR="%{_qt5_prefix}" ; export QTDIR ; \ PATH="%{_qt5_bindir}:$PATH" ; export PATH ; \ CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \ CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \ FFLAGS="${FFLAGS:-%optflags%{?_fmoddir: -I%_fmoddir}}" ; export FFLAGS ; \ %{?__global_ldflags:LDFLAGS="${LDFLAGS:-%__global_ldflags}" ; export LDFLAGS ;} \ - %{?fedora:%{__cmake}}%{?rhel:%{__cmake3}} \\\ + %{__cmake} \\\ + %{?__cmake_builddir:-S "%{_vpath_srcdir}"} \\\ + %{?__cmake_builddir:-B "%{__cmake_builddir}"} \\\ -DBUILD_TESTING:BOOL=FALSE \\\ -DCMAKE_BUILD_TYPE=%{_liri_buildtype} \\\ -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \\\ diff --git a/liri-eglfs/liri-eglfs.spec b/liri-eglfs/liri-eglfs.spec index d6c4756..a282e1b 100644 --- a/liri-eglfs/liri-eglfs.spec +++ b/liri-eglfs/liri-eglfs.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %define snapdate @DATE@ %define snaphash @HASH@ @@ -48,15 +50,12 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install rm -f %{buildroot}%{_libdir}/libLiri1{EdidSupport,KmsSupport,LibInput}.a rm -rf %{buildroot}%{_includedir}/Liri{EglFSDeviceIntegration,EglFSKmsSupport,EdidSupport,KmsSupport,LibInput} rm -f %{buildroot}%{_libdir}/libLiri1EglFS{DeviceIntegration,KmsSupport}.so diff --git a/liri-files/liri-files.spec b/liri-files/liri-files.spec index 034c77e..259f6e1 100644 --- a/liri-files/liri-files.spec +++ b/liri-files/liri-files.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -34,15 +36,12 @@ Files is a file manager for Liri. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %find_lang %{name} --all-name --with-qt diff --git a/liri-materialdecoration/liri-materialdecoration.spec b/liri-materialdecoration/liri-materialdecoration.spec index ef3c8cc..b24c421 100644 --- a/liri-materialdecoration/liri-materialdecoration.spec +++ b/liri-materialdecoration/liri-materialdecoration.spec @@ -1,5 +1,7 @@ # This package needs to be rebuilt every time Qt is updated. +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -28,15 +30,12 @@ Material Design decoration for Qt applications on Wayland. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-networkmanager/liri-networkmanager.spec b/liri-networkmanager/liri-networkmanager.spec index 7b2fd4f..7a554a4 100644 --- a/liri-networkmanager/liri-networkmanager.spec +++ b/liri-networkmanager/liri-networkmanager.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -40,15 +42,12 @@ to access network options from the Liri shell. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-platformtheme/liri-platformtheme.spec b/liri-platformtheme/liri-platformtheme.spec index 4d21ad0..191813d 100644 --- a/liri-platformtheme/liri-platformtheme.spec +++ b/liri-platformtheme/liri-platformtheme.spec @@ -1,5 +1,7 @@ # This package needs to be rebuilt every time Qt is updated. +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -29,15 +31,12 @@ Qt Platform Theme integration plugin for Liri. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-power-manager/liri-power-manager.spec b/liri-power-manager/liri-power-manager.spec index fd57a58..1272569 100644 --- a/liri-power-manager/liri-power-manager.spec +++ b/liri-power-manager/liri-power-manager.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -40,17 +42,13 @@ settings module to configure power consumption settings. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} \ - -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} \ -.. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri \ + -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %posttrans diff --git a/liri-pulseaudio/liri-pulseaudio.spec b/liri-pulseaudio/liri-pulseaudio.spec index 524d539..fd8827a 100644 --- a/liri-pulseaudio/liri-pulseaudio.spec +++ b/liri-pulseaudio/liri-pulseaudio.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -36,15 +38,12 @@ to access volume and media players from the Liri shell. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-screencast/liri-screencast.spec b/liri-screencast/liri-screencast.spec index cf59cf8..8beeb17 100644 --- a/liri-screencast/liri-screencast.spec +++ b/liri-screencast/liri-screencast.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -28,15 +30,12 @@ Take videos of your screen under a Liri Shell session. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %find_lang %{name} --all-name --with-qt diff --git a/liri-screenshot/liri-screenshot.spec b/liri-screenshot/liri-screenshot.spec index 5abffbe..91e9381 100644 --- a/liri-screenshot/liri-screenshot.spec +++ b/liri-screenshot/liri-screenshot.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -34,15 +36,12 @@ Take a picture of your screen under a Liri Shell session. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %find_lang %{name} --all-name --with-qt diff --git a/liri-session/liri-session.spec b/liri-session/liri-session.spec index 72027aa..ab281d3 100644 --- a/liri-session/liri-session.spec +++ b/liri-session/liri-session.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -45,18 +47,14 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} \ +%cmake_liri \ -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} \ - -DINSTALL_SYSTEMDUSERGENERATORSDIR:PATH=%{_systemdusergeneratordir} \ -.. -popd -make %{?_smp_mflags} -C %{_target_platform} + -DINSTALL_SYSTEMDUSERGENERATORSDIR:PATH=%{_systemdusergeneratordir} +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %posttrans diff --git a/liri-settings/liri-settings.spec b/liri-settings/liri-settings.spec index fa38482..a1d4096 100644 --- a/liri-settings/liri-settings.spec +++ b/liri-settings/liri-settings.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -47,15 +49,12 @@ properties, screen resolution, and other settings. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %find_lang %{name} --all-name --with-qt diff --git a/liri-shell/liri-shell.spec b/liri-shell/liri-shell.spec index 8d2ab38..8b98216 100644 --- a/liri-shell/liri-shell.spec +++ b/liri-shell/liri-shell.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -71,18 +73,14 @@ with the SDDM theme. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} \ +%cmake_liri \ -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} \ - -DLIRI_SHELL_DEVELOPMENT_BUILD:BOOL=ON \ -.. -popd -make %{?_smp_mflags} -C %{_target_platform} + -DLIRI_SHELL_DEVELOPMENT_BUILD:BOOL=ON +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install rm -f %{buildroot}%{_libdir}/*.a diff --git a/liri-terminal/liri-terminal.spec b/liri-terminal/liri-terminal.spec index 3242268..cf707f0 100644 --- a/liri-terminal/liri-terminal.spec +++ b/liri-terminal/liri-terminal.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -34,15 +36,12 @@ This package contains a terminal emulator for the Liri desktop environment. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-text/liri-text.spec b/liri-text/liri-text.spec index c65a941..e6c404d 100644 --- a/liri-text/liri-text.spec +++ b/liri-text/liri-text.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -34,15 +36,12 @@ Advanced text editor built in accordance with Material Design. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %check diff --git a/liri-themes/liri-themes.spec b/liri-themes/liri-themes.spec index 3ae82bc..4bf5b6b 100644 --- a/liri-themes/liri-themes.spec +++ b/liri-themes/liri-themes.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -65,15 +67,12 @@ This package contains the "Liri OS" theme for SDDM. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} -DINSTALL_GRUBDIR=%{_grubdir} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri -DINSTALL_GRUBDIR=%{_grubdir} +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install # Set SDDM theme mkdir -p %{buildroot}/usr/lib/sddm/sddm.conf.d diff --git a/liri-wallpapers/liri-wallpapers.spec b/liri-wallpapers/liri-wallpapers.spec index eb9bb30..656b615 100644 --- a/liri-wallpapers/liri-wallpapers.spec +++ b/liri-wallpapers/liri-wallpapers.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -25,15 +27,12 @@ This package contains backgrounds for the Liri desktop. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/liri-wayland/liri-wayland.spec b/liri-wayland/liri-wayland.spec index 7f4a55b..7e536ca 100644 --- a/liri-wayland/liri-wayland.spec +++ b/liri-wayland/liri-wayland.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %define snapdate @DATE@ %define snaphash @HASH@ @@ -46,15 +48,12 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %post -p /sbin/ldconfig diff --git a/qml-xwayland/qml-xwayland.spec b/qml-xwayland/qml-xwayland.spec index 2591ae5..f507250 100644 --- a/qml-xwayland/qml-xwayland.spec +++ b/qml-xwayland/qml-xwayland.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %define snapdate @DATE@ %define snaphash @HASH@ @@ -36,15 +38,12 @@ implementation for Liri Shell. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files diff --git a/qt5-qtaccountsservice/qt5-qtaccountsservice.spec b/qt5-qtaccountsservice/qt5-qtaccountsservice.spec index 550d2ae..3aa7c3d 100644 --- a/qt5-qtaccountsservice/qt5-qtaccountsservice.spec +++ b/qt5-qtaccountsservice/qt5-qtaccountsservice.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -39,15 +41,12 @@ Files for development using Qt Account Service Addon. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %post -p /sbin/ldconfig diff --git a/qt5-qtgsettings/qt5-qtgsettings.spec b/qt5-qtgsettings/qt5-qtgsettings.spec index d4f5ce1..626d051 100644 --- a/qt5-qtgsettings/qt5-qtgsettings.spec +++ b/qt5-qtgsettings/qt5-qtgsettings.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -41,15 +43,12 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %post -p /sbin/ldconfig diff --git a/qt5-qtudev/qt5-qtudev.spec b/qt5-qtudev/qt5-qtudev.spec index f6c8878..9d9fb2f 100644 --- a/qt5-qtudev/qt5-qtudev.spec +++ b/qt5-qtudev/qt5-qtudev.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + %global snapdate @DATE@ %global snaphash @HASH@ @@ -38,15 +40,12 @@ developing applications that use %{name}. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} .. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %post -p /sbin/ldconfig diff --git a/xdg-desktop-portal-liri/xdg-desktop-portal-liri.spec b/xdg-desktop-portal-liri/xdg-desktop-portal-liri.spec index 39787fd..6da564d 100644 --- a/xdg-desktop-portal-liri/xdg-desktop-portal-liri.spec +++ b/xdg-desktop-portal-liri/xdg-desktop-portal-liri.spec @@ -1,3 +1,5 @@ +%undefine __cmake_in_source_build + # Version required for Session support. %global xdg_desktop_portal_version 0.10 @@ -47,17 +49,13 @@ pieces of Liri libraries and infrastructure. %build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake_liri} \ - -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} \ -.. -popd -make %{?_smp_mflags} -C %{_target_platform} +%cmake_liri \ + -DINSTALL_SYSTEMDUSERUNITDIR:PATH=%{_userunitdir} +%cmake_build %install -make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +%cmake_install %files