boost autolinkig issue - library names on vc9?
Hi, I'm having an issue with boost autolinking on Visual Studio 9 (2008), with the boost-pything library. the boost build process generates libraries of the name: libboost_XXX-vc90-mt-gd-1_39.lib and the like, but interestingly autolinkig fails with the following message: 1>LINK : fatal error LNK1104: cannot open file 'boost_python-vc90-mt-gd-1_39.lib' am I doing something wrong? Akos
Maróy Ákos wrote:
Hi,
I'm having an issue with boost autolinking on Visual Studio 9 (2008),
Did you check the getting started guide or google for solution? This is a common problem and I would like to understand why it's coming up repeatedly and what we can improve.
with the boost-pything library. the boost build process generates libraries of the name: libboost_XXX-vc90-mt-gd-1_39.lib
This is static debug version.
and the like, but interestingly autolinkig fails with the following message:
1>LINK : fatal error LNK1104: cannot open file 'boost_python-vc90-mt-gd-1_39.lib'
This is (import library for) shared debug version, which is not built by default. You can either use static Boost libraries, by making sure BOOST_ALL_DYN_LINK, or similar, macros are not defined, or build shared versions of Boost libraries, using additional link=shared option to Boost.Build. Let me know if this helps. - Volodya
Dear Volodya,
Did you check the getting started guide or google for solution? This is a common problem and I would like to understand why it's coming up repeatedly and what we can improve.
yes, I have. I have already built boost on a number of platforms (Linux 32 and 64 bit, Mac OS X, and Windows using mingw and visual studio). I even build boost using a cross-compiler (on a Linux host for mingw) I wouldn't consider myself an expert on the subject, but I read through a number of documentation resources.
with the boost-pything library. the boost build process generates libraries of the name: libboost_XXX-vc90-mt-gd-1_39.lib
This is static debug version.
yes, this what I need at the moment
and the like, but interestingly autolinkig fails with the following message:
1>LINK : fatal error LNK1104: cannot open file 'boost_python-vc90-mt-gd-1_39.lib'
This is (import library for) shared debug version, which is not built by default. You can either use static Boost libraries, by making sure BOOST_ALL_DYN_LINK, or similar, macros are not defined, or build shared versions of Boost libraries, using additional link=shared option to Boost.Build.
Let me know if this helps.
can you be more specific in terms of "BOOST_ALL_DYN_LINK, or similar, macros are not defined"? should I add sone #undef statement in my source code? should add some parameter to the compiler to define some macro? Aks
AMDG Maróy Ákos wrote:
and the like, but interestingly autolinkig fails with the following message:
1>LINK : fatal error LNK1104: cannot open file 'boost_python-vc90-mt-gd-1_39.lib'
This is (import library for) shared debug version, which is not built by default. You can either use static Boost libraries, by making sure BOOST_ALL_DYN_LINK, or similar, macros are not defined, or build shared versions of Boost libraries, using additional link=shared option to Boost.Build.
Let me know if this helps.
can you be more specific in terms of "BOOST_ALL_DYN_LINK, or similar, macros are not defined"? should I add sone #undef statement in my source code? should add some parameter to the compiler to define some macro?
Boost.Python's use of autolinking is different from all other libraries. You need to define BOOST_PYTHON_STATIC_LIB to use the static library. In Christ, Steven Watanabe
Maróy Ákos wrote: Hi Maróy,
Did you check the getting started guide or google for solution? This is a common problem and I would like to understand why it's coming up repeatedly and what we can improve.
yes, I have. I have already built boost on a number of platforms (Linux 32 and 64 bit, Mac OS X, and Windows using mingw and visual studio). I even build boost using a cross-compiler (on a Linux host for mingw) I wouldn't consider myself an expert on the subject, but I read through a number of documentation resources.
Ok, then there's some unknown glitch for us to track down.
with the boost-pything library. the boost build process generates libraries of the name: libboost_XXX-vc90-mt-gd-1_39.lib
This is static debug version.
yes, this what I need at the moment
and the like, but interestingly autolinkig fails with the following message:
1>LINK : fatal error LNK1104: cannot open file 'boost_python-vc90-mt-gd-1_39.lib'
This is (import library for) shared debug version, which is not built by default. You can either use static Boost libraries, by making sure BOOST_ALL_DYN_LINK, or similar, macros are not defined, or build shared versions of Boost libraries, using additional link=shared option to Boost.Build.
Let me know if this helps.
can you be more specific in terms of "BOOST_ALL_DYN_LINK, or similar, macros are not defined"? should I add sone #undef statement in my source code? should add some parameter to the compiler to define some macro?
What I actually meant is to make sure BOOST_ALL_DYN_LINK or BOOST_PYTHON_DYN_LINK is *not* set in your project settings. But I've just now looked at the source code, and it seems that Python requires that you set BOOST_PYTHON_STATIC_LIB macro to 1 in the settings of your project -- which differs from every other Boost library. Can you let me now if that helps? Thanks, Volodya
participants (3)
-
Maróy Ákos
-
Steven Watanabe
-
Vladimir Prus