Nixpkgs Reference Manual says:
Dependencies can be broken down along three axes: their host and
target platforms relative to the new derivation’s, and whether they
are propagated. The platform distinctions are motivated by cross
compilation; see Cross-compilation for exactly what each platform
means. [1] But even if one is not cross compiling, the platforms imply
whether or not the dependency is needed at run-time or build-time, a
concept that makes perfect sense outside of cross compilation. By
default, the run-time/build-time distinction is just a hint for mental
clarity, but with strictDeps set it is mostly enforced even in the
native case.The extension of PATH with dependencies, alluded to above, proceeds
according to the relative platforms alone. The process is carried out
only for dependencies whose host platform matches the new derivation’s
build platform i.e. dependencies which run on the platform where the
new derivation will be built. [2] For each dependency of those
dependencies, dep/bin, if present, is added to the PATH environment
variable.A dependency is said to be propagated when some of its
other-transitive (non-immediate) downstream dependencies also need it
as an immediate dependency. [3]It is important to note that dependencies are not necessarily
propagated as the same sort of dependency that they were before, but
rather as the corresponding sort so that the platform rules still line
up. To determine the exact rules for dependency propagation, we start
by assigning to each dependency a couple of ternary numbers (-1 for
build, 0 for host, and 1 for target) representing its dependency type,
which captures how its host and target platforms are each “offset”
from the depending derivation’s host and target platforms. The
following table summarize the different combinations that can be
obtained: …
What are the three axes? I only saw two:
- their host and target platforms relative to the new derivation’s,
- whether they are propagated.
What do the following parts from the quote mean:
-
the “host and target platforms” of a dependency, as in the first paragraph;
-
“build”, as in “assigning to each dependency a couple of ternary numbers (-1 for build, 0 for host, and 1 for target) representing its dependency type” in the last paragraph; (Is “build” another platform of a dependency, besides the dependency’s “host and target platforms”?)
-
“their host and target platforms relative to the new derivation’s”;
-
the two sentences in bold and in the last paragraph.
?
Can someone rephrase it in a way easier to understand?
Thanks.