On Windows, how does Boost decide which MSVS version to use, if I have more than one installed?
When I tried to build some app, I ended up with this error message: 1>LINK : fatal error LNK1104: cannot open file 'libboost_filesystem-vc80-mt-1_51.lib' I am sure it is due to the fact that I have a couple of Boost installations and 2 Versions of MSVS as well (2005 and 2010). NB: This is the way I build Boost on Windows: .\bootstrap.bat .\bjam.exe --with-date_time --with-filesystem --with-regex --with-system --stagedir=. --build-type=complete toolset=msvc The question is about that last parameter above. Does the install procedure: (a) Go to "Program Files" and takes a look at the name of the highest numbered MSVS folder? or (b) Is this info extracted from the Registry or something? TIA, -Ramon
On Mon, Nov 05, 2012 at 02:48:01PM -0600, Ramon F Herrera wrote:
When I tried to build some app, I ended up with this error message:
1>LINK : fatal error LNK1104: cannot open file 'libboost_filesystem-vc80-mt-1_51.lib'
I am sure it is due to the fact that I have a couple of Boost installations and 2 Versions of MSVS as well (2005 and 2010).
NB: This is the way I build Boost on Windows:
.\bootstrap.bat
.\bjam.exe --with-date_time --with-filesystem --with-regex --with-system --stagedir=. --build-type=complete toolset=msvc
The question is about that last parameter above.
Does the install procedure:
(a) Go to "Program Files" and takes a look at the name of the highest numbered MSVS folder?
or
(b) Is this info extracted from the Registry or something?
Mostly alternative B, I believe. It enumerates the msvc versions it knows about and picks the fanciest, independent of the environment in your current prompt. You can specify an explicit version like msvc-10.0 if you want a particular VC++. The boostrap script does something similiar, but as the compiler used for b2 doesn't really matter much, the default choice it picks tends to work just fine. In your case, if you want to build for 2005, you want toolset=msvc-8.0 -- Lars Viklund | zao@acc.umu.se
participants (2)
-
Lars Viklund
-
Ramon F Herrera