swtpm: upgrade to jammy fails

Bug #1955114 reported by Heinrich Schuchardt
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
swtpm (Ubuntu)
New
Undecided
Unassigned
Jammy
Triaged
High
Unassigned
Kinetic
New
Undecided
Unassigned

Bug Description

[Impact]

 * swtpm did not use to exist in ubuntu
 * prior to packaging in ubuntu, it was common to compile and use swtpm debian packaging as provided by upstream
 * ubuntu packaging is incompatible with upstream provided one, and upgrades to ubuntu package do not work automatically, despite same naming for some of the packaging

[Test Plan]

 * build and install swtpm & swtpm-libs deb packages from https://github.com/stefanberger/swtpm

 * Attempt to upgrade to ubuntu's provided swtpm

 * The upgrade should automatically break/replace and remove swtpm-libs package that is not used in Ubuntu, and conflicts with swtpm package.

[Where problems could occur]

 * Inverse change may be required in upstream packaging, if they wish to support upgrading from Ubuntu packages to Upstream provided ones.

[Other Info]

 * Original bug report

While trying to upgrade from impish to jammy I get:

Preparing to unpack .../swtpm_0.6.1-0ubuntu5_amd64.deb ...
Unpacking swtpm (0.6.1-0ubuntu5) over (0.6.1) ...
dpkg: error processing archive /var/cache/apt/archives/swtpm_0.6.1-0ubuntu5_amd64.deb (--unpack):
 trying to overwrite '/usr/lib/x86_64-linux-gnu/swtpm/libswtpm_libtpms.so.0.0.0', which is also in package swtpm-libs:amd64 0.6.1
Errors were encountered while processing:
 /var/cache/apt/archives/swtpm_0.6.1-0ubuntu5_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

I had previously installed the swtpm package using the upstream source as the package was not available for Impish.

Best regards

Heinrich

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

Can we mark package swtpm as replacing swtpm-libs?

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

To overcome the problem on my machine I removed the following lines

/var/lib/dpkg/info/swtpm-libs:amd64.list:6:/usr/lib/x86_64-linux-gnu/swtpm/libswtpm_libtpms.so.0.0.0
/var/lib/dpkg/info/swtpm-libs:amd64.list:12:/usr/lib/x86_64-linux-gnu/swtpm/libswtpm_libtpms.so.0

and ran 'apt-get purge swtpm-libs'.

Changed in swtpm (Ubuntu Jammy):
milestone: none → ubuntu-22.04.1
tags: added: rls-jj-incoming
Changed in swtpm (Ubuntu Jammy):
importance: Undecided → Critical
status: New → Triaged
Lukas Märdian (slyon)
tags: added: fr-2549
tags: removed: fr-2549 rls-jj-incoming
Revision history for this message
Brian Murray (brian-murray) wrote :

Given that the issue involved a package from a third party provider I don't think there is anything we can do here.

Changed in swtpm (Ubuntu Jammy):
milestone: ubuntu-22.04.1 → none
importance: Critical → Undecided
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

it exploaded my upgrade to jammy; leaving me with unconfigured perl & python, making me run dpkg -i installs by hand for half an hour.

and the fix is simple "breaks: swtpm-libs replaces: swtpm-libs" in the swtpm package. third-party provider is debian, when we diverge from debian package naming, we should at least safeguard ourselves.

Changed in swtpm (Ubuntu Jammy):
importance: Undecided → High
description: updated
Revision history for this message
Heinrich Schuchardt (xypron) wrote :

Debian's version 0.7.1 follows the upstream packaging. So this issue will be resolved for Kinetic once we upgrade.

For Jammy we could SRU with

  Conflicts: swtpm-libs, swtpm-dev
  Replaces: swtpm-libs, swtpm-dev

added for Package swtpm.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.