I have a small issue when it comes to writing a DLL in MSVC (the 2010 version in particular). My program consists of the main part and a DLL. The DLL contains a function that is
__declspec(dllexport) int test_function(void) {
return 42;
}
The file is compiled using a DLL project (not using pre-compiled headers, I have chosen a empty DLL project). Now, when I want to list the exported symbols using the dumpbin
tool, the test_function
is not listed under exports. Is there a specific setting that forces __declspec(dllexport)
to actually export symbols?
Any help is welcome. Thank you!