From 39cb21dfc0780bda4c08420500ca026a274cc0cb Mon Sep 17 00:00:00 2001 From: Nicolas Lebedenco Date: Tue, 2 Apr 2024 08:52:20 -0400 Subject: [PATCH] cmake: Fix invalid calls of set_compiler_property set_compiler_property does not accept a TARGET argument. Only set_property does but they are easy to confuse. This patch fixes the wrong instances of set_compiler_property that should have been set_property. Signed-off-by: Nicolas Lebedenco --- cmake/compiler/compiler_flags_template.cmake | 2 +- cmake/compiler/gcc/compiler_flags.cmake | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/compiler/compiler_flags_template.cmake b/cmake/compiler/compiler_flags_template.cmake index 53e37287b9f..a18ef39d916 100644 --- a/cmake/compiler/compiler_flags_template.cmake +++ b/cmake/compiler/compiler_flags_template.cmake @@ -51,7 +51,7 @@ set_compiler_property(PROPERTY nostdinc) set_compiler_property(PROPERTY nostdinc_include) # Compiler flags for disabling C++ standard include. -set_compiler_property(TARGET compiler-cpp PROPERTY nostdincxx) +set_property(TARGET compiler-cpp PROPERTY nostdincxx) # Required C++ flags when compiling C++ code set_property(TARGET compiler-cpp PROPERTY required) diff --git a/cmake/compiler/gcc/compiler_flags.cmake b/cmake/compiler/gcc/compiler_flags.cmake index 14cd3e67889..be08cc18bad 100644 --- a/cmake/compiler/gcc/compiler_flags.cmake +++ b/cmake/compiler/gcc/compiler_flags.cmake @@ -121,7 +121,7 @@ endif() set_compiler_property(PROPERTY no_printf_return_value -fno-printf-return-value) -set_compiler_property(TARGET compiler-cpp PROPERTY nostdincxx "-nostdinc++") +set_property(TARGET compiler-cpp PROPERTY nostdincxx "-nostdinc++") # Required C++ flags when using gcc set_property(TARGET compiler-cpp PROPERTY required "-fcheck-new")