From ab96f77d9e7406ed148ac82ba6e878f83fe25aa7 Mon Sep 17 00:00:00 2001 From: Quantum Date: Mon, 11 Jan 2021 23:33:53 -0500 Subject: [PATCH] [client] wm/wayland: generate protocol files into the build dir This avoids polluting the source tree. --- client/CMakeLists.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index f94835b6..7d490c46 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -141,15 +141,17 @@ if(ENABLE_WAYLAND) target_sources(looking-glass-client PRIVATE "${output_file}.h" "${output_file}.c") endmacro() + file(MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/wayland") + include_directories("${CMAKE_BINARY_DIR}/wayland") wayland_generate( "${WAYLAND_PROTOCOLS_BASE}/unstable/relative-pointer/relative-pointer-unstable-v1.xml" - "${PROJECT_TOP}/client/src/wayland-relative-pointer-unstable-v1-client-protocol") + "${CMAKE_BINARY_DIR}/wayland/wayland-relative-pointer-unstable-v1-client-protocol") wayland_generate( "${WAYLAND_PROTOCOLS_BASE}/unstable/pointer-constraints/pointer-constraints-unstable-v1.xml" - "${PROJECT_TOP}/client/src/wayland-pointer-constraints-unstable-v1-client-protocol") + "${CMAKE_BINARY_DIR}/wayland/wayland-pointer-constraints-unstable-v1-client-protocol") wayland_generate( "${WAYLAND_PROTOCOLS_BASE}/unstable/keyboard-shortcuts-inhibit/keyboard-shortcuts-inhibit-unstable-v1.xml" - "${PROJECT_TOP}/client/src/wayland-keyboard-shortcuts-inhibit-unstable-v1-client-protocol") + "${CMAKE_BINARY_DIR}/wayland/wayland-keyboard-shortcuts-inhibit-unstable-v1-client-protocol") endif() feature_summary(WHAT ENABLED_FEATURES DISABLED_FEATURES)