title: CMake Error: Could NOT find Boost (missing: system filesystem thread log locale regex chrono atomic date_time) (found version "1.75.0")
body: <p>I am attempting to build and run a c++ program from GitHub, although i keep running into problems presumably with Cmake and the boost libraries. It is the first time i have tried building a program, so there is probably something obvious missing.</p>
  <p>The program in question is from the following GitHub repository: <a href="https://github.com/antimix/PrusaSlicer" rel="nofollow noreferrer">https://github.com/antimix/PrusaSlicer</a>. I am opening the folder i Visual Studio Code as an administrator (to remove some other error) with the Cmake and Cmake tools extensions installed. I have installed 1.75.0 Boost from this site: <a href="https://boost.teeks99.com/" rel="nofollow noreferrer">https://boost.teeks99.com/</a>. From the Visual Code terminal I get the following error(s):</p>
  <pre><code>[cmake] CMake Error at C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  [cmake]   Could NOT find Boost (missing: system filesystem thread log locale regex
  [cmake]   chrono atomic date_time) (found version &quot;1.75.0&quot;)
  [cmake] Call Stack (most recent call first):
  [cmake]   C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  [cmake]   C:/Program Files/CMake/share/cmake-3.20/Modules/FindBoost.cmake:2344 (find_package_handle_standard_args)
  [cmake]   CMakeLists.txt:266 (find_package)
  </code></pre>
  <p>And here is the full log:</p>
  <pre><code>[variant] Loaded new set of variants
  [kit] Successfully loaded 8 kits from C:\Users\*user*\AppData\Local\CMakeTools\cmake-tools-kits.json
  [main] Configuring folder: PrusaSlicer-dribbling_2.2.0 
  [proc] Executing command: &quot;C:\Program Files\CMake\bin\cmake.EXE&quot; &quot;-Hc:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0&quot; &quot;-Bc:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build&quot; -G &quot;Visual Studio 16 2019&quot; -T host=x64 -A win32
  [proc] Executing command: &quot;C:\Program Files\CMake\bin\cmake.EXE&quot; --no-warn-unused-cli -DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE &quot;-Hc:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0&quot; &quot;-Bc:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build&quot; -G &quot;Visual Studio 16 2019&quot; -T host=x64 -A win32
  [cmake] Not searching for unused variables given on the command line.
  [cmake] -- Selecting Windows SDK version 10.0.18362.0 to target Windows 10.0.18363.
  [cmake] -- SLIC3R_ASAN: OFF
  [cmake] -- SLIC3R_BUILD_SANDBOXES: OFF
  [cmake] -- SLIC3R_BUILD_TESTS: ON
  [cmake] -- SLIC3R_FHS: OFF
  [cmake] -- SLIC3R_GTK: 2
  [cmake] -- SLIC3R_GUI: ON
  [cmake] -- SLIC3R_MSVC_COMPILE_PARALLEL: ON
  [cmake] -- SLIC3R_MSVC_PDB: ON
  [cmake] -- SLIC3R_PCH: ON
  [cmake] -- SLIC3R_PERL_XS: OFF
  [cmake] Building without Win10 Netfabb STL fixing service support
  [cmake] -- SLIC3R_PROFILE: OFF
  [cmake] -- SLIC3R_STATIC: ON
  [cmake] -- SLIC3R_WX_STABLE: ON
  [cmake] -- SLIC3R_STATIC: ON
  [cmake] -- CMAKE_PREFIX_PATH: (default)
  [cmake] CMake Error at C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  [cmake]   Could NOT find Boost (missing: system filesystem thread log locale regex
  [cmake]   chrono atomic date_time) (found version &quot;1.75.0&quot;)
  [cmake] Call Stack (most recent call first):
  [cmake]   C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  [cmake]   C:/Program Files/CMake/share/cmake-3.20/Modules/FindBoost.cmake:2344 (find_package_handle_standard_args)
  [cmake]   CMakeLists.txt:266 (find_package)
  [cmake] 
  [cmake] 
  [cmake] -- Configuring incomplete, errors occurred!
  [cmake] See also &quot;C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/CMakeOutput.log&quot;.
  [cmake] See also &quot;C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/CMakeError.log&quot;.
  </code></pre>
  <p>Also, here is the two logs that the terminal talk about if that is of interest:</p>
  <p><em>CMakeOutput.log</em></p>
  <pre><code>    The system is: Windows - 10.0.18363 - AMD64
  Compiling the C compiler identification source file &quot;CMakeCCompilerId.c&quot; succeeded.
  Compiler:  
  Build flags: 
  Id flags:  
  
  The output was:
  0
  Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET Framework
  Copyright (C) Microsoft Corporation. All rights reserved.
  
  Build started 21-02-2021 22:55:20.
  Project &quot;C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdC\CompilerIdC.vcxproj&quot; on node 1 (default targets).
  PrepareForBuild:
    Creating directory &quot;Debug\&quot;.
    Creating directory &quot;Debug\CompilerIdC.tlog\&quot;.
  InitializeBuildStatus:
    Creating &quot;Debug\CompilerIdC.tlog\unsuccessfulbuild&quot; because &quot;AlwaysCreate&quot; was specified.
  ClCompile:
    C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX64\x86\CL.exe /c /nologo /W0 /WX- /diagnostics:column /Od /Oy- /D _MBCS /Gm- /EHsc /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo&quot;Debug\\&quot; /Fd&quot;Debug\vc142.pdb&quot; /Gd /TC /analyze- /FC /errorReport:queue CMakeCCompilerId.c
    CMakeCCompilerId.c
  Link:
    C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX64\x86\link.exe /ERRORREPORT:QUEUE /OUT:&quot;.\CompilerIdC.exe&quot; /INCREMENTAL:NO /NOLOGO kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /MANIFEST /MANIFESTUAC:&quot;level='asInvoker' uiAccess='false'&quot; /manifest:embed /PDB:&quot;.\CompilerIdC.pdb&quot; /SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE /NXCOMPAT /IMPLIB:&quot;.\CompilerIdC.lib&quot; /MACHINE:X86 /SAFESEH Debug\CMakeCCompilerId.obj
    CompilerIdC.vcxproj -&gt; C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdC\CompilerIdC.exe
  PostBuildEvent:
    for %%i in (cl.exe) do @echo CMAKE_C_COMPILER=%%~$PATH:i
    :VCEnd
    CMAKE_C_COMPILER=C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\Hostx64\x86\cl.exe
  FinalizeBuildStatus:
    Deleting file &quot;Debug\CompilerIdC.tlog\unsuccessfulbuild&quot;.
    Touching &quot;Debug\CompilerIdC.tlog\CompilerIdC.lastbuildstate&quot;.
  Done Building Project &quot;C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdC\CompilerIdC.vcxproj&quot; (default targets).
  
  Build succeeded.
      0 Warning(s)
      0 Error(s)
  
  Time Elapsed 00:00:01.39
  
  
  Compilation of the C compiler identification source &quot;CMakeCCompilerId.c&quot; produced &quot;CompilerIdC.exe&quot;
  
  Compilation of the C compiler identification source &quot;CMakeCCompilerId.c&quot; produced &quot;CompilerIdC.vcxproj&quot;
  
  The C compiler identification is MSVC, found in &quot;C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/3.20.0-rc1/CompilerIdC/CompilerIdC.exe&quot;
  
  Compiling the CXX compiler identification source file &quot;CMakeCXXCompilerId.cpp&quot; succeeded.
  Compiler:  
  Build flags: 
  Id flags:  
  
  The output was:
  0
  Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET Framework
  Copyright (C) Microsoft Corporation. All rights reserved.
  
  Build started 21-02-2021 22:55:21.
  Project &quot;C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdCXX\CompilerIdCXX.vcxproj&quot; on node 1 (default targets).
  PrepareForBuild:
    Creating directory &quot;Debug\&quot;.
    Creating directory &quot;Debug\CompilerIdCXX.tlog\&quot;.
  InitializeBuildStatus:
    Creating &quot;Debug\CompilerIdCXX.tlog\unsuccessfulbuild&quot; because &quot;AlwaysCreate&quot; was specified.
  ClCompile:
    C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX64\x86\CL.exe /c /nologo /W0 /WX- /diagnostics:column /Od /Oy- /D _MBCS /Gm- /EHsc /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo&quot;Debug\\&quot; /Fd&quot;Debug\vc142.pdb&quot; /Gd /TP /analyze- /FC /errorReport:queue CMakeCXXCompilerId.cpp
    CMakeCXXCompilerId.cpp
  Link:
    C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\HostX64\x86\link.exe /ERRORREPORT:QUEUE /OUT:&quot;.\CompilerIdCXX.exe&quot; /INCREMENTAL:NO /NOLOGO kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /MANIFEST /MANIFESTUAC:&quot;level='asInvoker' uiAccess='false'&quot; /manifest:embed /PDB:&quot;.\CompilerIdCXX.pdb&quot; /SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE /NXCOMPAT /IMPLIB:&quot;.\CompilerIdCXX.lib&quot; /MACHINE:X86 /SAFESEH Debug\CMakeCXXCompilerId.obj
    CompilerIdCXX.vcxproj -&gt; C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdCXX\CompilerIdCXX.exe
  PostBuildEvent:
    for %%i in (cl.exe) do @echo CMAKE_CXX_COMPILER=%%~$PATH:i
    :VCEnd
    CMAKE_CXX_COMPILER=C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.28.29333\bin\Hostx64\x86\cl.exe
  FinalizeBuildStatus:
    Deleting file &quot;Debug\CompilerIdCXX.tlog\unsuccessfulbuild&quot;.
    Touching &quot;Debug\CompilerIdCXX.tlog\CompilerIdCXX.lastbuildstate&quot;.
  Done Building Project &quot;C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\3.20.0-rc1\CompilerIdCXX\CompilerIdCXX.vcxproj&quot; (default targets).
  
  Build succeeded.
      0 Warning(s)
      0 Error(s)
  
  Time Elapsed 00:00:01.11
  
  
  Compilation of the CXX compiler identification source &quot;CMakeCXXCompilerId.cpp&quot; produced &quot;CompilerIdCXX.exe&quot;
  
  Compilation of the CXX compiler identification source &quot;CMakeCXXCompilerId.cpp&quot; produced &quot;CompilerIdCXX.vcxproj&quot;
  
  The CXX compiler identification is MSVC, found in &quot;C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/3.20.0-rc1/CompilerIdCXX/CompilerIdCXX.exe&quot;
  
  Detecting C compiler ABI info compiled with the following output:
  Change Dir: C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/CMakeTmp
  
  Run Build Command(s):C:/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/MSBuild/Current/Bin/MSBuild.exe cmTC_e9c90.vcxproj /p:Configuration=Debug /p:Platform=win32 /p:VisualStudioVersion=16.0 /v:m &amp;&amp; Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET Framework
  
  Copyright (C) Microsoft Corporation. All rights reserved.
  
  
  
    Microsoft (R) C/C++ Optimizing Compiler Version 19.28.29336 for x86
  
    Copyright (C) Microsoft Corporation.  All rights reserved.
  
    CMakeCCompilerABI.c
  
    cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /Oy- /D WIN32 /D _WINDOWS /D &quot;CMAKE_INTDIR=\&quot;Debug\&quot;&quot; /D _MBCS /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo&quot;cmTC_e9c90.dir\Debug\\&quot; /Fd&quot;cmTC_e9c90.dir\Debug\vc142.pdb&quot; /Gd /TC /analyze- /errorReport:queue &quot;C:\Program Files\CMake\share\cmake-3.20\Modules\CMakeCCompilerABI.c&quot;
  
    cmTC_e9c90.vcxproj -&gt; C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\CMakeTmp\Debug\cmTC_e9c90.exe
  
  
  
  
  Detecting CXX compiler ABI info compiled with the following output:
  Change Dir: C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/CMakeTmp
  
  Run Build Command(s):C:/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/MSBuild/Current/Bin/MSBuild.exe cmTC_65605.vcxproj /p:Configuration=Debug /p:Platform=win32 /p:VisualStudioVersion=16.0 /v:m &amp;&amp; Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET Framework
  
  Copyright (C) Microsoft Corporation. All rights reserved.
  
  
  
    Microsoft (R) C/C++ Optimizing Compiler Version 19.28.29336 for x86
  
    Copyright (C) Microsoft Corporation.  All rights reserved.
  
    CMakeCXXCompilerABI.cpp
  
    cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /Oy- /D WIN32 /D _WINDOWS /D &quot;CMAKE_INTDIR=\&quot;Debug\&quot;&quot; /D _MBCS /Gm- /EHsc /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /GR /Fo&quot;cmTC_65605.dir\Debug\\&quot; /Fd&quot;cmTC_65605.dir\Debug\vc142.pdb&quot; /Gd /TP /analyze- /errorReport:queue &quot;C:\Program Files\CMake\share\cmake-3.20\Modules\CMakeCXXCompilerABI.cpp&quot;
  
    cmTC_65605.vcxproj -&gt; C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\CMakeTmp\Debug\cmTC_65605.exe
  </code></pre>
  <p><em>CMakeError.log</em></p>
  <pre><code>Determining if the include file pthread.h exists failed with the following output:
  Change Dir: C:/Program Files/Prusa3D/PrusaSlicer-dribbling_2.2.0/build/CMakeFiles/CMakeTmp
  
  Run Build Command(s):C:/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/MSBuild/Current/Bin/MSBuild.exe cmTC_3680a.vcxproj /p:Configuration=Debug /p:Platform=win32 /p:VisualStudioVersion=16.0 /v:m &amp;&amp; Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET Framework
  
  Copyright (C) Microsoft Corporation. All rights reserved.
  
  
  
    Microsoft (R) C/C++ Optimizing Compiler Version 19.28.29336 for x86
  
    Copyright (C) Microsoft Corporation.  All rights reserved.
  
    CheckIncludeFile.c
  
    cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /Oy- /D WIN32 /D _WINDOWS /D &quot;CMAKE_INTDIR=\&quot;Debug\&quot;&quot; /D _MBCS /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo&quot;cmTC_3680a.dir\Debug\\&quot; /Fd&quot;cmTC_3680a.dir\Debug\vc142.pdb&quot; /Gd /TC /analyze- /errorReport:queue &quot;C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\CMakeTmp\CheckIncludeFile.c&quot;
  
  C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\CMakeTmp\CheckIncludeFile.c(1,10): fatal error C1083: Cannot open include file: 'pthread.h': No such file or directory [C:\Program Files\Prusa3D\PrusaSlicer-dribbling_2.2.0\build\CMakeFiles\CMakeTmp\cmTC_3680a.vcxproj]
  </code></pre>
  <p>I have looked around at some different threads to find a solution but without luck. Most of them revolve around setting the system environment variables for Boost, but it seems that Cmake gives a message that it ignores this variable. I have also found a thread that suggests adding a line in the CMakeLists.txt to set the boost path before loading the libraries (as far as I understand), but none of these things unfortunately helped.</p>
  <p>Hope some of you have a solution for this headscratcher...</p>