Hi guys,
in this page https://cmake.org/cmake/help/latest/command/set_directory_properties.html there is a sentence
Sets properties of the current directory and its subdirectories in key-value pairs.
I’m trying to verify it by (in parent CMakeLists.txt)
set_directory_properties(PROPERTIES prop1 value1)
add_subdirectory(sub)
and
add_subdirectory(sub)
set_directory_properties(PROPERTIES prop1 value1)
in sub/CMakeLists.txt
get_directory_property(x prop1)
message("prop1 `${x}`")
in both case I cannot read prop1 , any suggestion?