Skip to Content.
Sympa Menu

charm - Re: [charm] Can you help me with the link error with Charm++ in VS2005?

charm AT lists.cs.illinois.edu

Subject: Charm++ parallel programming system

List archive

Re: [charm] Can you help me with the link error with Charm++ in VS2005?


Chronological Thread 
  • From: Gengbin Zheng <zhenggb AT gmail.com>
  • To: 倪安宁 <nianning1981 AT 163.com>
  • Cc: charm AT cs.uiuc.edu
  • Subject: Re: [charm] Can you help me with the link error with Charm++ in VS2005?
  • Date: Wed, 24 Feb 2010 12:11:42 -0600
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/charm>
  • List-id: CHARM parallel programming system <charm.cs.uiuc.edu>


libmemory-default.o

Gengbin

2010/2/24 倪安宁 <nianning1981 AT 163.com>

Hi :

I have added the libraries (i.e. libldb-none.o libck.a libmemory-default.o libconv-cplus-y.a libconv-core.a libconv-util.a libthreads-default.o ws2_32.lib kernel32.lib user32.lib psapi.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib) to my charm++ project(called mytest) developed with VS2005. Then I builded the project, it can be compiled successfully, but when linking, the following errors occurred.

 

------ Build started: Project: mytest, Configuration: Debug Win32 ------

Linking...

LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library

libmemory-default.o : error LNK2019: unresolved external symbol _GetProcessMemoryInfo@12 referenced in function _MemusageWindows


this should be in psapi.lib. see:

http://msdn.microsoft.com/en-us/library/ms683219%28VS.85%29.aspx

libck.a(trace-common.o) : error LNK2019: unresolved external symbol "void __cdecl _createTraces(char * *)" (?_createTraces@@YAXPAPAD@Z) referenced in function "void __cdecl _traceInit(char * *)" (?_traceInit@@YAXPAPAD@Z)

libck.a(init.o) : error LNK2019: unresolved external symbol "void __cdecl _registerExternalModules(char * *)" (?_registerExternalModules@@YAXPAPAD@Z) referenced in function "void __cdecl _initCharm(int,char * *)" (?_initCharm@@YAXHPAPAD@Z)


this is a little complicated. Charm uses charmc, a compiler wrapper, to compile. It generate a small file called moduleinit.C that defines these functions:
If you don't use some special features (such extern module) in ci file, your moduleinit.C will be simple like:


void _registerExternalModules(char **argv) {
}
void _createTraces(char **argv) {
}

Gengbin
 




Archive powered by MHonArc 2.6.16.

Top of Page