0

The gprinstall program part of the GNAT tool-set seems to ignore the prefix attribute in the project file. It does use the --prefix when specified on the command line. Is there a way to force it to use the prefix in the project file?

Jacob Sparre Andersen
  • 6,733
  • 17
  • 22
Wayne B.
  • 7
  • 1
  • 1
  • 1
    For a tool-related question, it helps if you say the OS you’re on and the release of the toolset (e.g. output of `gnatls -v`). For any question, it helps if you can say exactly what you tried (in this case, the actual GPR would help, as well as exactly where the software is installed). You can use the `--dry-run` switch to `gprinstall` to see what would happen without trashing your filesystem. – Simon Wright Feb 18 '17 at 08:11

1 Answers1

1

In your project file, you simply add the package Install, where you declare which prefix you want to use:

   package Install is
      for Prefix use "/tmp/installed";
   end Install;

If you declare a relative path, it will be prefixed with either the default prefix or the one passed on the command line.

See the manual for further details.

Jacob Sparre Andersen
  • 6,733
  • 17
  • 22