适用于codeblcoks
http://blog.csdn.net/huys03/article/details/3912475
经过试验,创建动态库, 如果所有函数都没有加__declspec(dllexport)和__stdcall,则所有的函数都以原名导出,如果加了__declspec(dllexport)和__stdcall,则只有加了__declspec(dllexport)的会导出,同时加了__stdcall会出现符号@n,在链接选项中加入下面选项解决。
参考:
So for anyone else looking to build a dll using the __stdcall (WINAPI) calling convention, without the name decoration MinGW (GCC) adds, then put this in CodeBlocks' "Other Linker Options":-Wl,--kill-at
http://blog.csdn.net/huys03/article/details/3912475