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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,fe1dc0666af8f6a6 X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: "Alex R. Mosteo" Newsgroups: comp.lang.ada Subject: Re: Creating mixed language static libraries with gpr files? Followup-To: comp.lang.ada Date: Tue, 03 Mar 2009 16:06:05 +0100 Message-ID: <714vb1Fj2e75U1@mid.individual.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit X-Trace: individual.net 1XT5oTnUzzlpkG6t3M7TRQPYy/FpTeEKs0O0YkHBb7e8CZpZA= Cancel-Lock: sha1:tqJ8o8dUIEm9TvCQdqFiVCf25YQ= User-Agent: KNode/0.99.01 Xref: g2news1.google.com comp.lang.ada:3897 Date: 2009-03-03T16:06:05+01:00 List-Id: Markus Schoepflin wrote: > Ludovic Brenta wrote: > >> Markus Schoepflin wrote on comp.lang.ada: > >>> Using gcc 4.3.3, I'm trying to create a static library that contains >>> both object files created from Ada and C. > > [...] > >> Off the top of my head, this requires that you use gprmake instead of >> gnatmake. gprmake is part of GPS; if you have GPS on your system, then >> maybe you have gprmake too. If you don't have it, you can still use a >> Makefile to complement your project file. You can easily add an object >> file to an existing static library with "ar rt libLIBRARY.a >> object_file_produced_from_c.o". > > Thank you for your answer. > > gprmake seems pretty undocumented, but I found the documentation for > something called gprbuild which looks like it would be up to the job. > > As I don't use GPS, I will probably take the Makefile route. I suspect that gprbuild is supposed to obsolete gprmake. Sometime ago I tried to find some info on this but couldn't arrive at anything definite. For sure gprmake existed prior to gprbuild, and some bugs in gprmake are no longer in gprbuild. I'm building somewhat complex executables with a mix of Ada/C/C++ with gprbuild with zero problems, so I expect you'll be lucky too.