From 5a17a02abbf02286fa3b0a7c718251ffb595445b Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Mon, 23 Oct 2023 11:39:45 +0800 Subject: [PATCH] build: cmake: add -ffile-prefix-map option this mirrors what we already have in configure.py. Signed-off-by: Kefu Chai Closes scylladb/scylladb#15798 --- cmake/mode.common.cmake | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cmake/mode.common.cmake b/cmake/mode.common.cmake index 02c62380c7..554c19c8a0 100644 --- a/cmake/mode.common.cmake +++ b/cmake/mode.common.cmake @@ -78,6 +78,8 @@ function(get_padded_dynamic_linker_option output length) set(${output} "${dynamic_linker_option}=${padded_dynamic_linker}" PARENT_SCOPE) endfunction() +add_compile_options("-ffile-prefix-map=${CMAKE_SOURCE_DIR}=.") + default_target_arch(target_arch) if(target_arch) add_compile_options("-march=${target_arch}")