comp.lang.ada
 help / color / mirror / Atom feed
* Gnattest under Debian/Ubuntu Linux/Linux Lint
@ 2013-02-08 16:50 ziotom78
  2013-02-08 18:04 ` Simon Wright
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: ziotom78 @ 2013-02-08 16:50 UTC (permalink / raw)


Hi to everybody,

  I am trying to have GNAT installed on my Linux Mint 14 (Nadia) computer, and I have some problems in determining how to install "gnattest". I have verified it is *not* in any of the following packages:
- gnat-4.6
- gnat-4.6-base
- gnat-gps
- gnat-gps-common
- libaunit2-dev
- libaunit3
- asis-programs

What puzzles me is that in AdaCore's repositories its source code belongs to "gps":

http://viewvc.libre.adacore.com/viewvc.cgi/Public/trunk/gps/gnattest/

so I assumed that installing "gnat-gps" would've been enough to have "gnattest" as well. Is it true that this tool is not available in Debian packages? (This would not be the first weird thing with Gnat's packages in Debian...)

If "gnattest" is really missing, is there any quick way to install it instead of uninstalling Debian's Gnat and downloading AdaCore's? Last time I tried under Ubuntu x64 I had a few problems because of some inconsistencies in the directory where libraries should be installed, and I would therefore like to stick with Debian packages if possible.

Thank you all,
  Maurizio.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Gnattest under Debian/Ubuntu Linux/Linux Lint
  2013-02-08 16:50 Gnattest under Debian/Ubuntu Linux/Linux Lint ziotom78
@ 2013-02-08 18:04 ` Simon Wright
  2013-02-08 19:14   ` Ludovic Brenta
  2013-02-08 20:53 ` ziotom78
  2013-02-08 22:45 ` ziotom78
  2 siblings, 1 reply; 6+ messages in thread
From: Simon Wright @ 2013-02-08 18:04 UTC (permalink / raw)


ziotom78@gmail.com writes:

>   I am trying to have GNAT installed on my Linux Mint 14 (Nadia)
> computer, and I have some problems in determining how to install
> "gnattest". I have verified it is *not* in any of the following
> packages:
> - gnat-4.6
> - gnat-4.6-base
> - gnat-gps
> - gnat-gps-common
> - libaunit2-dev
> - libaunit3
> - asis-programs
>
> What puzzles me is that in AdaCore's repositories its source code
> belongs to "gps":
>
> http://viewvc.libre.adacore.com/viewvc.cgi/Public/trunk/gps/gnattest/
>
> so I assumed that installing "gnat-gps" would've been enough to have
> "gnattest" as well. Is it true that this tool is not available in
> Debian packages? (This would not be the first weird thing with Gnat's
> packages in Debian...)

It's a synchronisation problem.

gnattest is an ASIS[1][2][3] tool (it has to understand the program
structure).

I'm pretty sure that the only ASIS sources we GNAT users get to see are
those in the GNAT GPL sources on libre.adacore.com.

gnattest first appeared in GNAT GPL 2012 ASIS, and Debian is (I believe)
currently using the GNAT GPL 2010 version.

> If "gnattest" is really missing, is there any quick way to install it
> instead of uninstalling Debian's Gnat and downloading AdaCore's? Last
> time I tried under Ubuntu x64 I had a few problems because of some
> inconsistencies in the directory where libraries should be installed,
> and I would therefore like to stick with Debian packages if possible.

Only _some_ inconsistencies?! When you install GNAT GPL, you can choose
the top-level directory, and then you just need to make sure $prefix/bin
is on your path, which will keep things apart; but I agree, you really
don't want to mix libraries.

I wonder how much trouble it'd be to get gnattest to build under Debian?

[1] http://www.sigada.org/WG/asiswg/
[2] http://sourceforge.net/projects/gnat-asis/ (not up-to-date)
[3] http://forward-in-code.blogspot.co.uk/2011/10/building-asis.html



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Gnattest under Debian/Ubuntu Linux/Linux Lint
  2013-02-08 18:04 ` Simon Wright
@ 2013-02-08 19:14   ` Ludovic Brenta
  0 siblings, 0 replies; 6+ messages in thread
From: Ludovic Brenta @ 2013-02-08 19:14 UTC (permalink / raw)


Simon Wright writes on comp.lang.ada:
> ziotom78@gmail.com writes:
>> I am trying to have GNAT installed on my Linux Mint 14 (Nadia)
>> computer, and I have some problems in determining how to install
>> "gnattest". I have verified it is *not* in any of the following
>> packages:
>> - gnat-4.6
>> - gnat-4.6-base
>> - gnat-gps
>> - gnat-gps-common
>> - libaunit2-dev
>> - libaunit3
>> - asis-programs
>>
>> What puzzles me is that in AdaCore's repositories its source code
>> belongs to "gps":
>>
>> http://viewvc.libre.adacore.com/viewvc.cgi/Public/trunk/gps/gnattest/
>>
>> so I assumed that installing "gnat-gps" would've been enough to have
>> "gnattest" as well. Is it true that this tool is not available in
>> Debian packages? (This would not be the first weird thing with Gnat's
>> packages in Debian...)

No, gnattest is not available in Debian packages at the moment.  As you
noticed the sources are part of the gnat-gps sources but for a version
later than 5.1 (Debian currently has gnat-gps 5.0).

> It's a synchronisation problem.
>
> gnattest is an ASIS[1][2][3] tool (it has to understand the program
> structure).
>
> I'm pretty sure that the only ASIS sources we GNAT users get to see are
> those in the GNAT GPL sources on libre.adacore.com.

Debian has libgnatvsn, built from the GCC sources, to ensure
synchronization between GCC and ASIS.

> gnattest first appeared in GNAT GPL 2012 ASIS, and Debian is (I
> believe) currently using the GNAT GPL 2010 version.

More correctly, GCC 4.6 and ASIS GPL 2010 Edition, glued by libgnatvsn.

>> If "gnattest" is really missing, is there any quick way to install it
>> instead of uninstalling Debian's Gnat and downloading AdaCore's? Last
>> time I tried under Ubuntu x64 I had a few problems because of some
>> inconsistencies in the directory where libraries should be installed,
>> and I would therefore like to stick with Debian packages if possible.

There is no quick way.  You'd have to rebuild ASIS and GPS from sources
using GNAT GPL 2012 Edition; gnattest would come as part of GPS.  Sorry
if that's not what you wanted to hear :/

> Only _some_ inconsistencies?! When you install GNAT GPL, you can choose
> the top-level directory, and then you just need to make sure $prefix/bin
> is on your path, which will keep things apart; but I agree, you really
> don't want to mix libraries.
>
> I wonder how much trouble it'd be to get gnattest to build under Debian?

I've already completed the packaging of GNAT 4.8 (with its libgnatvsn)
for Debian.  The next steps are to package ASIS 2012, a later version of
GtkAda, and then (last) a recent version of gnat-gps.  Usually, doing
this takes me between 6 and 12 months.  Now if someone would step
forward and offer help... :)

-- 
Ludovic Brenta.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Gnattest under Debian/Ubuntu Linux/Linux Lint
  2013-02-08 16:50 Gnattest under Debian/Ubuntu Linux/Linux Lint ziotom78
  2013-02-08 18:04 ` Simon Wright
@ 2013-02-08 20:53 ` ziotom78
  2013-02-08 22:45 ` ziotom78
  2 siblings, 0 replies; 6+ messages in thread
From: ziotom78 @ 2013-02-08 20:53 UTC (permalink / raw)


Thanks to everybody for your helpful comments. Now that I know what is the situation, I think I'll try again to download GNAT from AdaCore.

Best,
  Maurizio.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Gnattest under Debian/Ubuntu Linux/Linux Lint
  2013-02-08 16:50 Gnattest under Debian/Ubuntu Linux/Linux Lint ziotom78
  2013-02-08 18:04 ` Simon Wright
  2013-02-08 20:53 ` ziotom78
@ 2013-02-08 22:45 ` ziotom78
  2013-03-12 10:40   ` Justin Time
  2 siblings, 1 reply; 6+ messages in thread
From: ziotom78 @ 2013-02-08 22:45 UTC (permalink / raw)


Hi again,

  It turns out it was easier than I expected. Basically, after having downloaded the tar file from http://libre.adacore.com/download/, I compiled and installed gnatgpl into /usr/gnat (the default choice), I put the following file into /etc/profile.d/gnat.sh:

#!/bin/sh
export PATH=/usr/gnat/bin:$PATH
export LD_LIBRARY_PATH=/usr/gnat/lib:/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH
export LIBRARY_PATH=/usr/gnat/lib:/usr/lib/x86_64-linux-gnu:$LIBRARY_PATH
export ADA_PROJECT_PATH=/usr/gnat/lib/gnat

(Avoiding the reference to /usr/lib/x86_64-linux-gnu leads to a weird behavior, as it will make gcc crash at link time because it is not able to find crt1.o -- fortunately I already knew the solution to this problem. The other definitions are pretty standard stuff.)

After sourcing the file (with ". /etc/profile.d/gnat.sh"), I was able to compile AUnit, GnatColl, Florist, AUnit, XmlAda, and GtkAda quite easily (the latter required to remove one #include instruction which made GLib complain).

Everything seems to work well now, and I finally have an usable "gnattest". (Only a minor nuisance: GPS does not look very nice, perhaps the Gtk+ version it links to is older than the one used by the gnat-gps package. Anyway, it seems to be fully functional.)

I am writing this here so perhaps it'll be of some use for somebody else in my situation.

Cheers,
  Maurizio.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Gnattest under Debian/Ubuntu Linux/Linux Lint
  2013-02-08 22:45 ` ziotom78
@ 2013-03-12 10:40   ` Justin Time
  0 siblings, 0 replies; 6+ messages in thread
From: Justin Time @ 2013-03-12 10:40 UTC (permalink / raw)


Le vendredi 8 février 2013 23:45:47 UTC+1, ziot...@gmail.com a écrit :
 
> I am writing this here so perhaps it'll be of some use for somebody else in my situation.
> 
>   Maurizio.


Thanks Maurizio,

Your post proved very helfull for installing on Adacore Debian Wheezy AMD64
To build GtkAda (or any program using C files), you must also specify variable C_INCLUDE_PATH.
So file /etc/profile.d/gnat.sh should look like :

#!/bin/sh
export PATH=/usr/gnat/2012/bin:$PATH
export LD_LIBRARY_PATH=/usr/gnat/2012/lib:/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH
export LIBRARY_PATH=/usr/gnat/2012/lib:/usr/lib/x86_64-linux-gnu:$LIBRARY_PATH
export C_INCLUDE_PATH=/usr/include/x86_64-linux-gnu
export GPR_PROJECT_PATH=/usr/gnat/2012/lib/gnat



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-03-12 10:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-08 16:50 Gnattest under Debian/Ubuntu Linux/Linux Lint ziotom78
2013-02-08 18:04 ` Simon Wright
2013-02-08 19:14   ` Ludovic Brenta
2013-02-08 20:53 ` ziotom78
2013-02-08 22:45 ` ziotom78
2013-03-12 10:40   ` Justin Time

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