* [gentoo-commits] proj/kde:master commit in: kde-frameworks/kidletime/files/, kde-frameworks/kidletime/
@ 2017-08-05 22:13 Andreas Sturmlechner
0 siblings, 0 replies; only message in thread
From: Andreas Sturmlechner @ 2017-08-05 22:13 UTC (permalink / raw
To: gentoo-commits
commit: fbc10178e93c0498b1d77a40874d717699a90966
Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 5 22:12:53 2017 +0000
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sat Aug 5 22:12:53 2017 +0000
URL: https://gitweb.gentoo.org/proj/kde.git/commit/?id=fbc10178
kde-frameworks/kidletime: Add IUSE X, xscreensaver
x11-libs/libXScrnSaver is only used as a fallback,
built as additional plugin that requires Qt5DBus.
Upstream commit 79d45ca682b8ae59b839a5ee7341a97ba4122018
Package-Manager: Portage-2.3.6, Repoman-2.3.1
.../kidletime/files/kidletime-5.37.0-qtdbus.patch | 32 ++++++++++++++++++
kde-frameworks/kidletime/kidletime-9999.ebuild | 38 ++++++++++++++++++----
2 files changed, 63 insertions(+), 7 deletions(-)
diff --git a/kde-frameworks/kidletime/files/kidletime-5.37.0-qtdbus.patch b/kde-frameworks/kidletime/files/kidletime-5.37.0-qtdbus.patch
new file mode 100644
index 0000000000..44d1bc4bea
--- /dev/null
+++ b/kde-frameworks/kidletime/files/kidletime-5.37.0-qtdbus.patch
@@ -0,0 +1,32 @@
+commit e86d576d4030231617d191a569354e368a038384
+Author: Andreas Sturmlechner <andreas.sturmlechner@gmail.com>
+Date: Sat Aug 5 23:45:39 2017 +0200
+
+ Qt5DBus is only required with HAVE_XSCREENSAVER
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index e3c89d8..39cae72 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -32,10 +32,6 @@ include(KDECMakeSettings)
+ set(REQUIRED_QT_VERSION 5.6.0)
+ find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Widgets)
+
+-if(NOT WIN32 AND NOT APPLE)
+- find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED DBus)
+-endif()
+-
+ if(APPLE)
+ cmake_find_frameworks(CoreFoundation Carbon)
+ endif()
+@@ -66,6 +62,10 @@ if(X11_FOUND)
+ set(HAVE_XSCREENSAVER ${X11_Xscreensaver_FOUND})
+ add_feature_info("X-Screensaver based poller" HAVE_XSCREENSAVER "KIdleTime fallback mode (libXss)")
+
++ if(HAVE_XSCREENSAVER AND NOT WIN32)
++ find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED DBus)
++ endif()
++
+ if(NOT HAVE_XSCREENSAVER AND NOT HAVE_XSYNC)
+ message(FATAL_ERROR "\nNeither the XSync (libXext) nor XScreensaver (libXss) development package was found.\nPlease install one of them (XSync is recommended)")
+ endif()
diff --git a/kde-frameworks/kidletime/kidletime-9999.ebuild b/kde-frameworks/kidletime/kidletime-9999.ebuild
index 4779b3a045..812edf6821 100644
--- a/kde-frameworks/kidletime/kidletime-9999.ebuild
+++ b/kde-frameworks/kidletime/kidletime-9999.ebuild
@@ -9,16 +9,40 @@ inherit kde5
DESCRIPTION="Framework for detection and notification of device idle time"
LICENSE="LGPL-2+"
KEYWORDS=""
-IUSE=""
+IUSE="X xscreensaver"
+
+REQUIRED_USE="xscreensaver? ( X )"
RDEPEND="
- $(add_qt_dep qtdbus)
$(add_qt_dep qtgui)
$(add_qt_dep qtwidgets)
- $(add_qt_dep qtx11extras)
- x11-libs/libX11
- x11-libs/libXScrnSaver
- x11-libs/libXext
- x11-libs/libxcb
+ X? (
+ $(add_qt_dep qtx11extras)
+ x11-libs/libX11
+ x11-libs/libxcb
+ x11-libs/libXext
+ )
+ xscreensaver? (
+ $(add_qt_dep qtdbus)
+ x11-libs/libXScrnSaver
+ )
"
DEPEND="${RDEPEND}"
+
+PATCHES=( "${FILESDIR}/${PN}-5.37.0-qtdbus.patch" )
+
+src_prepare() {
+ kde5_src_prepare
+ if ! use xscreensaver; then
+ sed -i -e "s/\${X11_Xscreensaver_FOUND}/0/" CMakeLists.txt || die
+ fi
+}
+
+src_configure() {
+ local mycmakeargs=(
+ $(cmake-utils_use_find_package X X11)
+ $(cmake-utils_use_find_package X XCB)
+ )
+
+ kde5_src_configure
+}
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2017-08-05 22:13 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-05 22:13 [gentoo-commits] proj/kde:master commit in: kde-frameworks/kidletime/files/, kde-frameworks/kidletime/ Andreas Sturmlechner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox