trying to build a DLL on Windows 7 gcc using 3rd party libraries

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I used to do this using Borland C but no longer have that machine. I have been told that the free Microsoft compiler will work, but I am aUnix/Linux person and would prefer to use gcc on the Windows machine(s) for compilation. Compiling the user-defined-function source works fine (I have appropriate __cdecl defined for the functions just as needed in Borland's compiler without __export). However linking the DLL is not so good - the problem appears to be in using the firebird libraries. I have both the library and dll versions of both in my current working directory (for now - till I get it working, then I will try using the "-L" option ....). From what I can see in the error listed below, gcc does NOT like these .lib libraries (I also tried the .dll files, but they really were not liked by the compiler).

Below is the command as entered on the PC and the error that follows.
E:\ray\vetadmin\UDF>gcc -shared -o vetAdmin.dll udf.o -Wl,--out-implib=libvetAdmin.dll.a ^
 -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--whole-archive fbclient_ms.lib ib_util_ms.lib

fbclient_ms.lib: member fbclient_ms.lib(fbclient.dll) in archive is not an object
collect2: ld returned 1 exit status

I also know that before the final compile and build with Borland I had to use the "implib" command (NO idea why) and it is not part of the gcc version (I think).

Does anyone know how to link using someone elses .lib files (C++ based)??




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux