|
From: John B. <joh...@ho...> - 2005-10-30 13:02:07
|
> > 1) you can create an import library for the foo.exe using a foo.def > > file like this: [snip] > > Then link the DLL with libfoo.a. >Ok, I see. However, this doesn't work if the foo.exe itself depends on >the DLL. So, circular dependencies are impossible, correct? I don't know. > > 2) Look up the symbol at runtime. Read up on GetProcAddress() and > > GetModuleHandle(). > >And how would I link the DLL itself using this second approach? > Use your normal command line to generate the DLL. In the DLL, you will use the function pointer returned by GetProcAddress to call the functions that live in foo.exe. |