commit:     8440fac77cf5050fe3a85e903a52f46afa6a1d40
Author:     Andreas Sturmlechner <andreas.sturmlechner <AT> gmail <DOT> com>
AuthorDate: Mon Jan 19 02:13:11 2015 +0000
Commit:     Johannes Huber <johu <AT> gentoo <DOT> org>
CommitDate: Mon Jan 19 21:56:19 2015 +0000
URL:        http://sources.gentoo.org/gitweb/?p=proj/kde.git;a=commit;h=8440fac7

[kde-apps/dolphin] Make tests optional

---
 kde-apps/dolphin/dolphin-5.9999.ebuild                     |  6 +++++-
 kde-apps/dolphin/files/dolphin-5.9999-tests-optional.patch | 11 +++++++++++
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/kde-apps/dolphin/dolphin-5.9999.ebuild 
b/kde-apps/dolphin/dolphin-5.9999.ebuild
index ce3acdb..05564bd 100644
--- a/kde-apps/dolphin/dolphin-5.9999.ebuild
+++ b/kde-apps/dolphin/dolphin-5.9999.ebuild
@@ -6,7 +6,9 @@ EAPI=5
 
 EGIT_BRANCH="frameworks"
 KMNAME="kde-baseapps"
-KDE_HANDBOOK=true
+KDE_HANDBOOK="true"
+KDE_TEST="true"
+VIRTUALX_REQUIRED="test"
 inherit kde5
 
 DESCRIPTION="KDE filemanager focusing on usability"
@@ -53,6 +55,8 @@ RDEPEND="${DEPEND}
        !kde-base/dolphin:4
 "
 
+PATCHES=( "${FILESDIR}/${PN}-5.9999-tests-optional.patch" )
+
 S=${S}/${PN}
 
 src_configure() {

diff --git a/kde-apps/dolphin/files/dolphin-5.9999-tests-optional.patch 
b/kde-apps/dolphin/files/dolphin-5.9999-tests-optional.patch
new file mode 100644
index 0000000..43aa648
--- /dev/null
+++ b/kde-apps/dolphin/files/dolphin-5.9999-tests-optional.patch
@@ -0,0 +1,11 @@
+--- a/src/CMakeLists.txt       2015-01-19 02:45:45.207037408 +0100
++++ b/src/CMakeLists.txt       2015-01-19 02:52:38.558025089 +0100
+@@ -334,4 +334,7 @@
+ install( PROGRAMS settings/services/servicemenuinstallation DESTINATION 
${BIN_INSTALL_DIR} )
+ install( PROGRAMS settings/services/servicemenudeinstallation DESTINATION 
${BIN_INSTALL_DIR} )
+ 
+-add_subdirectory(tests)
++if(BUILD_TESTING)
++    find_package(Qt5Test ${QT_MIN_VERSION} CONFIG REQUIRED)
++    add_subdirectory(tests)
++endif()

Reply via email to