Eclipse C++ dll import

2020-06-21 07:03发布

问题:

How does one import a dll into an Eclipse C++ project?

回答1:

You don't import the library files themselves since they are binary code and of little use. Usually you get a binary lib/dll with a bunch of header files. You include the header files in your program source, use the functions from the lib in your progam. Finally, in the project build settings you specify in the linker step that you also want to link with the binary lib/dll. The product will be an executable that uses the binary libs..

This is not unique to eclipse by the way :)



回答2:

http://www.jinvoke.com/book/export/html/37 - For using the dlls in Java under Eclipse