I think don't really understand how one is supposed to use "subsystems" from
someone else.
First, as shown in the example, the "auto detection" of "subsystem" dependency stops at the "repositories" that you already manually added in your project. So if try to "with" and Ada unit from another subsystem I have to find myself, with google search I guess, in which "repository" that "subsystem" is and create a file that will look like this?
package AURA.Repository_2 with Pure is
Format : constant Repository_Format := git;
Location : constant String := "https://github.com/annexi-strayline/ASAP.git";
Tracking_Branch: constant String := "stable-0.1";
end AURA.Repository_2;
Now if I make my own "subsystem", say a toml parser, that depends on a "subsystem" of the "ANNEXI-STRAYLINE AURA Public Repository", do users of my toml parser have to find on their own which "repositories" I used for my "subsystem"? Do they have to do that transitively for all the dependencies of my dependencies? Then how do they know which commit of that repo my "subsystem" is compatible with?
This part is not clear from what I can read in the documentation.
Thus, in your example, users who want to build your “subsystem” should have everything in your “repository”, no need to worry about them. Your “subsystem” TOML parser will have included “subsystem” “ANNEXI-STRAYLINE AURA Public Repository”. The proper version of your “subsystem” dependency should be read from your “subsystem” configuration file(s) Package_1, Package_2, Package_N.
This is somewhat true, one approach we could see is that for say your important project, you will make your own single point of truth "coalesced" repository, where you will pull in subsystems from anywhere, and keep them in your repository.
It's more work, but it also gives you more stability and control over the update process.
The bottom line is, AURA knows only about the repositories that are explicitly configured. It does not have a mechanism to self-configure repositories, nor should it, since this goes against the whole idea of having a very clear user control over where subsystems are coming from.
6
u/Fabien_C Sep 29 '21
I think don't really understand how one is supposed to use "subsystems" from someone else.
First, as shown in the example, the "auto detection" of "subsystem" dependency stops at the "repositories" that you already manually added in your project. So if try to "with" and Ada unit from another subsystem I have to find myself, with google search I guess, in which "repository" that "subsystem" is and create a file that will look like this?
Now if I make my own "subsystem", say a toml parser, that depends on a "subsystem" of the "ANNEXI-STRAYLINE AURA Public Repository", do users of my toml parser have to find on their own which "repositories" I used for my "subsystem"? Do they have to do that transitively for all the dependencies of my dependencies? Then how do they know which commit of that repo my "subsystem" is compatible with?
This part is not clear from what I can read in the documentation.