CMake: Don't mess with absolute compile_ipc() source paths

If given an absolute path, compile_ipc() should just use it verbatim
instead of trying to be helpful.
This commit is contained in:
Andreas Kling 2022-10-06 11:23:53 +02:00
parent b5681992e1
commit 2ac385f4db

View file

@ -19,7 +19,9 @@ function(compile_gml source output string_name)
endfunction()
function(compile_ipc source output)
set(source ${CMAKE_CURRENT_SOURCE_DIR}/${source})
if (NOT IS_ABSOLUTE ${source})
set(source ${CMAKE_CURRENT_SOURCE_DIR}/${source})
endif()
add_custom_command(
OUTPUT ${output}
COMMAND $<TARGET_FILE:Lagom::IPCCompiler> ${source} > ${output}.tmp