我在顶级 CMakeLists.txt 中有一个简单的 find_package(pack 1.0.0 REQUIRED EXACT) 现在,我想给出一个特定的格式,如 MAJOR.MINOR.PATCH/TWEAK 并使用 find_package 设置这些变量。我怎样才能做到这一点?我阅读了有关 _MAJOR_VERSION 等的 cmake 文档,但无法获取有关我的特定场景的示例或详细信息:https://c...
and newer MAJOR API versions of it, using FindPkgConfig*** Supposedly something similar is possible with find_package's .cmake files as installed by write_basic_package_version_file? How do I provide a PackageNameConfigVersion.cmake for major version 1.0 and 2.0 (the equivalent of PackageNam...
<< TBB_VERSION_MAJOR << "." << TBB_VERSION_MINOR << "." << TBB_VERSION_PATCH << "!" << std::endl; return 0; } windows11+powershell cmake .. PSD:\work\modern_cmake_work\ModernCMake\codes\oneAPI\oneTBB\info\info01\build>cmake..--Buildingfor:VisualStudio172022--SelectingWindow...