Purpose: Convet the project " ImageStone "(with source code) to a DLL
Platform: Visual Studio 2005 on Windows Vista
What I've done:
1. Create a empty DLL project and add all the source codes of ImageStone in the Header Files of the project(because ImageStone project has only header files)
2. Add "__declspec(dll export)" in all the functions of .h file in the Header Files of project
3. Add a ImageStone.cpp file to the Source Files
#include "ImageStone .h"
int main()
{
return 0;
}
4. Build the project and got the ImageStone.dll
5. Create another new project to this solution
6. Copy the "example01" which also provided by ImageStone project to the Source Files of the project that step 5 created
7. Setup the Reference, Additional Include Directories, and Environment of the project of step 5 created
8. Build the solution and got the expample01.exe
Question: I want to prove the correctness of the DLL that just maked. I remove the DLL and run the example01.exe, and example01.exe still work!!! It means I failed. The ImageStone is still build with example01.exe as a static library.
How can I do to achieve my purpose? Thanks for your answers!
Platform: Visual Studio 2005 on Windows Vista
What I've done:
1. Create a empty DLL project and add all the source codes of ImageStone in the Header Files of the project(because ImageStone project has only header files)
2. Add "__declspec(dll export)" in all the functions of .h file in the Header Files of project
3. Add a ImageStone.cpp file to the Source Files
#include "ImageStone .h"
int main()
{
return 0;
}
4. Build the project and got the ImageStone.dll
5. Create another new project to this solution
6. Copy the "example01" which also provided by ImageStone project to the Source Files of the project that step 5 created
7. Setup the Reference, Additional Include Directories, and Environment of the project of step 5 created
8. Build the solution and got the expample01.exe
Question: I want to prove the correctness of the DLL that just maked. I remove the DLL and run the example01.exe, and example01.exe still work!!! It means I failed. The ImageStone is still build with example01.exe as a static library.
How can I do to achieve my purpose? Thanks for your answers!
Comment