Confusion about install locations
Brought to you by:
simonjwright
I'm a bit confused about the installation directories.
setup.tcl offers an INSTALLROOT defaulting to /opt/tash but that does not seem to be used upon make install. Instead, the installation seems to go to the setup.tcl defined prefix, which is determined using the location of gnatls. This means that if my gnatls is /usr/bin/gnatls, prefix will be /usr, and tash.gpr gets installed to /usr/lib/gnat.
However, my gnatls -v gives the following:
GNATLS 4.6
Copyright (C) 1997-2010, Free Software Foundation, Inc.
[...]
Project Search Path:
<Current_Directory>
/usr/share/ada/adainclude/
Hmm...
Anonymous
I think it might be about time to get rid of setup.tcl (I can't use the GUI version on my 13-inch Macbook Pro, because the font size doesn't appear to be (easily?) changeable, so the window extends below the bottom of the screen, and I can't click on the Save button :-)
That said, your problem arises from the file system layout adopted by Debian, which doesn't match up to the one used by GNAT on other platforms (or GNAT GPL). More power to Ludo and friends, a shame that AdaCore couldn't follow their lead (I think they came first). See
makefile:49.Does your GNAT include gprinstall? If so, it could be worth investing time to train it to install on Debian systems.
If not, could just work from the gnatls output.
Is your system rather old? haven't we gone past GCC 4.6?
Good point. It seems that newer GNATs do have prefix/lib/gnat as one of their project search paths.
I tried gnatls -v with GPL-2014 (i686) installed in /opt/gnat/gpl,
and with the system FSF-GNAT that comes with OpenSuSE Tumbleweed (x86_64),
Under Linux, the command
could retrieve the best matching project path, only that the gcc-4.6 based compiler gives the deviating location /usr/share/ada/adainclude/.
I have no idea how this could be handled in Windows.
I just updated the repo; main changes in [77e800].
setup.tclis shortened (I've left out the items that can't be changed), and now detects whether the compiler is a Debian standard (i.e./etc/debian_versionexists and the prefix is/usr), and installs GPRs where the Debian standard compiler expects, i.e.$prefix/share/ada/adainclude/. In all other cases, it'll be$prefix/lib/gnat/.My only Linux setup is Debian jessie (in a VM), so I may well have missed something. If it's OK, we'll go for a release.
By the way,
make installnow usesgprinstall.Related
Commit: [77e800]
Thanks for that.
Tried it on my OpenSuSE Tumbleweed and make install went well (OT: had to patch up a gprbuild bug which I happened to run into.)
Related
Commit: [77e800]
Fixed in release 20191120.