You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I build my project on CentOS 7.9 (using gcc version 4.8.5), it builds successfully.
However, when attempting to build the project on Windows with the following configuration:
I encountered an error in the CMakeLists.txt file. The specific error message is:
CMake Error at winbuild/_deps/toml11-src/src/CMakeLists.txt:140 (target_compile_definitions):
target_compile_definitions may only set INTERFACE properties on INTERFACE
I believe there are issues in the CMakeLists.txt file that need to be addressed for successful building on Windows with the specified configuration.
The text was updated successfully, but these errors were encountered:
As shown in my example, you should only need to make the necessary modifications as prompted ("target_compile_definitions may only set INTERFACE properties on INTERFACE"). Your library is excellent, thank you for your contribution. Regarding the issue of MSVC compilation failure, based on my experience, I recommend using VS2022 and installing toolchains for 2015, 2017, and 2019. You can test them one by one. I highly recommend using CMakePresets.json for platform-specific compilation settings. The initial JSON string is also part of my project's CMakePresets.json configuration. Once configured, you can achieve cross-platform packaging with a single command. For Linux, use cmake --workflow --preset Centos7Project, and for Windows, use cmake --workflow --preset VS2022-v140-Project.
When I build my project on CentOS 7.9 (using gcc version 4.8.5), it builds successfully.
However, when attempting to build the project on Windows with the following configuration:
I encountered an error in the CMakeLists.txt file. The specific error message is:
CMake Error at winbuild/_deps/toml11-src/src/CMakeLists.txt:140 (target_compile_definitions): target_compile_definitions may only set INTERFACE properties on INTERFACE
I believe there are issues in the CMakeLists.txt file that need to be addressed for successful building on Windows with the specified configuration.
The text was updated successfully, but these errors were encountered: