0

This is my first time using cmake gui in windows. I am trying to install the vsomeip library in Windows. This is mainly required for my common API someip application. Now, I am having issue to compile the vsomeip library. When I run CMake gui, it says Could NOT find Boost (missing: system thread filesystem) (found suitable version "1.67.0", minimum required is "1.55")

I have already added the boost directory to my environment Path variable. I am not sure whether are there any additional configurations is required. When I try the same in Linux, it works fine. Only in Windows there is an issue.

Raaj Lokanathan
  • 479
  • 3
  • 7
  • 19
  • How did you install Boost? Did you build it? – rustyx Aug 10 '20 at 08:13
  • @rustyx I installed the .exe in Windows. – Raaj Lokanathan Aug 10 '20 at 08:30
  • Can you use the CMake GUI to define the CMake variable `Boost_DEBUG` to `ON` then provide the output in your question post? This will show more information about how CMake is locating Boost on your system. Also, are you able to verify that the "missing" libraries (e.g. filesystem) actually exist on your system, and that they match the compiler you are trying to use with CMake? – Kevin Aug 10 '20 at 13:01
  • @squareskittles as you mentioned i checked the compiler is not matching. In my windows my compiler is vc140-vc142 but in the boost.exe it is using vc120. – Raaj Lokanathan Nov 03 '20 at 06:35

1 Answers1

0

I fixed the issue by changing the boost version inside the boost/version.hpp.

Previously the version was written as 1_55_0. So I just changed the version to 1_55.

The other fixed was to add the environment variable Path. I added the boost include directory itself: C:\local\boost_1_55_0\boost

I am not sure this is the right way for the fix but this fixes worked for me. Maybe if you guys have better solution can share it here.

Raaj Lokanathan
  • 479
  • 3
  • 7
  • 19
  • 1
    Manually changing the Boost version in the `version.hpp` is certainly not recommended. – Kevin Aug 12 '20 at 12:57
  • The error message is **typically** indicative of a *mismatch* between the compiler/architecture used for your CMake project and the compiler/architecture of the Boost libraries for that Boost version on your system. It can **usually** be corrected by re-building the Boost libraries for the *correct* compiler and architecture (based on that used by your CMake project), or by opting to build and use static or shared Boost libraries using CMake, as sometimes only one type is built. – Kevin Aug 21 '20 at 12:14
  • @squareskittles currently I am not building boost in windows. I am simply using the prebuilt binaries directly. If this is the case how can I fix my problem? Because right now, with 1.58 I am not able to build my vsomeip3 library. it says system, thread and log is not found. And when i enable the debug flag I can see that the boost_compiler is guessing vc142 but my prebuilt libraries are vc120. – Raaj Lokanathan Nov 03 '20 at 06:32
  • As my previous comment suggested, it sounds like you have installed the *wrong version* of the Boost binaries on your system. If your compiler requires the vc142 version, then you must download that version, not the vc120 binaries... – Kevin Nov 03 '20 at 18:43
  • @squareskittles but, the strange thing is my compiler is using vc142, but when I manually compile the boost library using the `.\b2` command the compiler uses vc140. How can I really make sure the compiler I am using is vc142? – Raaj Lokanathan Nov 05 '20 at 03:12
  • There are several arguments you can provide to `b2` to control how it builds the Boost libraries (read up on it [here](https://boostorg.github.io/build/manual/develop/index.html)). One of these arguments is `toolset`, so you can do `.\b2 -j4 toolset=msvc-14.2` – Kevin Nov 05 '20 at 03:20
  • wow that's great, let me give it a try then. will let you know the outcome. – Raaj Lokanathan Nov 05 '20 at 04:10
  • @squareskittles I tried using the following command as you mentioned, but I am getting error `'cl' is not recognized as an internal or external command, operable program or batch file.` – Raaj Lokanathan Nov 05 '20 at 06:01
  • A quick Google search led me to this: https://stackoverflow.com/questions/42793958/building-boost-build-engine-cl-is-not-recognized-as-an-internal-or-external-co – Kevin Nov 05 '20 at 17:03