From d6ff965abb956ab8f6c369c5ce82007d12417af3 Mon Sep 17 00:00:00 2001 From: Simon Quigley Date: Wed, 9 Apr 2025 05:59:49 -0500 Subject: [PATCH] [pkgselectprocess] Disable the dpkg trigger inhibition logic this cycle. The original goal here was to de-duplicate some of the trigger processing work, but it's obvious this needs more work. It's too premature to ship right now, unfortunately. --- .../pkgselectprocess/PackageSelectProcess.cpp | 17 ++++++++++++++++- debian/changelog | 4 ++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/common/modules/pkgselectprocess/PackageSelectProcess.cpp b/common/modules/pkgselectprocess/PackageSelectProcess.cpp index 090ecb9..7fc687f 100644 --- a/common/modules/pkgselectprocess/PackageSelectProcess.cpp +++ b/common/modules/pkgselectprocess/PackageSelectProcess.cpp @@ -324,12 +324,14 @@ Calamares::JobResult PackageSelectProcess::exec() } // Add diversions for dracut, update-initramfs, and locale-gen + /* dpkgDiversions = { {"dracut", "/usr/bin/dracut"}, {"update-initramfs", "/usr/sbin/update-initramfs"}, {"locale-gen", "/usr/sbin/locale-gen"} }; divert(true); + */ double installStart; double installEnd; @@ -363,6 +365,19 @@ Calamares::JobResult PackageSelectProcess::exec() const QString checkpackage_path = "/usr/libexec/checkpackage-backend"; const QString chroot_checkpackage_path = rootMountPoint + checkpackage_path; + // As part of the fix for LP: #2104343, we need to ensure that, if + // we are currently in OEM mode, Calamares and friends remain + // installed. During stage two, we clean it up. + // FIXME: When the OEM stack is rewritten in 25.10, this needs to be + // rewritten. + if (QFile::exists("/etc/calamares/OEM_MODE_ACTIVATED")) { + QStringList wip_list; + for (auto debPackage : debPackages) { + if (!debPackage.contains(QString("calamares"))) wip_list << debPackage; + } + debPackages = wip_list; + } + // checkpackage-backend needs to be explicitly copied to the chroot // and removed later for systems with stacked squashfses, or the // install command will fail. LP: #2104243 @@ -419,7 +434,7 @@ Calamares::JobResult PackageSelectProcess::exec() true); // Disable diversions - divert(false); + //divert(false); // Handle snap packages if (installationMode != "minimal") { diff --git a/debian/changelog b/debian/changelog index 9f8379a..7773850 100644 --- a/debian/changelog +++ b/debian/changelog @@ -13,6 +13,10 @@ calamares-settings-ubuntu (1:25.04.24) UNRELEASED; urgency=medium (LP: #2104343). * [OEM] [Kubuntu] In stage two, ensure we use Wayland, consistent with the rest of the session scripts. + * [pkgselectprocess] Disable the dpkg trigger inhibition logic this cycle. + The original goal here was to de-duplicate some of the trigger processing + work, but it's obvious this needs more work. It's too premature to ship + right now, unfortunately. -- Simon Quigley Wed, 09 Apr 2025 01:55:07 -0500