Boost logo

Boost Users :

From: David Kowis (dkowis_at_[hidden])
Date: 2003-10-19 16:35:09


Quoting John Maddock <john_at_[hidden]>:

> You don't say what the errors are, but that usually happens if you build the
> lib against one runtime library (bjam builds against the dll runtime by
> default), and try and link your program against a different runtime.
>
> John.

Sorry about that, this time I've pasted the errors into this message. This is
telling it to use boost_filesystem.lib in the runtime directory that bjam
creates. I rebuilt the entire thing.
Is there another file I'm supposed to link to? I don't remember there ever being
a .dll file being built. If there is, I haven't found it yet. I'm pretty sure I
followed the bjam instructions really well. Also I'm just trying to use
boost::filesystem. That doesn't appear to make a dll.
I've set up my MSVC project to use D:\mp3dber\boost-1.30.2 as an include
directory. That's where I extracted the source and built it using bjam.

Thanks,
David

My compile errors:
Compiling...
path_test.cpp
Linking...
LINK : warning LNK4075: ignoring /INCREMENTAL due to /DEBUGTYPE specification
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: void __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Copy(unsigned int)"
(?_Copy@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAEXI_at_Z)
 already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: void __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Tidy(bool)"
(?_Tidy@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAEX_N_at_Z)
alread
y defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: unsigned int __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::max_size(void)const "
(?max_size@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@st
d@@QBEIXZ) already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "void __cdecl std::_Xlen(void)"
(?_Xlen_at_std@@YAXXZ) already defined in libcpd.lib(string.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: void __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Eos(unsigned int)"
(?_Eos@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAEXI_at_Z) a
lready defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: bool __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Grow(unsigned int,bool)"
(?_Grow@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAE
_NI_N_at_Z) already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "bool __cdecl std::operator!=(class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> const &,char const *)"
(??9std@@YA_NABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator
@D_at_2@@0_at_PBD@Z) already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::~basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>(void)" (??1?$basic_string@
DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAE_at_XZ) already defined in
path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: virtual __thiscall
std::runtime_error::~runtime_error(void)" (??1runtime_error_at_std@@UAE_at_XZ) already
defined in libcpd.lib(ios.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>(class std::basic_string<cha
r,struct std::char_traits<char>,class std::allocator<char> > const &)"
(??0?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAE_at_ABV01@@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: __thiscall
std::runtime_error::runtime_error(class std::runtime_error const &)"
(??0runtime_error_at_std@@QAE_at_ABV01@@Z) already defined in libcpd.lib(ios.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::append(class s
td::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >
const &,unsigned int,unsigned int)"
(?append@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_ABV12@II_at_Z)
already defined in libcpd.lib(locale.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::erase(unsigned
 int,unsigned int)"
(?erase@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_II@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: void __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Freeze(void)"
(?_Freeze@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAEXXZ) alre
ady defined in libcpd.lib(iostream.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::append(unsigne
d int,char)"
(?append@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_ID@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::append(char co
nst *,unsigned int)"
(?append@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_PBDI@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "private: void __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::_Split(void)"
(?_Split@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@AAEXXZ) alread
y defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "void __cdecl std::_Xran(void)"
(?_Xran_at_std@@YAXXZ) already defined in libcpd.lib(string.obj)
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::assign(class s
td::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >
const &,unsigned int,unsigned int)"
(?assign@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_ABV12@II_at_Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>(class std::allocator<char>
const &)"
(??0?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAE_at_ABV?$allocator_at_D@1@@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> & __thiscall std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >::assign(char co
nst *,unsigned int)"
(?assign@?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAEAAV12_at_PBDI@Z)
already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "bool __cdecl std::operator==(class
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
> const &,char const *)"
(??8std@@YA_NABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator
@D_at_2@@0_at_PBD@Z) already defined in path_test.obj
msvcprt.lib(MSVCP60.dll) : error LNK2005: "public: __thiscall
std::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>::basic_string<char,struct std::char_traits<char>,class std::allocator<char>
>(char const *,class std::all
ocator<char> const &)"
(??0?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@QAE_at_PBDABV?$allocator_at_D@1@@Z)
already defined in path_test.obj
MSVCRT.lib(MSVCRT.dll) : error LNK2005: _memchr already defined in
LIBCD.lib(memchr.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: _memmove already defined in
LIBCD.lib(memmove.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: "public: virtual __thiscall
exception::~exception(void)" (??1exception@@UAE_at_XZ) already defined in
LIBCD.lib(stdexcpt.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: "public: __thiscall
exception::exception(class exception const &)" (??0exception@@QAE_at_ABV0@@Z)
already defined in LIBCD.lib(stdexcpt.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: "public: int __thiscall
type_info::operator==(class type_info const &)const "
(??8type_info@@QBEHABV0@@Z) already defined in LIBCD.lib(typinfo.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: "public: __thiscall
exception::exception(char const * const &)" (??0exception@@QAE_at_ABQBD@Z) already
defined in LIBCD.lib(stdexcpt.obj)
LINK : warning LNK4098: defaultlib "MSVCRT" conflicts with use of other libs;
use /NODEFAULTLIB:library
Debug/path_test.exe : fatal error LNK1169: one or more multiply defined symbols
found
Error executing link.exe.

path_test.exe - 30 error(s), 2 warning(s)

            _ ._ _ , _ ._
          (_ ' ( ` )_ .__)
        ( ( ( ) `) ) _)
       (__ (_ (_ . _) _) ,__)
           `~~`\ ' . /`~~`
           ,::: ; ; :::,
          ':::::::::::::::'
  _____________/_ __ \____________
             David Kowis
         Computer Programmer

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net