From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,22727740a6694ce8 X-Google-Attributes: gid11318c,public X-Google-Thread: f65d0,22727740a6694ce8 X-Google-Attributes: gidf65d0,public X-Google-Thread: 103376,22727740a6694ce8 X-Google-Attributes: gid103376,public From: jerry@jvdsys.nextjk.stuyts.nl (Jerry van Dijk) Subject: Re: Linking GCC/Gnat and Microsoft Visual C++ libs Date: 1998/05/25 Message-ID: #1/1 X-Deja-AN: 356409527 References: <6k9npe$qah$1@plug.news.pipex.net> Followup-To: comp.lang.ada,gnu.gcc,gnu.gcc.help Organization: * JerryWare *, Leiden, Holland Newsgroups: comp.lang.ada,gnu.gcc,gnu.gcc.help Date: 1998-05-25T00:00:00+00:00 List-Id: Paul Hussein (paul.hussein@dial.pipex.com) wrote: : Can anyone help. I am trying to link some Microsoft VC++ 5.0 libs with : Gnat/GCC. At run-time I get an error and am wondering if this link is : legal. : If not, how do I do link MS VC++ libs and Gnat/GCC. As usual, it depends. Basically gcc uses the .a library format, not the .lib format. So if you are using the gcc linker (ld) that won't work. You might have success with a GNAT version previous to 3.10, since it is rumored that these ports could use the microsoft linker. But that would in all likelyhood involve some tricks. If this .lib is an import library, it is possible that GNAT already includes the .a format import libraries you need. Otherwise follow the instructions on my homepage: http://stad.dsl.nl/~jvandyk to build a GNAT compatible import library for the DLL. If this is a normal code library, and you have the sources, see if you can compile the code into a DLL, and build a GNAT import library for this DLL. If this is a code library for which you have no sources, there is AFAIK no way to use it directly. An option might then be to write some wrapper code and compile this into a DLL, linking the .lib within the DLL. Success, Jerry. -- -- Jerry van Dijk | email: jdijk@acm.org -- Leiden, Holland | member Team-Ada