Ok, I've managed to compile one of my C modules on windows (the XML2 parser glue), but I'm running into problems with dynamic module loading in pike.
The libxml2 module uses some functions like modf and log10. Because libxml2 is being compiled as a library, the c library doesn't appear to be linked. Similarly, when I make the module, these symbols (and the snprintf pointer in the following error message) don't seem to be getting linked in. Thus, when I try to load the compiled module into Pike, I end up with undefined symbols.
The question is, how do I work around it? I can get the regular functions like log10 and fmod to be linked into Pike by creating dummy functions that use them, but then that will only work with my copy of pike and not anyone elses. Similarly, I'm not sure what to do with the __imp records. Is dlopen not aware of how to resolve these?
Any thoughts and suggestions would be greatly appreciated!
Bill
DL: Symbol '__imp___snprintf' not found. DL: Symbol '__imp___snprintf' not found. DL: Symbol '__imp___snprintf' not found. DL: Symbol '__imp___snprintf' not found. DL: Symbol '__imp___snprintf' not found. DL: Symbol '__imp___snprintf' not found. DL_Symbol '_modf' not found. DL: Symbol '_log10' not found. DL: Symbol '__imp___snprintf' not found.
The "__imp__" prefix is normally added when you specify (at compile time) that you want to link with the dll version of a lib. Are you using MSVC and/or linking with the MS CRT?
pike-devel@lists.lysator.liu.se