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: a07f3367d7,46ebb7f176dc318f X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,UTF8 Path: g2news1.google.com!news2.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!feedme.ziplink.net!news.swapon.de!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: "Alex R. Mosteo" Newsgroups: comp.lang.ada Subject: Re: CMake and Ada : a track around the place ? Followup-To: comp.lang.ada Date: Mon, 01 Aug 2011 11:23:33 +0200 Organization: A noiseless patient Spider Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8Bit Injection-Date: Mon, 1 Aug 2011 09:23:37 +0000 (UTC) Injection-Info: mx04.eternal-september.org; posting-host="M7rP6jhm1IVgvmYaXQFuIA"; logging-data="32458"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+yrCQkHIeH96xKFsuNEW2z" User-Agent: KNode/4.4.10 Cancel-Lock: sha1:hXLx27ykSxtvGzeLDn0Vj5Xaglg= Xref: g2news1.google.com comp.lang.ada:20436 Date: 2011-08-01T11:23:33+02:00 List-Id: Yannick DuchĂȘne (Hibou57) wrote: > Hi all (a long time I didn't posted here, hope every one is fine and fine) > > I may have two opportunities to push Ada in two different projects. The > first one is OK, as I will start it from the ground up. The second one is > rather different, in the way it is an already existing project I would > like to work on (may not be a priority, as I would probably get nothing > for this, as it is a GPL application). This is a C++ rather big (for me) > peace of software, which however provide an opportunity to push Ada > inside, as it is a very modular application (I may dream, in the future, > to incrementally translate some part from C++ to Ada, as I hate when this > application crash with no back-track and runtime-check at all). Alex R. > Masteo already talked about CMake and Ada here, as I did too some time > before Alex. Ludovic replied to Alex using CMake is a bad idea. I > understood the reason he gave, but I simply would like it anyway, for > seamless integration, as this application has a build process all designed > around CMake since long, and I would not want to change. > > The sole material I could found about this topic, is an old mailing list > archive. I just made a test with a sample Ada project to see what's going > on using Make as-is, and CMake complained he could not determine some > linker language for the target application. So Ada is clearly not built-in > the default CMake. > > Any track for using CMake to build a source tree containing Ada sources > mixed with C++ files ? I would probably rely on solely GNAT for the Ada > compiler, as it comes along GCC (this may help). Hi Yannick, I wish you some success here since I'm really interested in this too. In the end, I finally went pure C++ after my earlier posts on this topic, for a variety of minor reasons that together made this the better choice. That said, I never got around to make any Ada tests, but after all the discussion here and the threads (that can be easily found) on the Ada PlPlot binding (which also uses CMake), my final conclusion was that, whenever I get the opportunity, I'll start by testing the apparently simplest option of bypassing CMake from inside CMake: that is, launching gprbuild (add_custom_command, add_custom_target? execute_process?) to build a self- contained Ada library that is finally linked to the main C++ executable (with link_libraries and target_link_libraries). This is ugly in that it simply does not integrate Ada into CMake (as the guys from PlPlot seem to have done); I'm not even sure if this will work and, if it does, which complications may arise. On the other hand, CMake (partially) sets to solve a problem that Ada does not have, so I feel it is OK to rely on the Ada compilation process, particularly if it is the way of minimal integration pain. In any case, I'm interested in your experience, so please do share any or other way! Alex. > > Have a nice time all, and happy designing > >