Hi all,

I’m currently trying to port my partially done application from Linux to Windows, it’s gone fairly smoothly, but now I have hit a barrier. I have an application which depends on a main application DLL, and then numerous plugin DLLs which also depend on it. I also require some Boost libraries and GLEW.

So I downloaded the last Qt 4 libraries and the latest MinGW, and built Boost and GLEW successfully. I then built my main application dll without a problem – except that it is 100MB bigger than the Linux debug version (more than double)!

I then tried to build the first of my plugins, but suffered undefined reference errors for functions that reside in my main application DLL. Looking at the verbose linker output I can see that it is finding and successfully opening the DLL. Doing an objdump on the application DLL, I can see the ‘missing’ functions.

However if I objdump the import library, it seems very empty. I expected to see every function/method listed, instead there’s just 3 blocks very similar to this:

Qt Code:
  1. d000762.o: file format pe-i386
  2.  
  3. SYMBOL TABLE:
  4. [ 0](sec 1)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 .text
  5. [ 1](sec 2)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 .idata$7
  6. [ 2](sec 3)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 .idata$5
  7. [ 3](sec 4)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 .idata$4
  8. [ 4](sec 5)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 .idata$6
  9. [ 5](sec -1)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000001 @feat.00
  10. [ 6](sec 1)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 _qt_plugin_query_verification_data
  11. [ 7](sec 3)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 __imp__qt_plugin_query_verification_data
  12. [ 8](sec 0)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 __head_Syren_dll
To copy to clipboard, switch view to plain text mode 

But I also read that libraries built using MinGW do not need an import library to link libraries also being built with MinGW, so I doubt that this is relevant.

So just to recap, if I’m building a DLL and linking it to 3rd party DLLs (and Qt) – I have no problem; but linking a plugin DLL to my main application plugin fails because it can’t see the symbols. I’ve never built on Windows using MinGW, so I presume I’m missing a step somewhere?