Compile got error "LNK1104 cannot open file
'libboost_filesystem-vc141-mt-
Root
Cause
Reference:
https://www.boost.org/doc/libs/1_79_0/more/getting_started/windows.html
The only Boost libraries that must be built separately are:
- Boost.Chrono
- Boost.Context
- Boost.Filesystem ß focus this one
- Boost.GraphParallel
- Boost.IOStreams
- Boost.Locale
- Boost.Log (see build
documentation)
- Boost.MPI
- Boost.ProgramOptions
- Boost.Python (see
the Boost.Python
build documentation before building and installing it)
- Boost.Regex
- Boost.Serialization
- Boost.Thread
- Boost.Timer
- Boost.Wave
Use the
example tut1.cpp to test the setting
Reference:
https://www.boost.org/doc/libs/1_79_0/libs/filesystem/doc/tutorial.html
How to
use boost Library in Visual Studio
Follow
instruction 5.2.1
https://www.boost.org/doc/libs/1_79_0/more/getting_started/windows.html
5.2.1 Install
Boost.Build
Boost.Build is a
text-based system for developing, testing, and installing software. First,
you'll need to build and install it. To do this:
- Go
to the directory tools\build\.
- Run bootstrap.bat
- Run b2 install --prefix=PREFIX where PREFIX is the
directory where you want Boost.Build to be installed
- Add PREFIX\bin to your PATH environment variable.
Remark
Pre-request: Use “Administrator Command Prompt”
Step 1 - Process procedure 1 & 2
\boost_1_79_0\b2.exe should be build
Step 2
Execute \boost_1_79_0\b2.exe
Then \boost_1_79_0\stage\lib should be full of
library and include this link in visual studio
Setting as below:




No comments:
Post a Comment