Uh oh!
There was an error while loading. Please reload this page.
Fix CMake CMP0167 Warning - #1170
Conversation
When I was building the source code of msgpack-c, I encountered a CMP0167 warning. Although it did not affect the code building process, it was a minor flaw. I believed that adding CONFIG to `find_package(Boost REQUIRED)` could solve the issue. Therefore, I organized the code repository and fixed this minor issue.
SSDGADsss
commented
Jan 8, 2026
It seems that all the test cases on macOS have failed, but I noticed that the previous commit had already fixed the issue with the CMake version. Should I adjust the CMake version to a later one? I would appreciate any guidance from the maintainer. |
redboltz
commented
Jan 9, 2026
@SSDGADsss Thank you for sending the PR. If your branch was created based on the older point of cpp_master, please rebase your branch form the up to date cpp_master. |
SSDGADsss
commented
Jan 9, 2026
I checked, and the latest commit hash for the |
redboltz
commented
Jan 9, 2026
The CI log indicates that all tests are passed. tests are executed from this line: Then test-install process started. In the test-install process, the following CMakeLists.txt is read. cmake_minimum_required(VERSION3.1FATAL_ERROR)It is incompatible to the root one. https://github.com/SSDGADsss/msgpack-c/blob/fix_cmake_CP0167/CMakeLists.txt#L1 CMAKE_MINIMUM_REQUIRED (VERSION3.5...4.0)I guess that test-install/CMakeLists.txt should be cmake_minimum_required(VERSION3.5...4.0)NOTE: FATAL_ERROR is default behavior. It is no longer needed. Could you try this? |
SSDGADsss
commented
Jan 9, 2026
Thank you very much, I'll fix this issue |
SSDGADsss
commented
Jan 9, 2026
There's only one last error left. It seems the issue is in the DevOps continuous integration part, with the error being that the Boost library cannot be found. I revisited the CMake FindBoost documentation—could it be due to an outdated Boost version? While reviewing previous issues, I found that defining |
redboltz
commented
Jan 10, 2026
It seems that the appveyor image has various versions of boost. So replacing https://github.com/SSDGADsss/msgpack-c/blob/fix_cmake_CP0167/appveyor.yml#L12 boost_prefix:C:\Libraries\boost_1_69_0to boost_prefix:C:\Libraries\boost_1_86_0would work. Could you try this? |
SSDGADsss
commented
Jan 11, 2026
Thank you very much for your help. I'll give it another try |
a6a0b35 to
cc7b67aComparecc7b67a to
b1d4944CompareI tried modifying CMAKE_PREFIX_PATH to |
redboltz
commented
Jan 11, 2026
It seems that your branch is not rebased.
I overlooked this comment. |
redboltz
commented
Jan 11, 2026
You need to add debug code to appveyor.yml (e.g. enter DIR command to check boost dir, etc) |
redboltz
commented
Jan 12, 2026
Sorry, I misunderstood something. Your branch is correctly created. |
redboltz
commented
Jan 12, 2026
I will investigate the appveyor problem using #1171 |
When I was building the source code of msgpack-c, I encountered a CMP0167 warning. Although it did not affect the code building process, it was a minor flaw. I believed that adding CONFIG to
find_package(Boost REQUIRED)could solve the issue. Therefore, I organized the code repository and fixed this minor issue.