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,3d76796391769899 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news4.google.com!news2.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!news.flashnewsgroups.com-b7.4zTQh5tI3A!not-for-mail From: Stephen Leake Newsgroups: comp.lang.ada Subject: Re: GCC conflict on Ubuntu for mixed Ada/C++ project References: <41d3829e-286d-4894-9140-31343bfa75ac@o12g2000vba.googlegroups.com> Date: Tue, 18 May 2010 03:53:01 -0400 Message-ID: <82632l1w9u.fsf@stephe-leake.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (windows-nt) Cancel-Lock: sha1:/we+4698djiT7qVIVWkjffMz3wk= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Complaints-To: abuse@flashnewsgroups.com Organization: FlashNewsgroups.com X-Trace: daf524bf247c5e197caa713960 Xref: g2news2.google.com comp.lang.ada:11702 Date: 2010-05-18T03:53:01-04:00 List-Id: zeta_no writes: > With the distribution of GNAT GPL form Adacore Libre comes some code > examples like "ada_cpp" that presents mixed Ada/C++ projetcs. My > problem is the following: In GPS, for the project to build, we need > GPRBUILD which uses GCC and the -gnat05 option. Well, using GPRBUILD, > the ouput of a BUILD ALL tells me that GCC 4.4 installed by Ubuntu was > triggered, not GCC 4.3 coming with the GNAT distro. How do I tell GPS > and GPRBUILD to use the good GCC? The problem is on the Ubuntu side or > GPRBUILD? It's on your side; set PATH to include the correct gcc first. Or uninstall gcc 4.4 from Ubuntu. Or install GPS and gprbuild from Ubuntu; both are in Debian testing, I don't know if they are in Ubuntu yet. If they are not in Ubuntu, upgrade to Debian. Just out of curiosity; why are you using Ubuntu instead of Debian in the first place? What version of GNAT GPL are you using? Since it has the older compiler, it is quite likely that there is a newer version. > We have to admit that my setup is ugly. I use GPS and GPRBUILD from > Adacore, but GNAT from Ubuntu. That's what's causing the ugliness; when you install packages outside the normal Unbuntu package manager, you have to expect problems like this. > That's not all. I don't know why, but by using GNAT from Ubuntu, the > second example from ada_cpp, animals.gpr, does not compile at all. I > get the following error mesage: > > cannot import abstract subprogram "Number_Of_Teeth" declared at line > 5. > cannot imp... It is often the case that newer compilers implement language checks that older compilers did not. > If someone could help me with my problem of GNAT versioning to resolve > the good use of GCC, I would really appreciate. Just to confirm, I > did exported /usr/gnat/bin into my PATH env. variable. Is GPS using that PATH? That depends on how you launch it. -- -- Stephe