alire-project / GNAT-FSF-builds

Builds of the GNAT Ada compiler from FSF GCC releases
MIT License
32 stars 9 forks source link

Problem: absence of gnatpp #60

Closed yrashk closed 4 months ago

yrashk commented 4 months ago

Is there any reason why gnatpp/gnat pretty is not present in the released build? (gnat-13.2.0-1)

yrashk commented 4 months ago

Found that this can be accomplished by:

  1. Using latest alire 2 beta (to get alr install)
  2. Running alr install libadalang_tools

(or a manual build equivalent of the above)

This is a non-trivial path for somebody not (yet) deeply immersed in the GNAT ecosystem. At the very least, there should be an easier way to discover this (or a simpler) approach.

The above approach is also considerably slower than getting it as a part of a binary toolchain (which is what I expected because gnatpp is documented within GNAT)

I understand there may be historical reasoning behind this, but I'd love to help figure out a better way to handle this, especially for newcomers.

Fabien-Chouteau commented 4 months ago

Hello @yrashk,

gnatpp is indeed not part of GNAT anymore. Do you mind letting us know what documentation did you look at?

In the future alr search should be the first place to look for tools and libraries. (As I am writing this I realize that alr search gnatpp doesn't yield any results 🤦).

yrashk commented 4 months ago

https://docs.adacore.com/gnat_ugn-docs/html/gnat_ugn/gnat_ugn/gnat_utility_programs.html#the-gnat-pretty-printer-gnatpp

Older GCC manuals document it, too. Newer once (seemingly?) don't.

This suggests that it is part of GNAT. Also, gnat command having pretty subcommand suggests that, too.

For an outsider, it was indeed non-trivial to figure out where it went.

Fabien-Chouteau commented 4 months ago

https://docs.adacore.com/gnat_ugn-docs/html/gnat_ugn/gnat_ugn/gnat_utility_programs.html#the-gnat-pretty-printer-gnatpp

This is the AdaCore documentation, the AdaCore GNAT Pro package does include gnatpp, which is not the case for GNAT FSF.

Note that we have modified the alr seach command such that alr search gnatpp will now provide useful information. You can give it a try with the 2.0-rc1 release here: https://github.com/alire-project/alire/releases/tag/v2.0.0-rc1