CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2009
    Posts
    166

    unexplained linking errors

    Hello all,

    I get the following linking errors when trying to compile my exe:

    1>MSVCRT.lib(MSVCR100.dll) : error LNK2005: _tolower already defined in libcmt.lib(tolower.obj)
    1>MSVCRT.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in libcmt.lib(typinfo.obj)
    1>MSVCRT.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info:perator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in libcmt.lib(typinfo.obj)
    1>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
    fatal error LNK1169: one or more multiply defined symbols found

    I realize that this happens sometimes when trying to link libraries in that use different methods of code generation. All my dependencies are linked with /MT

    Any idea why this can still happen?

    Also, when I build in Debug mode using all /MTd it compiles, so this problem only exists in Release mode.

    Thanks!
    Ellay K.

  2. #2
    Join Date
    Mar 2009
    Posts
    166

    Re: unexplained linking errors

    nevermind.. I missed a sneaky /MD

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured