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 / Managed C++ / October 2005

Tip: Looking for answers? Try searching our database.

LNK2019 error

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
hazizpour@gmail.com - 04 Oct 2005 21:09 GMT
Hello

I hope I am in the correct newsgroup, if not please let me know.

I am trying to build a sample for using a certain library ( IFC mapping
to C++ classes, see www.cstb.fr) with MS Visual Studio 2003.
When building a sample program, I get the error mentioned in the title:
LNK2019
Here is a snippet of the error message:

---
main.obj : error LNK2019: unresolved external symbol
"__declspec(dllimport) public: bool __thiscall
IFC20_LONGFORM::SPFwriter::writeSPF(class IFC20_LONGFORM::Model *,class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)"
(__imp_?writeSPF@SPFwriter@IFC20_LONGFORM@@QAE_NPAVModel@2@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
referenced in function _main

main.obj : error LNK2019: unresolved external symbol
"__declspec(dllimport) public: class IFC20_LONGFORM::Model * __thiscall
IFC20_LONGFORM::SPFreader::readSPF(class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> > const &)"
(__imp_?readSPF@SPFreader@IFC20_LONGFORM@@QAEPAVModel@2@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
referenced in function _main

Debug/CSTBTest2_Console.exe : fatal error LNK1120: 2 unresolved
externals
---

What I have found so far on the net wasn't very helpful. I have read
somewhere, that the reason of the error could have something to do with
different versions of VC (since the libraries were programmed in 2000,
they were probably built with VC5 or 6, I dont know if that is a
problem)

Does anyone know what I can do about this error?

thanks alot in advance!
Ron - 05 Oct 2005 18:09 GMT
Since you stated that the libraries were created in 2000, I would say
that the problem is incompatability with VS2003. The only way that I
know of to get around this is to recompile the libraries or purchase
.Net versions.

Ron
H_A_ - 05 Oct 2005 18:18 GMT
Thanks a lot. I ve received kind of the same reply from someone else,
too, so chances are that the incompatibility is indeed the problem.
The solution you suggest makes of course sense, since it doesnt seem
that they have newer versions of the library, I have emailed the
programmers to ask for the sources, so I can recompile (it is strange
that the sources dont seem to be available at the site even though the
libraries are supposed to be "open source")

thanks again, if you can come up with other solutions, i d be happy to
know.

Haroon

Rate this thread:







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.