Closed MGuillaumeF closed 2 years ago
You've installed boost for mingw but you are trying to compile using msvc.
You should set the toolset
parameter to msvc
to install the proper binaries.
There should also be a warning issued about the toolset
parameter being unset.
Let me know if that fixed your problem or if you need further instructions :)
Thank you it works 😊
Great!
It doesn't fix mine, i still have the issue. 1.78.0 work but not 1.79.0 workflow https://github.com/cyberium/mangos-wotlk/blob/master/.github/workflows/windows-release.yml#L71
msvc is set https://github.com/cyberium/mangos-wotlk/runs/6422426953?check_suite_focus=true#step:6:4
fail https://github.com/cyberium/mangos-wotlk/runs/6422426953?check_suite_focus=true#step:8:116
i checked if something changed in boost api and i dont see anything in changelog related to this.
It work with my local version of boost and i have that file localy. So iam wondering if the filesystem support is correctly set on your images.
You might be able to fix this issue by adding
include_directories(${Boost_INCLUDE_DIRS})
to your CMakeLists.txt
after FindBoost
is invoked.
But clearly, the project you are trying to build is not meant to be built with boost 1.79:
CMake Warning at C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:1369 (message): New Boost version may have incorrect or missing dependencies and imported targets
Thank for your suggestion The include should be correctly done here
The build work on my local as i said, the only difference is the boost binaries and cmake version. I use latest one.
So i just went further and here is the content of your boost folder
Here is what i get on my local install
So issue is clearly in your image.
My test was with the version 1.78.0, i confirm with 1.79.0 the error is present,
See also "D:/a/cpp-coso/cpp-coso/bin/CMakeFiles/CMakeError.log".
* libboost_system-vc142-mt-gd-x32-1_79.lib (32 bit, need 64)
* libboost_system-vc142-mt-gd-x64-1_79.lib (vc142, detected vc143, set
Boost_COMPILER to override)
* libboost_system-vc142-mt-x32-1_79.lib (32 bit, need 64)
* libboost_system-vc142-mt-x64-1_79.lib (vc142, detected vc143,
*
it could be the arch of x64 / x86
like toolset it’s required to set value of arch on install step ?
Oh, you just tried to install binaries compiled for windows 2019 on a windows 2022 machine, this is unrelated
But 1.79.0 seems to cause issues, so I'll keep this open until I can find a fix
@cyberium You may want to try boost version 1.79.0.beta1
, this version should fix your Problem.
The issue seems to be the folder structure of the include directory (windows requires another build layout, of course it does), which doesn't work with boost 1.79.0
and CMake, for some reason. The structure is exactly the same as with previous versions, but this one just doesn't work that way. That's probably why CMake emits the warning about newer boost versions...whatever.
When moving the include directory, this seems to work fine, so let me know if that fix works for you (seems to work fine with your repository on my local machine) and I'll re-compile the binaries for version 1.79.0
🙂
I can confirm that 1.79.0.beta1
is working. Thank you very much.
Boost version 1.79.0
is now rebuilt. I'll close this issue, reopen if the issue still persists
Hello,
when add
find_package (Boost COMPONENTS system filesystem REQUIRED)
in my CMakeFile.txt, it's works well on MacOSX and Ubuntu in Job but failed with on Windows(on local it works with the same CMakeList.txt windows)
The code in job :
The error :
I don't know if Windows need extra parameters to works with boost::filesystem usage, have you ever encountered this problem ?