From 77efa57e0a2812ac248b9f6ac097e77b411a463f Mon Sep 17 00:00:00 2001 From: Jakob Bornecrantz Date: Wed, 4 Oct 2023 00:38:52 +0100 Subject: [PATCH] c/render: Make library usable on it's own in cmake --- src/xrt/compositor/CMakeLists.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/xrt/compositor/CMakeLists.txt b/src/xrt/compositor/CMakeLists.txt index e2c852708..6ac672995 100644 --- a/src/xrt/compositor/CMakeLists.txt +++ b/src/xrt/compositor/CMakeLists.txt @@ -124,12 +124,14 @@ if(XRT_HAVE_VULKAN) render/render_shaders.c render/render_util.c ) + # The aux_vk library needs to be public to include Vulkan. target_link_libraries( comp_render - PUBLIC xrt-interfaces - PRIVATE aux_util aux_os aux_vk + PUBLIC xrt-interfaces aux_vk + PRIVATE aux_util aux_os ) - target_include_directories(comp_render PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}) + # So it can be used without any other compositor libraries. + target_include_directories(comp_render PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}) # Shaders - marked SYSTEM so we get no warnings target_include_directories(comp_render SYSTEM PRIVATE ${CMAKE_CURRENT_BINARY_DIR})