yaml-cpp
yaml-cpp copied to clipboard
Project name in root CMakeLists.txt
Trying to install yaml-cpp 0.7.0 on Windows, I see that the default install directory is YAML_CPP
instead of the expected yaml-cpp
directory under the CMAKE_SYSTEM_PREFIX_PATH
. It looks like it corresponds to the project name under CMake. Is that expected behaviour? It makes a basic find_package(yaml-cpp 0.7.0 REQUIRED)
fails, though can probably be fixed using the NAMES
hint but is still weird default.
cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
-DBUILD_SHARED_LIBS=ON \
-DYAML_CPP_BUILD_TESTS=OFF \
-DYAML_CPP_BUILD_TOOLS=OFF\
-DYAML_CPP_BUILD_CONTRIB=OFF \
../.
cmake --build . --target install --config Release --parallel
...
-- Installing: C:/Program Files (x86)/YAML_CPP/include
...