Discussion:
[Ghdl-discuss] problem GNAT while compiling the libraries
Patrick Lehmann
2017-02-20 14:35:59 UTC
Permalink
Hello Roberto,

I find it strange that your gnat names himself "GNAT GPL 2016" instead of gnat 6.3.0 or any other GCC like version number.

What is your system's name? Is GNAT standalone in your system or a part of GCC?

Kind regards
Patrick



-------- Originalnachricht --------
Betreff: [Ghdl-discuss] problem GNAT while compiling the libraries
Von: Roberto Hexsel
An: ghdl-***@gna.org
Cc:

greetings,

I am trying to build ghdl from sources, and following the instructions to the letter.

When compiling the VHDL libraries, the error is (Unix comands in bold)


make clean
lots of files removed

make ghdllib
make GHDL=/usr/local/bin/ghdl vhdl.libs.all libs.vhdl.standard
make[1]: Entering directory `/home/roberto/ghdl-master'
if [ -d ./.git ]; then \
desc=`cd .; git describe --dirty`; \
sed -e "s/[(].*[)]/($desc)/" < src/version.in<http://version.in> > version.tmp; \
else \
cp src/version.in<http://version.in> version.tmp; \
fi
if [ ! -r version.ads ] || ! cmp version.tmp version.ads > /dev/null; then cp version.tmp version.ads; fi
gnatmake -aI./src -aI./src/vhdl -aI./src/psl -aI./src/vhdl/translate -aI./src/ghdldrv \
-gnaty3befhkmr -gnatwae -aO. -gnatf -gnat05 -g -gnata ghdl_gcc -bargs -E -largs
gcc -c -I./ -I./src -I./src/vhdl -I./src/psl -I./src/vhdl/translate -I./src/ghdldrv -gnaty3befhkmr -gnatwae -gnatf -gnat05 -g -gnata -I- /home/roberto/ghdl-master/src/ghdldrv/ghdl_gcc.adb
gcc: error: /home/roberto/ghdl-master/src/ghdldrv/ghdl_gcc.adb: Ada compiler not installed on this system
gnatmake: "/home/roberto/ghdl-master/src/ghdldrv/ghdl_gcc.adb" compilation error
make[1]: *** [ghdl_gcc] Error 4
make[1]: Leaving directory `/home/roberto/ghdl-master'
make: *** [libs.vhdl.gcc] Error 2


in an attempt to find the Ada compiler:

which gnat
/usr/local/bin/gnat

/usr/local/bin/gnat --version
GNAT GPL 2016 (20160515-49)
Copyright (C) 1996-2016, Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


apparently, the GNAT compiler is there and is an executable.



Is the path to GNAT hardwired anywhere in the code, or in the Makefiles?

I looked into these and did not find anything wrong.



thanks in advance,
Roberto

--
Roberto Hexsel ***@gmail.com<mailto:***@gmail.com> http://www.inf.ufpr.br/roberto
"facts can speak for themselves with overwhelming precision" J.Conrad
Tristan Gingold
2017-02-20 17:42:52 UTC
Permalink
On 20/02/17 15:27, Roberto Hexsel wrote:
> greetings,
>
> I am trying to build ghdl from sources, and following the instructions
> to the letter.

Hello,

how did you configure ghdl ?

[...]

> in an attempt to find the Ada compiler:
>
> *which gnat*
> /usr/local/bin/gnat
>
> * /usr/local/bin/gnat --version*
> GNAT GPL 2016 (20160515-49)
> Copyright (C) 1996-2016, Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.
> There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
> PARTICULAR PURPOSE.
>
>
> apparently, the GNAT compiler is there and is an executable.

What is the output of:
which gcc

> Is the path to GNAT hardwired anywhere in the code, or in the Makefiles?

No.

Regards,
Tristan.
Patrick Lehmann
2017-02-21 13:36:44 UTC
Permalink
Hello,

Being stuck with gnat 4.6 is a problem of an old Debian. My Debian 9 has a gnat 6.3 :)

Even Debian 8 / 8.x should use a gnat 4.9 or 5.x.

Kind regards
Patrick


-------- Originalnachricht --------
Betreff: Re: [Ghdl-discuss] problem GNAT while compiling the libraries
Von: Roberto Hexsel
An: ghdl-***@gna.org
Cc:

Acting on Patrick's question,

> I find it strange that your gnat names himself "GNAT GPL 2016" instead of gnat 6.3.0 or any other GCC like version number.
>
> What is your system's name? Is GNAT standalone in your system or a part of GCC?

I installed (again) Debian's gnat and the libraries compiled. My regression tests run to completion, and it seems GHDL is correctly installed.

Thanks for your help and patience!

--x--

In spite of being somewhat experienced with Linux-Debian administration, I got confused in the process of building GHDL :)

The instructions say the GNAT should, preferably, be that from http://libre.adacore.com.

I downloaded the tarball with the latest version and installed the files at /usr/local.

This is the GNAT with the "GNAT GPL 2016" version number, and the one which the make-ing of the libraries says "gnat compiler cannot be found".

Considering Patrick's suggestion, I downloaded the (very old) GNAT 4.6 of the Debian distro and with this version, GHDL compiled all the libraries.

The permissions and PATHs were all double-checked before asking for help on ghdl-discuss.

I guess I ought to have stuck with the proven 2014 GNAT.


Please note that this is not a complaint, just a report on my experience.


Regards,
Roberto


--
Roberto Hexsel ***@gmail.com<mailto:***@gmail.com> http://www.inf.ufpr.br/roberto
"facts can speak for themselves with overwhelming precision" J.Conrad
Loading...