I want to compile a program where I need to build boost library with static linkage, since in Visual Studio 2017 Community I get the following linker error:
LINK : fatal error LNK1104: File "libboost_filesystem-vc140-mt-gd-1_63.lib" could not be opened.
I compiled that already long ago with a different VS version, where it worked.
So, I tried to compile boost 1.63 as discribed on their page. In the VS command prompt, I adopted the arguments from this answer (but just b2 without arguments doesn't work either):
bootstrap
b2 -j8 toolset=msvc-14.1 address-model=32 architecture=x86 link=static threading=multi runtime-link=shared --build-type=complete stage
After the call to b2 I get the following error message in the command window:
C:/Program Files/boost_1_63_0/tools/build/src/tools\msvc.jam:834: in generate-se
tup-cmd
*** argument error
* rule maybe-rewrite-setup ( toolset : setup-script : setup-options : version :
rewrite-setup ? )
* called with: ( msvc : : : default : )
* missing argument setup-script
C:/Program Files/boost_1_63_0/tools/build/src/tools\msvc.jam:746:see definition
of rule 'maybe-rewrite-setup' being called
C:/Program Files/boost_1_63_0/tools/build/src/tools\msvc.jam:1076: in configure-
really
C:/Program Files/boost_1_63_0/tools/build/src/tools\msvc.jam:201: in configure
C:/Program Files/boost_1_63_0/tools/build/src/tools\msvc.jam:153: in msvc.init
C:/Program Files/boost_1_63_0/tools/build/src/build\toolset.jam:43: in toolset.u
sing
C:/Program Files/boost_1_63_0/tools/build/src/build\project.jam:1052: in using
project-config.jam:3: in modules.load
C:/Program Files/boost_1_63_0/tools/build/src\build-system.jam:249: in load-conf
ig
C:/Program Files/boost_1_63_0/tools/build/src\build-system.jam:412: in load-conf
iguration-files
C:/Program Files/boost_1_63_0/tools/build/src\build-system.jam:524: in load
C:\Program Files\boost_1_63_0\tools\build\src/kernel\modules.jam:295: in import
C:\Program Files\boost_1_63_0\tools\build\src/kernel/bootstrap.jam:139: in boost
-build
C:\Program Files\boost_1_63_0\boost-build.jam:17: in module scope
Question: What is the problem here? How can I build the required libs?