Updated cmake sources to TDesktop version 3.5.2+93a9f34
This commit is contained in:
commit
d4a3a67bad
4 changed files with 11 additions and 110 deletions
11
external/jemalloc/CMakeLists.txt
vendored
11
external/jemalloc/CMakeLists.txt
vendored
|
|
@ -33,11 +33,16 @@ endif()
|
||||||
include(ExternalProject)
|
include(ExternalProject)
|
||||||
ExternalProject_Add(jemalloc
|
ExternalProject_Add(jemalloc
|
||||||
URL ${third_party_loc}/jemalloc
|
URL ${third_party_loc}/jemalloc
|
||||||
CONFIGURE_COMMAND cd "<SOURCE_DIR>" && export EXTRA_CFLAGS=-fstack-protector-all\ -fPIC\ -D_FORTIFY_SOURCE=2 && export EXTRA_CXXFLAGS=-fstack-protector-all\ -fPIC\ -D_FORTIFY_SOURCE=2 && CC=clang CXX=clang++ ./autogen.sh
|
CONFIGURE_COMMAND env
|
||||||
|
CC=clang
|
||||||
|
CXX=clang++
|
||||||
|
"EXTRA_CFLAGS=-fstack-protector-all -D_FORTIFY_SOURCE=2"
|
||||||
|
"EXTRA_CXXFLAGS=-fstack-protector-all -D_FORTIFY_SOURCE=2"
|
||||||
|
./autogen.sh --disable-shared
|
||||||
BUILD_IN_SOURCE 1
|
BUILD_IN_SOURCE 1
|
||||||
STEP_TARGETS build
|
STEP_TARGETS build
|
||||||
EXCLUDE_FROM_ALL TRUE
|
EXCLUDE_FROM_ALL TRUE
|
||||||
BUILD_BYPRODUCTS <SOURCE_DIR>/lib/libjemalloc.a
|
BUILD_BYPRODUCTS <SOURCE_DIR>/lib/libjemalloc_pic.a
|
||||||
)
|
)
|
||||||
|
|
||||||
ExternalProject_Get_property(jemalloc SOURCE_DIR)
|
ExternalProject_Get_property(jemalloc SOURCE_DIR)
|
||||||
|
|
@ -50,7 +55,7 @@ INTERFACE
|
||||||
|
|
||||||
target_link_libraries(external_jemalloc
|
target_link_libraries(external_jemalloc
|
||||||
INTERFACE
|
INTERFACE
|
||||||
-Wl,--push-state,--whole-archive,${SOURCE_DIR}/lib/libjemalloc.a,--pop-state,-ldl
|
-Wl,--push-state,--whole-archive,${SOURCE_DIR}/lib/libjemalloc_pic.a,--pop-state
|
||||||
)
|
)
|
||||||
|
|
||||||
add_dependencies(external_jemalloc jemalloc-build)
|
add_dependencies(external_jemalloc jemalloc-build)
|
||||||
|
|
|
||||||
9
external/kwayland/CMakeLists.txt
vendored
9
external/kwayland/CMakeLists.txt
vendored
|
|
@ -76,11 +76,6 @@ ExternalProject_Add_StepDependencies(plasma-wayland-protocols configure extra-cm
|
||||||
ExternalProject_Get_property(plasma-wayland-protocols BINARY_DIR)
|
ExternalProject_Get_property(plasma-wayland-protocols BINARY_DIR)
|
||||||
set(plasma_wayland_protocols_binary_dir ${BINARY_DIR})
|
set(plasma_wayland_protocols_binary_dir ${BINARY_DIR})
|
||||||
|
|
||||||
set(kwayland_patch_command)
|
|
||||||
if (DESKTOP_APP_QT6)
|
|
||||||
set(kwayland_patch_command PATCH_COMMAND patch -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/kwayland-qt6.patch)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
ExternalProject_Add(kwayland
|
ExternalProject_Add(kwayland
|
||||||
URL ${third_party_loc}/kwayland
|
URL ${third_party_loc}/kwayland
|
||||||
CMAKE_GENERATOR Ninja
|
CMAKE_GENERATOR Ninja
|
||||||
|
|
@ -88,11 +83,11 @@ ExternalProject_Add(kwayland
|
||||||
-DCMAKE_BUILD_TYPE=Release
|
-DCMAKE_BUILD_TYPE=Release
|
||||||
-DBUILD_SHARED_LIBS=OFF
|
-DBUILD_SHARED_LIBS=OFF
|
||||||
-DBUILD_TESTING=OFF
|
-DBUILD_TESTING=OFF
|
||||||
|
-DBUILD_WITH_QT6=${DESKTOP_APP_QT6}
|
||||||
|
-DEXCLUDE_DEPRECATED_BEFORE_AND_AT=5.91.0
|
||||||
-DCMAKE_PREFIX_PATH=${wayland_protocols_binary_dir}
|
-DCMAKE_PREFIX_PATH=${wayland_protocols_binary_dir}
|
||||||
-DECM_DIR=${extra_cmake_modules_binary_dir}/share/ECM/cmake
|
-DECM_DIR=${extra_cmake_modules_binary_dir}/share/ECM/cmake
|
||||||
-DPlasmaWaylandProtocols_DIR=${plasma_wayland_protocols_binary_dir}/lib/cmake/PlasmaWaylandProtocols
|
-DPlasmaWaylandProtocols_DIR=${plasma_wayland_protocols_binary_dir}/lib/cmake/PlasmaWaylandProtocols
|
||||||
${kwayland_patch_command}
|
|
||||||
BUILD_COMMAND ${CMAKE_COMMAND} --build <BINARY_DIR> --target KF5WaylandClient
|
|
||||||
STEP_TARGETS build
|
STEP_TARGETS build
|
||||||
EXCLUDE_FROM_ALL TRUE
|
EXCLUDE_FROM_ALL TRUE
|
||||||
BUILD_BYPRODUCTS <BINARY_DIR>/lib/libKF5WaylandClient.a
|
BUILD_BYPRODUCTS <BINARY_DIR>/lib/libKF5WaylandClient.a
|
||||||
|
|
|
||||||
99
external/kwayland/kwayland-qt6.patch
vendored
99
external/kwayland/kwayland-qt6.patch
vendored
|
|
@ -1,99 +0,0 @@
|
||||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
||||||
index b478cde..5f19170 100644
|
|
||||||
--- a/CMakeLists.txt
|
|
||||||
+++ b/CMakeLists.txt
|
|
||||||
@@ -31,10 +31,8 @@ ecm_setup_version(PROJECT VARIABLE_PREFIX KWAYLAND
|
|
||||||
|
|
||||||
# Dependencies
|
|
||||||
set(REQUIRED_QT_VERSION 5.15.2)
|
|
||||||
-find_package(Qt5Gui ${REQUIRED_QT_VERSION} REQUIRED NO_MODULE COMPONENTS Private)
|
|
||||||
-find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Concurrent WaylandClient)
|
|
||||||
-
|
|
||||||
-find_package(QtWaylandScanner REQUIRED)
|
|
||||||
+find_package(Qt6Gui ${REQUIRED_QT_VERSION} REQUIRED NO_MODULE COMPONENTS Private)
|
|
||||||
+find_package(Qt6 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Concurrent WaylandClient)
|
|
||||||
|
|
||||||
find_package(Wayland 1.15 COMPONENTS Client Server)
|
|
||||||
set_package_properties(Wayland PROPERTIES
|
|
||||||
@@ -69,14 +67,8 @@ add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x050f02)
|
|
||||||
# Subdirectories
|
|
||||||
ecm_install_po_files_as_qm(po)
|
|
||||||
|
|
||||||
-find_package(QtWaylandScanner REQUIRED)
|
|
||||||
add_subdirectory(src)
|
|
||||||
|
|
||||||
-if (BUILD_TESTING)
|
|
||||||
- add_subdirectory(autotests)
|
|
||||||
- add_subdirectory(tests)
|
|
||||||
-endif()
|
|
||||||
-
|
|
||||||
# create a Config.cmake and a ConfigVersion.cmake file and install them
|
|
||||||
set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KF5Wayland")
|
|
||||||
|
|
||||||
diff --git a/KF5WaylandConfig.cmake.in b/KF5WaylandConfig.cmake.in
|
|
||||||
index ef20432..1294d3e 100644
|
|
||||||
--- a/KF5WaylandConfig.cmake.in
|
|
||||||
+++ b/KF5WaylandConfig.cmake.in
|
|
||||||
@@ -1,7 +1,7 @@
|
|
||||||
@PACKAGE_INIT@
|
|
||||||
|
|
||||||
include(CMakeFindDependencyMacro)
|
|
||||||
-find_dependency(Qt5Gui @REQUIRED_QT_VERSION@)
|
|
||||||
+find_dependency(Qt6Gui @REQUIRED_QT_VERSION@)
|
|
||||||
|
|
||||||
include("${CMAKE_CURRENT_LIST_DIR}/KF5WaylandTargets.cmake")
|
|
||||||
@PACKAGE_INCLUDE_QCHTARGETS@
|
|
||||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
|
||||||
index c8a307c..e6497c8 100644
|
|
||||||
--- a/src/CMakeLists.txt
|
|
||||||
+++ b/src/CMakeLists.txt
|
|
||||||
@@ -1,6 +1,4 @@
|
|
||||||
add_subdirectory(client)
|
|
||||||
-add_subdirectory(server)
|
|
||||||
-add_subdirectory(tools)
|
|
||||||
|
|
||||||
ecm_qt_install_logging_categories(
|
|
||||||
EXPORT KWAYLAND
|
|
||||||
@@ -36,7 +34,7 @@ if(BUILD_QCH)
|
|
||||||
${KWaylandServer_APIDOX_SRCS}
|
|
||||||
MD_MAINPAGE "${CMAKE_SOURCE_DIR}/README.md"
|
|
||||||
LINK_QCHS
|
|
||||||
- Qt5Gui_QCH
|
|
||||||
+ Qt6Gui_QCH
|
|
||||||
INCLUDE_DIRS
|
|
||||||
${KWaylandClient_APIDOX_BUILD_INCLUDE_DIRS}
|
|
||||||
${KWaylandServer_APIDOX_BUILD_INCLUDE_DIRS}
|
|
||||||
diff --git a/src/client/CMakeLists.txt b/src/client/CMakeLists.txt
|
|
||||||
index b7ec33a..efb390a 100644
|
|
||||||
--- a/src/client/CMakeLists.txt
|
|
||||||
+++ b/src/client/CMakeLists.txt
|
|
||||||
@@ -3,7 +3,7 @@ remove_definitions(-DQT_NO_CAST_FROM_ASCII)
|
|
||||||
remove_definitions(-DQT_NO_CAST_TO_ASCII)
|
|
||||||
|
|
||||||
# needed to access QPA
|
|
||||||
-include_directories(SYSTEM ${Qt5Gui_PRIVATE_INCLUDE_DIRS})
|
|
||||||
+include_directories(SYSTEM ${Qt6Gui_PRIVATE_INCLUDE_DIRS})
|
|
||||||
|
|
||||||
set(CLIENT_LIB_SRCS
|
|
||||||
appmenu.cpp
|
|
||||||
@@ -256,10 +256,17 @@ ecm_generate_export_header(KF5WaylandClient
|
|
||||||
|
|
||||||
target_include_directories(KF5WaylandClient INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF5}/KWayland/Client>")
|
|
||||||
|
|
||||||
+target_include_directories(KF5WaylandClient
|
|
||||||
+ PRIVATE ${Wayland_Client_INCLUDE_DIR}
|
|
||||||
+ ${Qt6Concurrent_INCLUDE_DIRS}
|
|
||||||
+)
|
|
||||||
+
|
|
||||||
+get_target_property(Qt6Concurrent_LIBRARIES Qt6::Concurrent IMPORTED_LOCATION)
|
|
||||||
+
|
|
||||||
target_link_libraries(KF5WaylandClient
|
|
||||||
- PUBLIC Qt5::Gui
|
|
||||||
- PRIVATE Wayland::Client
|
|
||||||
- Qt5::Concurrent
|
|
||||||
+ PUBLIC Qt6::Gui
|
|
||||||
+ PRIVATE ${Wayland_Client_LIBRARY}
|
|
||||||
+ ${Qt6Concurrent_LIBRARIES}
|
|
||||||
)
|
|
||||||
|
|
||||||
set_target_properties(KF5WaylandClient PROPERTIES VERSION ${KWAYLAND_VERSION}
|
|
||||||
|
|
@ -64,8 +64,8 @@ endif()
|
||||||
|
|
||||||
target_link_libraries(common_options
|
target_link_libraries(common_options
|
||||||
INTERFACE
|
INTERFACE
|
||||||
desktop-app::linux_jemalloc_helper
|
|
||||||
$<TARGET_OBJECTS:desktop-app::linux_jemalloc_helper>
|
$<TARGET_OBJECTS:desktop-app::linux_jemalloc_helper>
|
||||||
|
$<LINK_ONLY:desktop-app::external_jemalloc>
|
||||||
${CMAKE_DL_LIBS}
|
${CMAKE_DL_LIBS}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue