comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: gprbuild not working on GNAT 2015 GPL for raspberry pi cross compile
Date: Thu, 21 Jun 2018 17:27:20 +0100
Date: 2018-06-21T17:27:20+01:00	[thread overview]
Message-ID: <lyk1qshzpz.fsf@pushface.org> (raw)
In-Reply-To: 7d1aa1b8-44af-417e-8fe0-4512c2f74bf1@googlegroups.com

jeanbaptistesmn@gmail.com writes:

> I think the ENV_PREFIX variable is correctly set :
>
> $ echo $ENV_PREFIX
> /usr/gnat/arm-linux-gnueabihf/sysroot

looks OK

> sysroot directory was generated
>
> and :
>
> $ gprconfig -show-targets
> Lists of targets supported by a compilater:
> arm-linux-gnueabihf
> x86_64-linux-gnu
> arm-linux-gnueabihf

I wonder which gprconfig you're running?

Can you try

$ arm-linux-gnueabihf-gnatls -v

If it says something like "file not found", you're running a 64-bit
Linux; the arm-linux-gnueabihf cross-compiler is built as a 32-bit
executable; and you need the 32-bit system runtime support to be
installed.

On debian jessie I did this, YMMV:

$ sudo dpkg --add-architecture i386
$ sudo apt-get update
$ sudo apt-get upgrade

and then I got a bit lost with what exactly to install, so used
Synaptics to install libstdc++6:i386.

> but when i do :
> $ gprbuild --target=arm-linux-gnueabihf -P myProject.gpr
> "warning: no compiler specified for language "Ada", ignoring all its sources" 
> "main.adb" is not a source of project "myProject"
>
> Simon, i'm not sure i understand your answer :
>
>>Gprconfig looks for a compiler and a runtime. If it finds {target}-gcc
>>it runs -dumpmachine to find the version, then looks for runtimes in
>>(at least) lib/gcc/{target}/{version}; first in adalib/, then via
>>ada_object_path, then via rts-*/.

If when gprconfig finds {target}-gcc and tries to run it with
-dumpmachine and it fails to run, then gprconfig won't consider it as a
candidate compiler.


      reply	other threads:[~2018-06-21 16:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-11 18:13 gprbuild not working on GNAT 2015 GPL for raspberry pi cross compile Brad Moore
2015-07-11 19:04 ` Simon Wright
2015-07-12  4:40 ` Stephen Leake
2015-07-12  5:56   ` Simon Wright
2015-07-12 20:32     ` Brad Moore
2017-08-28 17:22       ` paherbst
2018-06-16 10:28 ` jeanbaptistesmn
2018-06-21 16:27   ` Simon Wright [this message]
replies disabled

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