From: <520...@t-...> - 2002-03-04 12:02:31
|
Hi folks, thanks to your wonderful work, I can now build our CORBA ORB Mico (http://www.mico.org/) pretty much out of the box into a DLL, using nothing more than c++ -shared. I have a couple of related questions, though. During the build and test process, I was repeatedly bitten by the fact that you cannot directly use global variables that come from a DLL. If you have "extern int foo;", the program compiles but gives wrong results. Instead, I had to replace "extern" by "__declspec(dllimport)" to make variables work. This was in some cases hard to track down, and I am worried that some instances of such code are still lurking somewhere. So the question is whether there's some smart way to find such problems. The linker should be able to notice this, shouldn't it? The second question has to do with the fact that Mico throws exceptions across the boundaries of its DLL. I therefore applied Thomas Pfaff's patches from his Jan 21 message. I have to use "c++ -mthreads" despite the program is non-threaded, but anyway, it works fine. Are there any plans to integrate these patches into MinGW? I just wrote build instructions for Mico, and they're getting rather lengthy and complicated because of this "undocumented" (read: nowhere mentioned in the MinGW docs but just in a hard-to-find mailing list message). There's now two DLLs that I need, our mico.dll and gcc-mt-2.95.3.dll. I suppose there's no way around the requirement for that gcc-mt lib? Thanks, Frank -- Frank Pilhofer ........................................... fp...@fp... Most of us don't know exactly what we want, but we're pretty sure we don't have it. - Alfred E. Neuman |