mirror of
https://github.com/AdaCore/gpr.git
synced 2026-02-12 12:58:39 -08:00
This project is used by multiple projects that have mains (those that build GPR2-based tools), however not all units in `gpr2tools-common.gpr` are in the closure of each individual GPR2-based tool. As a consequence, following recent gnatcov changes, the instrumentation of each GPR2-based tool (through `gpr2tools-gprbuild.gpr`, `gpr2tools-gprclean.gpr`, ...) instruments a different set of units in `gpr2tools-common.gpr`, and so in the end the set of instrumented units is inconsistent for each tool. To avoid this problem, and because it is actually a good practice for projects that provide common units to multiple projects, turn `gpr2tools-common.gpr` into a library project, so that all of its units are instrumented/considered for coverage, regardless of the actual Ada closure for each individual tool. This fixes coverage builds of gpr2 following the aforementionned gnatcov change.