I currently use a 3rd party dll connected to Fortran without problems, and i have only the .dll and .lib files. The 3rd party developer states that it is possible to connect it to Fortran or C.
I'm trying to use eclipse+mingw32 C and connect to this dll.
I tried several solutions reported here on the forum, but I always find problems with "linker" or "undefined reference" to the 3rd party function. See the list: [1]: Compile to .dll with some undefined references with MinGW [2]: mingw32 g++ and stdcall @suffix [3]: undefined reference to ‘_imp__InitBizLib’
The MinGW C Linker error is "undefined reference to `__imp_FUNCTIONNAME'".
Error message:
g++ -L"C:\temp\externalLib.lib" -o "test.exe" ./src/aaSampleCodes.o ./src/main.o
./src/main.o: In function main': C:\Source\Debug/../src/main.cpp:59: undefined reference to
func1(double, double)'
collect2.exe: error: ld returned 1 exit status
mingw32-make: *** [makefile:47: test.exe] Error 1
Someone could help by describing the proper way (using eclipse+mingw32) to proceed with that connection?