diff --git a/.kdev4/debcargo-conf.kdev4 b/.kdev4/debcargo-conf.kdev4 new file mode 100644 index 000000000..2ffd5cd5e --- /dev/null +++ b/.kdev4/debcargo-conf.kdev4 @@ -0,0 +1,2 @@ +[Project] +VersionControlSupport=kdevgit diff --git a/README.rst b/README.rst index 5ab611f3d..5bd956f0c 100644 --- a/README.rst +++ b/README.rst @@ -226,6 +226,30 @@ conditions for (2), e.g. https://github.com/hsivonen/simd/issues/25 obvious so documentation is less necessary, and dependent crates all do it correctly already.) +Setting collapse_features in debcargo.conf +------------------------------------------ + +Rust and Debian have a two different levels of abstraction when handling dependencies and the +relationship between them. In rust the lowest level is a feature, and in Debian it's the binary +package. + +This means that the following dependency chain is not a problem in rust: + +- crate A with feature AX depends on crate B with feature BY +- crate B with feature BX depends on crate A with feature AY + +This is a perfectly valid situation in the rust+cargo ecosystem. Notice that +there is no dependency cycle on the per-feature level, and this is enforced by +cargo; but if collapse_features is used then package A+AX+AY would cyclicly +depend on package B+BX+BY. + +This is reflected in the Debian packages by producing `Provides` lines for all combinations +of features, and this can become a quite large section. + +Setting `collapse_features = true` in debcargo.toml removes this behaviour and is recommended, +but it can lead to dependency cycles of debian packages, if that happens those must be +broken up by having some or all of the packages set this feature to false. + Changed orig tarballs --------------------- diff --git a/debcargo-conf.kdev4 b/debcargo-conf.kdev4 new file mode 100644 index 000000000..ea62718cf --- /dev/null +++ b/debcargo-conf.kdev4 @@ -0,0 +1,4 @@ +[Project] +CreatedFrom= +Manager=KDevCustomBuildSystem +Name=debcargo-conf