You've compiled the code, but you still haven't linked it into DLL and lib files.
Make them with
g++ -shared -o dlltest.dll dlltest.o -Wl,--out-implib,libdlltest.a
This creates both the DLL and an import library. If all you want is the DLL, ignore the stuff that isn't in red. (That's a -W and lower-case L.) See this link for more .
Good luck.
Duoas
Postaholic
2,043 posts since Oct 2007
Reputation Points: 1,140
Solved Threads: 229
When you are using an IDE, the options are usually (as they are in your case) to create either a DLL or an EXE. You can't create both in the same project.
Start a DLL project to make your DLL. Make the DLL.
Then start an normal application project. #include the .h from the DLL project. Make and run the EXE.
A DLL is not designed to be executed like an EXE --the entry point (if any) is different and different operating constraints apply. I think you need to read up a little more on the difference between a DLL and an EXE.
Hope this helps.
Duoas
Postaholic
2,043 posts since Oct 2007
Reputation Points: 1,140
Solved Threads: 229