diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2021-11-27 14:39:13 +0100 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2022-08-06 09:44:07 +0200 |
commit | d4bedf3b05b25d89a0bf4b6293ac87eeb296ce38 (patch) | |
tree | eec66fb2ffd875579cf2a35c53ecde353365d18a /kde-apps/konqueror | |
parent | kde-apps/kalarm: Fix build with USE -X (diff) | |
download | gentoo-d4bedf3b05b25d89a0bf4b6293ac87eeb296ce38.tar.gz gentoo-d4bedf3b05b25d89a0bf4b6293ac87eeb296ce38.tar.bz2 gentoo-d4bedf3b05b25d89a0bf4b6293ac87eeb296ce38.zip |
kde-apps/konqueror: Fix build with USE -X
Upstream commit ff0e19961f8345faea54e4f85057312b7ad7007d
Bug: https://bugs.gentoo.org/813450
Package-Manager: Portage-3.0.28, Repoman-3.0.3
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'kde-apps/konqueror')
-rw-r--r-- | kde-apps/konqueror/files/konqueror-22.04.3-with_x11.patch | 83 | ||||
-rw-r--r-- | kde-apps/konqueror/konqueror-22.04.3.ebuild | 4 |
2 files changed, 86 insertions, 1 deletions
diff --git a/kde-apps/konqueror/files/konqueror-22.04.3-with_x11.patch b/kde-apps/konqueror/files/konqueror-22.04.3-with_x11.patch new file mode 100644 index 000000000000..90273b072f0e --- /dev/null +++ b/kde-apps/konqueror/files/konqueror-22.04.3-with_x11.patch @@ -0,0 +1,83 @@ +From 69c2186c1a6c4fc0bf7f13b571b581e5f6157063 Mon Sep 17 00:00:00 2001 +From: Andreas Sturmlechner <asturm@gentoo.org> +Date: Sat, 27 Nov 2021 14:36:20 +0100 +Subject: [PATCH] Add CMake option to build without X11 + +Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> +--- + CMakeLists.txt | 16 ++++++++++------ + client/CMakeLists.txt | 4 ++-- + src/CMakeLists.txt | 6 +++--- + 3 files changed, 15 insertions(+), 11 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 77f5ea645..488ee7dc4 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -46,12 +46,16 @@ if(Qt5WebEngineWidgets_VERSION VERSION_LESS "5.14.0") + add_definitions(-DWEBENGINEDOWNLOADITEM_USE_PATH) + endif() + +-find_package(X11) +-set(KONQ_HAVE_X11 ${X11_FOUND}) +- +-if (X11_FOUND) +- find_package(Qt5 REQUIRED X11Extras) +-endif(X11_FOUND) ++if (NOT WIN32) ++ option(WITH_X11 "Build with X11 integration" ON) ++ if (WITH_X11) ++ find_package(X11 REQUIRED) ++ find_package(Qt5X11Extras NO_MODULE REQUIRED) ++ set(KONQ_HAVE_X11 TRUE) ++ endif() ++else() ++ set(WITH_X11 OFF) ++endif() + + add_definitions( + -DQT_USE_QSTRINGBUILDER +diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt +index 24aedb14c..51d2b44d0 100644 +--- a/client/CMakeLists.txt ++++ b/client/CMakeLists.txt +@@ -30,9 +30,9 @@ if (WIN32) + else (WIN32) + kf5_add_kdeinit_executable( kfmclient NOGUI ${kfmclient_SRCS}) + target_link_libraries(kdeinit_kfmclient ${kfmclient_LIBS}) +- if(X11_FOUND) ++ if(WITH_X11) + target_link_libraries(kdeinit_kfmclient Qt5::X11Extras) +- endif(X11_FOUND) ++ endif() + install(TARGETS kdeinit_kfmclient ${KDE_INSTALL_TARGETS_DEFAULT_ARGS} ) + endif (WIN32) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 2113e1c2f..07e64d90f 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -33,9 +33,9 @@ target_link_libraries(konquerorprivate + KF5::KIOGui + ) + +-if(X11_FOUND) ++if(WITH_X11) + target_link_libraries(konquerorprivate Qt5::X11Extras) +-endif(X11_FOUND) ++endif() + + + set_target_properties(konquerorprivate PROPERTIES VERSION ${KONQUEROR_LIB_VERSION} SOVERSION "5" ) +@@ -113,7 +113,7 @@ target_link_libraries(kdeinit_konqueror + KF5::SonnetUi + ) + +-if (X11_FOUND) ++if (WITH_X11) + target_link_libraries(kdeinit_konqueror ${X11_LIBRARIES}) + endif () + +-- +2.34.1 + diff --git a/kde-apps/konqueror/konqueror-22.04.3.ebuild b/kde-apps/konqueror/konqueror-22.04.3.ebuild index 6d69ff80806c..05c5705662e8 100644 --- a/kde-apps/konqueror/konqueror-22.04.3.ebuild +++ b/kde-apps/konqueror/konqueror-22.04.3.ebuild @@ -63,6 +63,8 @@ RDEPEND="${COMMON_DEPEND} kde-plasma/kde-cli-tools:5 " +PATCHES=( "${FILESDIR}/${P}-with_x11.patch" ) + src_prepare() { [[ ${CHOST} == *-solaris* ]] && append-ldflags -lmalloc @@ -74,7 +76,7 @@ src_configure() { -DCMAKE_DISABLE_FIND_PACKAGE_Hunspell=ON # requires fixing bug 634122 $(cmake_use_find_package activities KF5Activities) $(cmake_use_find_package speech Qt5TextToSpeech) - $(cmake_use_find_package X X11) + -DWITH_X11=$(usex X) ) ecm_src_configure } |