1
0
Fork 0

engine.cmake: Unix systems needs to link with X11 and Xrandr

This commit is contained in:
Henrik Hautakoski 2022-10-01 15:22:13 +02:00
parent 54aefa4bdd
commit a4f7c90f63

View file

@ -149,6 +149,10 @@ if (WIN32)
target_sources(Spectre PRIVATE ${ENGINE_PLATFORM_WIN32_SRC})
else()
target_sources(Spectre PRIVATE ${ENGINE_PLATFORM_UNIX_SRC})
# Unix needs to link against X11
find_package(X11 REQUIRED COMPONENTS Xrandr)
target_link_libraries(Spectre PRIVATE X11::X11 X11::Xrandr)
endif (WIN32)
# Select graphics API