diff --git a/Meta/CMake/targets.cmake b/Meta/CMake/targets.cmake index e9aa582cff0..d4881dde3be 100644 --- a/Meta/CMake/targets.cmake +++ b/Meta/CMake/targets.cmake @@ -5,7 +5,7 @@ function(lagom_generate_export_header name fs_name) # to export symbols required by external consumers. This allows the codebase # to gradually slowly migrate instead of an all-or-nothing approach. if (NOT WIN32) - target_compile_options(${name} PRIVATE -fvisibility=hidden) + add_cxx_compile_options(${name} PRIVATE -fvisibility=hidden) else() set_target_properties(${name} PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS OFF) endif()