Add explicit POSITION_INDEPENDENT_CODE
This commit is contained in:
parent
de3aa69c1e
commit
f0376367b1
8 changed files with 9 additions and 0 deletions
|
@ -32,6 +32,7 @@ endfunction()
|
|||
|
||||
macro(KWIN4_ADD_EFFECT_MODULE name)
|
||||
kcoreaddons_add_plugin(${name} STATIC SOURCES ${ARGN} INSTALL_NAMESPACE "kwin/effects/plugins")
|
||||
set_property(TARGET ${name} PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
kwin_strip_builtin_effect_metadata(${name} metadata.json)
|
||||
install(FILES metadata.json DESTINATION ${KDE_INSTALL_DATADIR}/${KWIN_NAME}/builtin-effects/${name}/)
|
||||
endmacro()
|
||||
|
|
|
@ -3,6 +3,7 @@ set(idletime_plugin_SRCS
|
|||
)
|
||||
|
||||
add_library(KF5IdleTimeKWinPlugin OBJECT ${idletime_plugin_SRCS})
|
||||
set_property(TARGET KF5IdleTimeKWinPlugin PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_compile_definitions(KF5IdleTimeKWinPlugin PRIVATE QT_STATICPLUGIN)
|
||||
target_link_libraries(KF5IdleTimeKWinPlugin
|
||||
KF5::IdleTime
|
||||
|
|
|
@ -3,5 +3,6 @@ set(kglobalaccel_plugin_SRCS
|
|||
)
|
||||
|
||||
add_library(KF5GlobalAccelKWinPlugin OBJECT ${kglobalaccel_plugin_SRCS})
|
||||
set_property(TARGET KF5GlobalAccelKWinPlugin PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_compile_definitions(KF5GlobalAccelKWinPlugin PRIVATE QT_STATICPLUGIN)
|
||||
target_link_libraries(KF5GlobalAccelKWinPlugin KF5::GlobalAccelPrivate kwin)
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
add_library(KWinQpaPlugin OBJECT)
|
||||
set_property(TARGET KWinQpaPlugin PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_sources(KWinQpaPlugin PRIVATE
|
||||
backingstore.cpp
|
||||
eglhelpers.cpp
|
||||
|
|
|
@ -6,5 +6,6 @@ set(kwindowsystem_plugin_SRCS
|
|||
)
|
||||
|
||||
add_library(KF5WindowSystemKWinPlugin OBJECT ${kwindowsystem_plugin_SRCS})
|
||||
set_property(TARGET KF5WindowSystemKWinPlugin PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_compile_definitions(KF5WindowSystemKWinPlugin PRIVATE QT_STATICPLUGIN)
|
||||
target_link_libraries(KF5WindowSystemKWinPlugin kwin)
|
||||
|
|
|
@ -8,6 +8,7 @@ endif()
|
|||
# CMake has a known bug where target_source() doesn't work as expected with files generated
|
||||
# in a directory other than the one where the target is defined. It should be fixed in 3.20.
|
||||
add_library(WaylandProtocols_xml OBJECT)
|
||||
set_property(TARGET WaylandProtocols_xml PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_link_libraries(WaylandProtocols_xml Qt::Core Wayland::Server)
|
||||
target_link_libraries(kwin WaylandProtocols_xml)
|
||||
|
||||
|
|
|
@ -16,4 +16,5 @@ add_library(KWinXwaylandServerModule OBJECT
|
|||
xwldrophandler.cpp
|
||||
xwaylandlauncher.cpp
|
||||
)
|
||||
set_property(TARGET KWinXwaylandServerModule PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
target_link_libraries(KWinXwaylandServerModule PUBLIC kwin KWinXwaylandCommon)
|
||||
|
|
|
@ -14,5 +14,7 @@ ecm_qt_declare_logging_category(KWinXwaylandCommon
|
|||
Warning
|
||||
)
|
||||
|
||||
set_property(TARGET KWinXwaylandCommon PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||
|
||||
target_include_directories(KWinXwaylandCommon PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
target_link_libraries(KWinXwaylandCommon Qt::Core Qt::Network)
|
||||
|
|
Loading…
Reference in a new issue