[LLVMdev] Problems linking shared library with __declspec(dllexport)

Ronald Pijnacker pijnacker at dse.nl
Sun Oct 11 13:34:35 PDT 2009


Hi all,

I am trying to use llvm-gcc to link shared libraries on windows/mingw32.
When I try to link libraries that contain functions declared with
  __declspec(dllexport) someFunction();

I get the link error:

  Cannot export _someFunction: symbol not found

Removing the declspec directive solves the problem, but this is not a 
very feasible solution for me.
Using 'regular' gcc does not have this problem.

Should I consider this a bug?

Thanks,

Ronald



More information about the llvm-dev mailing list