mirror of
https://codeberg.org/dnkl/yambar.git
synced 2025-04-23 04:25:42 +02:00
cmake: (maybe) build xcb-stuff STATIC library with -fPIC
When building plugins as shared libraries, xcb-stuff needs to be built with -fPIC, since a couple of the plugins link against it.
This commit is contained in:
parent
d185f7237d
commit
e4f3695f5e
1 changed files with 7 additions and 0 deletions
|
@ -47,6 +47,13 @@ if (ENABLE_X11)
|
||||||
target_link_libraries(xcb-stuff PkgConfig::xcb-errors)
|
target_link_libraries(xcb-stuff PkgConfig::xcb-errors)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
# Since there are plugins linking against xcb-stuff, we need to
|
||||||
|
# ensure it's compiled with -fPIC when the plugins are compiled as
|
||||||
|
# shared libraries.
|
||||||
|
if (CORE_PLUGINS_AS_SHARED_LIBRARIES)
|
||||||
|
set_property(TARGET xcb-stuff PROPERTY POSITION_INDEPENDENT_CODE 1)
|
||||||
|
endif ()
|
||||||
|
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if (ENABLE_WAYLAND)
|
if (ENABLE_WAYLAND)
|
||||||
|
|
Loading…
Add table
Reference in a new issue