comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: Erroneous installation for GPRBuild on Ubuntu ?
Date: Thu, 26 May 2011 13:21:24 +0100
Date: 2011-05-26T13:21:24+01:00	[thread overview]
Message-ID: <m2aae97iuz.fsf@pushface.org> (raw)
In-Reply-To: op.vv2dudg2ule2fv@douda-yannick

"Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr> writes:

> I've installed GNAT in Ubuntu (10.10) since 4 months. This works
> fine. Today, I wanted to install AUnit. The documentation stated
> GPRBuild is  required for that. So I installed GPRBuild (which I did
> not installed so  far), and launched the “make” command from the
> “aunit-gpl-2010-src”  directory.
>
> It failed, with this rather surprising message:
>
>> aunit_build.gpr:3:09: warning: no compiler specified forlanguage
>> "Ada", ignoring all its sources
>> […]
>> gprbuild: no sources to compile
>
> How is this possible ? No compiler specified for language "Ada", it says ?
>
> Note: both the FSF Ada compiler and GPRBuild was installed from
> official packages (not installed from scratch).

When you say "GPRBuild was installed from official packages" I suppose
you mean AdaCore's?

I think the trouble is that gprbuild has lots of flexibility to run
different compilers in different circumstances, and this can confuse it.

I presume that your GNAT's gcc and gprbuild are both on your PATH (NB,
gprbuild is looking for "gcc", not "gnatgcc"). If this is OK and
gprbuild still doesn't work, then execute

   $ gcc -v

and check the Target: line; here, I get

   $ gcc -v
   Using built-in specs.
   COLLECT_GCC=gcc
   COLLECT_LTO_WRAPPER=/opt/gcc-4.6.0-x86_64/libexec/gcc/x86_64-apple-darwin10/4.6.0/lto-wrapper
   Target: x86_64-apple-darwin10
   [...]

and you need to tell gprbuild to use that target.

Without,

   $ /opt/gnat-gpl-2010-x86_64/bin/gprbuild -P default
   default.gpr:1:09: no languages defined for this project
   gprbuild: "default" processing failed

With,

   $ /opt/gnat-gpl-2010-x86_64/bin/gprbuild \
     --target=x86_64-apple-darwin10 -P default
   gcc -c -g -gnatQ -gnato -fstack-check -g acc.adb
   [...]




  parent reply	other threads:[~2011-05-26 12:21 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-26  1:16 Erroneous installation for GPRBuild on Ubuntu ? Yannick Duchêne (Hibou57)
2011-05-26  8:21 ` Ludovic Brenta
2011-05-26 15:03   ` Yannick Duchêne (Hibou57)
2011-05-26 15:09     ` Yannick Duchêne (Hibou57)
2011-05-26 12:21 ` Simon Wright [this message]
2011-05-26 14:43   ` Yannick Duchêne (Hibou57)
2011-05-27  7:04     ` Ludovic Brenta
2011-05-27 11:39     ` Stephen Leake
2011-05-27 13:49       ` Yannick Duchêne (Hibou57)
2011-05-27 12:34     ` Ludovic Brenta
2011-05-27 11:33 ` Stephen Leake
2011-05-27 13:44   ` Yannick Duchêne (Hibou57)
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox