From aea231f489daf4b240387354041bf34ac4392417 Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 13:01:35 +0100 Subject: [PATCH 1/6] contrib/build: ignore initial failure to set $SOURCE More fallout from set -e patch, encountered during a release. Fixes: 64f8ec6099a4 ('rpm/build*.sh: trap failures') --- contrib/fedora/rpm/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/fedora/rpm/build.sh b/contrib/fedora/rpm/build.sh index f46b9ba56e..fe2fd968d1 100755 --- a/contrib/fedora/rpm/build.sh +++ b/contrib/fedora/rpm/build.sh @@ -127,7 +127,7 @@ if [ -n "$SOURCE" ]; then [[ "$SOURCE_FROM_GIT" == 1 ]] && die "Cannot set both \$SOURCE and \$SOURCE_FROM_GIT=1" SOURCE_FROM_GIT=0 elif [[ "$SOURCE_FROM_GIT" != "1" ]]; then - SOURCE="$(ls -1 "$GITDIR/NetworkManager-${VERSION}.tar."* 2>/dev/null | head -n1)" + SOURCE="$(ls -1 "$GITDIR/NetworkManager-${VERSION}.tar."* 2>/dev/null | head -n1 || :)" if [[ -z "$SOURCE" ]]; then [[ "$SOURCE_FROM_GIT" == "0" ]] && die "Either set \$SOURCE or set \$SOURCE_FROM_GIT=1" SOURCE_FROM_GIT=1 From 054962aeea1bc5e0e659c55142b13100878f8aa6 Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 14:52:19 +0100 Subject: [PATCH 2/6] contrib: drop old gtkdoc patch This has been integrated 6 years ago. --- .gitlab-ci/fedora-install.sh | 2 -- contrib/scripts/nm-ci-patch-gtkdoc.sh | 40 --------------------------- 2 files changed, 42 deletions(-) delete mode 100755 contrib/scripts/nm-ci-patch-gtkdoc.sh diff --git a/.gitlab-ci/fedora-install.sh b/.gitlab-ci/fedora-install.sh index 3bd4698366..cafc0e552b 100755 --- a/.gitlab-ci/fedora-install.sh +++ b/.gitlab-ci/fedora-install.sh @@ -66,8 +66,6 @@ else debuginfo-install -y glib2 fi -contrib/scripts/nm-ci-patch-gtkdoc.sh || true - if [ -x /usr/bin/ninja ] && ! [ -x /usr/bin/ninja-build ]; then ln -s /usr/bin/ninja-build /usr/bin/ninja fi diff --git a/contrib/scripts/nm-ci-patch-gtkdoc.sh b/contrib/scripts/nm-ci-patch-gtkdoc.sh deleted file mode 100755 index e72a0a8f6f..0000000000 --- a/contrib/scripts/nm-ci-patch-gtkdoc.sh +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash - -# patch gtk-doc for https://gitlab.gnome.org/GNOME/gtk-doc/merge_requests/2 - -cd / - -patch -f -p 1 --fuzz 0 --reject-file=- < ;' - # This could be an opaque data structure, so we output an - # empty declaration. If the structure is actually found that - # will override this. - structsym = m9.group(1).upper() - logging.info('%s typedef: "%s"', structsym, m9.group(2)) - forward_decls[m9.group(2)] = '<%s>\n%s\n%s\n' % ( - structsym, m9.group(2), deprecated, structsym) - -+ bm = re.search(r'^(\S+)(Class|Iface|Interface)\b', m9.group(2)) -+ if bm: -+ objectname = bm.group(1) -+ logging.info('Found object: "%s"', objectname) -+ title = '%s' % objectname -+ - elif re.search(r'^\s*(?:struct|union)\s+_(\w+)\s*;', line): - # Skip private structs/unions. - logging.info('private struct/union') - - elif m10: - # Do a similar thing for normal structs as for typedefs above. - # But we output the declaration as well in this case, so we - # can differentiate it from a typedef. - structsym = m10.group(1).upper() - logging.info('%s:%s', structsym, m10.group(2)) -EOF - From e2aa19a06cfb84ecb31e979bcb2a9aca0a0a5bfb Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 13:41:22 +0100 Subject: [PATCH 3/6] Revert "fedora/REQUIRED_PACKAGES: speed up optional packages installation" dnf --skip-unavailable not available on CentOS 9. This reverts commit 5409d4f5cd4088e40ee5b7077ffca7380fede731. --- contrib/fedora/REQUIRED_PACKAGES | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/contrib/fedora/REQUIRED_PACKAGES b/contrib/fedora/REQUIRED_PACKAGES index d47e60980a..418318d70c 100755 --- a/contrib/fedora/REQUIRED_PACKAGES +++ b/contrib/fedora/REQUIRED_PACKAGES @@ -25,6 +25,12 @@ install() { fi } +install_ignore_missing() { + for p; do + install "$p" || : + done +} + if test "$NM_NO_EXTRA" != 1; then # these packages are convenient for developing, but not necessary # for CI testing. @@ -82,9 +88,8 @@ install \ which \ #end -# Some packages don't exist in certain distributions. Ignore errors -# installing them, but still drag them in when available. -install --skip-unavailable \ +# some packages don't exist in certain distributions. Install them one-by-one, and ignore errors. +install_ignore_missing \ black \ dbus-python \ dhclient \ From 39efc8a394b46772bb4aae1d5765d4727dcdfeed Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 13:44:03 +0100 Subject: [PATCH 4/6] fedora/REQUIRED_PACKAGES: remove very old optional package names Attempting to install these takes time and they are no longer there since ancient times. CentOS 9 and later are fine. --- contrib/fedora/REQUIRED_PACKAGES | 5 ----- 1 file changed, 5 deletions(-) diff --git a/contrib/fedora/REQUIRED_PACKAGES b/contrib/fedora/REQUIRED_PACKAGES index 418318d70c..1bb7ec6b30 100755 --- a/contrib/fedora/REQUIRED_PACKAGES +++ b/contrib/fedora/REQUIRED_PACKAGES @@ -91,17 +91,12 @@ install \ # some packages don't exist in certain distributions. Install them one-by-one, and ignore errors. install_ignore_missing \ black \ - dbus-python \ dhclient \ iproute-tc \ libasan \ libpsl-devel \ libubsan \ libvala-devel \ - pexpect \ - pygobject3-base \ - python-gobject-base \ - python36-pexpect \ qt-devel \ teamd-devel \ vala-devel \ From 979717df4ee9d84cc3040d154596036576c3deae Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 12:48:47 +0100 Subject: [PATCH 5/6] gitlab/fedora-install: use yum install --allowerasing This allows us to drag in packages that replace something in the base image. Notably, this fixes installing pppd on Fedora 42 that requires systemd (whereas the image has conflicting systemd-standalone-sysusers). --- .gitlab-ci/fedora-install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci/fedora-install.sh b/.gitlab-ci/fedora-install.sh index cafc0e552b..50f9710fc7 100755 --- a/.gitlab-ci/fedora-install.sh +++ b/.gitlab-ci/fedora-install.sh @@ -39,7 +39,7 @@ fi fi -NM_NO_EXTRA=1 NM_INSTALL="yum install -y" ./contrib/fedora/REQUIRED_PACKAGES +NM_NO_EXTRA=1 NM_INSTALL="yum install -y --allowerasing" ./contrib/fedora/REQUIRED_PACKAGES yum install -y glibc-langpack-pl ccache clang # containers have "tsflags=nodocs" in /etc/dnf/dnf.conf. We need /usr/shared/gtk-doc/html From cafb841a291b634e12ccb60110527fb4ebb051a5 Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Wed, 12 Feb 2025 14:58:28 +0100 Subject: [PATCH 6/6] CI: update images --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 758162961c..c3c36ed81d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -61,9 +61,9 @@ variables: # This is done by running `ci-fairy generate-template` and possibly bumping # ".default_tag". ALPINE_TAG: 'tag-77ec3d923fd6' - CENTOS_TAG: 'tag-8af9c6a05c7b' + CENTOS_TAG: 'tag-7a677f4838e1' DEBIAN_TAG: 'tag-ecad19904683' - FEDORA_TAG: 'tag-8af9c6a05c7b' + FEDORA_TAG: 'tag-7a677f4838e1' UBUNTU_TAG: 'tag-ecad19904683' ALPINE_EXEC: 'bash .gitlab-ci/alpine-install.sh'