What with package do I use for texttools

I’m just trying out libtexttools. I’ve installed it using

sudo apt install libtexttools11-dev

That works - it installs the files in /usr/share/ada/adainclude/ along with ncursesada and gnatcoll. I’m just trying a file ttcheck.adb

with common; use common;
procedure ttcheck is
begin
   null;
end ttcheck;

When I use

alr build

it tells me it can’t find common.ads. If I try adding

alr with texttools

It says it can’t find texttools - but it is there along with ncurses and gnatcoll. Is there something else I need to do?

It is basically missing a crate. I’ll post the crate here and to the author
when I’ve written it.

1 Like

You need the crate in order to use the dependency through Alire, but if you just simply want to use the library, after installation in Debian, the project file will be directly visible to be used by gprbuild (at least if this program also comes from Debian).

That is, in ttcheck.gpr:

with "texttools";

project ttcheck is
  -- Whatever else you need   
end ttcheck;

And then:

$ gprbuild -P ttcheck.gpr ttcheck.adb
Compile
   [Ada]          ttcheck.adb
Bind
   [gprbind]      ttcheck.bexch
   [Ada]          ttcheck.ali
Link
   [link]         ttcheck.adb

Nevertheless, having this library as an Alire crate would be good news. In fact, all the Ada libraries already on Debian should be on the Alire index too.

You must use the system gnat/gprbuild for Ada system libraries to work, right?

Kind of a side note/unrelated to the OP:

I haven’t tried it, but since the one installed by alire has bin/share directories, I would be curious to see if one could install them there instead of at the system folders and it might still work

Yes, you’re right. The system gprbuild includes /usr/share/gpr in the default project path, but toolchains installed by Alire don’t seem to do it. One can compare the output of gprls -v for that.