Skip to content

Commit e9c70d0

Browse files
committed
Bug 2044781 - Only install awk during bootstrap when it is missing. r=firefox-build-system-reviewers,ahochheiden
The openSUSE bootstrapper unconditionally requested the awk capability, but the Tumbleweed base image already provides it through busybox-gawk. That made zypper try to swap in the canonical gawk, hit a package conflict, and abort the non-interactive install. Only add awk to the requested packages when it is not already available. Differential Revision: https://phabricator.services.mozilla.com/D310220
1 parent b4fa722 commit e9c70d0

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

python/mozboot/mozboot/opensuse.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
# License, v. 2.0. If a copy of the MPL was not distributed with this
33
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
44

5+
from mozfile import which
6+
57
from mozboot.base import MERCURIAL_INSTALL_PROMPT, BaseBootstrapper
68
from mozboot.linux_common import LinuxBootstrapper
79

@@ -16,8 +18,9 @@ def __init__(self, version, dist_id, **kwargs):
1618
def install_packages(self, packages):
1719
# watchman is not available
1820
packages = [p for p in packages if p != "watchman"]
19-
# awk might be missing
20-
packages += ["awk"]
21+
# awk may already be pulled in transitively; only request it when missing.
22+
if not which("awk"):
23+
packages += ["awk"]
2124
self.zypper_install(*packages)
2225

2326
def _update_package_manager(self):

0 commit comments

Comments
 (0)