Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / C++ Libraries / July 2004

Tip: Looking for answers? Try searching our database.

___mb_cur_max unresolved:  Yet MSVCRTD exports it!

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
deane - 13 Mar 2004 11:56 GMT
I have a DLL which I am trying to link in debug mode.  To that end I've specified the multithreaded debug DLL version of the runtime lib which, if I've read the docs correctly, should leave me linking to MSVCRTD.LI

My DLL is also linking to a static lib which was built using LIBCMT.LIB.  When I try to link I get the following error

 LIBCMT.lib(crt0.obj) : error LNK2019: unresolved external symbol _main referenced in function _mainCRTStartu

To get around that, I specified that the linker should ignore libcmt.  Now I get the following errors when I link

 librib.lib(illum.o) : error LNK2001: unresolved external symbol ___mb_cur_ma

But if I run 'dumpbin /exports' on the MSVCRTD.LIB file in VC++.NET's Vc7\lib folder, it shows an export for ___mb_cur_max.  So why isn't the linker finding it

Note that the problem goes away if I build my DLL using the non-debug multithreaded DLL version of the runtime library
Ronald Laeremans [MSFT] - 15 Mar 2004 19:22 GMT
Hi Deane,

In general you need to use the same version of the runtime for every
component you link into an image.

Ronald Laeremans
Visual C++ team

> I have a DLL which I am trying to link in debug mode.  To that end I've specified the multithreaded debug DLL version of the runtime lib which, if
I've read the docs correctly, should leave me linking to MSVCRTD.LIB

> My DLL is also linking to a static lib which was built using LIBCMT.LIB.  When I try to link I get the following error:
>
[quoted text clipped - 5 lines]
>
> But if I run 'dumpbin /exports' on the MSVCRTD.LIB file in VC++.NET's Vc7\lib folder, it shows an export for ___mb_cur_max.  So why isn't the
linker finding it?

> Note that the problem goes away if I build my DLL using the non-debug multithreaded DLL version of the runtime library.
DotNetJunkies User - 26 Jul 2004 19:08 GMT
Hi,

I am getting the same error, but with an ATL-based COM project. As far as I know it doesn't have a main(). So what is going on? Any help would be appreciated.

Royce

---

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.