summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apt-pkg/edsp.cc1
-rw-r--r--doc/external-dependency-solver-protocol.txt6
-rwxr-xr-xtest/integration/test-external-dependency-solver-protocol1
3 files changed, 8 insertions, 0 deletions
diff --git a/apt-pkg/edsp.cc b/apt-pkg/edsp.cc
index db38f588f..225d86de0 100644
--- a/apt-pkg/edsp.cc
+++ b/apt-pkg/edsp.cc
@@ -48,6 +48,7 @@ static void WriteScenarioVersion(pkgDepCache &Cache, FILE* output, pkgCache::Pkg
fprintf(output, "Source: %s\n", Ver.SourcePkgName());
fprintf(output, "Architecture: %s\n", Ver.Arch());
fprintf(output, "Version: %s\n", Ver.VerStr());
+ fprintf(output, "Source-Version: %s\n", Ver.SourceVerStr());
if (Pkg.CurrentVer() == Ver)
fprintf(output, "Installed: yes\n");
if (Pkg->SelectedState == pkgCache::State::Hold ||
diff --git a/doc/external-dependency-solver-protocol.txt b/doc/external-dependency-solver-protocol.txt
index 14e9528c8..5757991a8 100644
--- a/doc/external-dependency-solver-protocol.txt
+++ b/doc/external-dependency-solver-protocol.txt
@@ -227,6 +227,12 @@ field. The following fields are supported in package stanzas:
Release file entry (Origin, Label, Codename, etc.) in the format of
APT_PREFERENCES(5).
+- **Source:** (optional) The name of the source package the binary
+ package this record is for was built from.
+ This field does NOT include the version of the source package unlike
+ the Source field in the dpkg database. The version is optionally
+ available in the **Source-Version:** field.
+
### Answer
diff --git a/test/integration/test-external-dependency-solver-protocol b/test/integration/test-external-dependency-solver-protocol
index 15944da9d..5d5b1c735 100755
--- a/test/integration/test-external-dependency-solver-protocol
+++ b/test/integration/test-external-dependency-solver-protocol
@@ -92,6 +92,7 @@ testsuccessequal 'Package: stuff
Source: stuff
Architecture: all
Version: 1
+Source-Version: 1
Installed: yes
APT-ID: 2
Priority: optional