From 2b6b7ce591974cfd5e18a05d3b8eefeb93c6b8641e0cf9726aa6804e8da91c79 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Thu, 27 Oct 2022 07:56:22 +0000 Subject: [PATCH] Accepting request 1030521 from home:berny:branches:Base:System - coreutils-tests-workaround-make-fdleak.patch: Add patch to work around a GNU make bug which leaks file descriptors when using the jobserver; this makes some tests fail on OBS. - coreutils.spec: Reference the patch. OBS-URL: https://build.opensuse.org/request/show/1030521 OBS-URL: https://build.opensuse.org/package/show/Base:System/coreutils?expand=0&rev=342 --- coreutils-tests-workaround-make-fdleak.patch | 25 ++++++++++++++++++++ coreutils.changes | 8 +++++++ coreutils.spec | 6 +++-- 3 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 coreutils-tests-workaround-make-fdleak.patch diff --git a/coreutils-tests-workaround-make-fdleak.patch b/coreutils-tests-workaround-make-fdleak.patch new file mode 100644 index 0000000..70a84cd --- /dev/null +++ b/coreutils-tests-workaround-make-fdleak.patch @@ -0,0 +1,25 @@ +--- + tests/init.sh | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +Index: tests/init.sh +=================================================================== +--- tests/init.sh.orig ++++ tests/init.sh +@@ -685,6 +685,16 @@ compare () + } + + # ----------------------------------------------------------------------------- ++# OpenSUSE/OSC workaround. ++# GNU make 4.3.90 leaks a lot of file descriptors when using the jobserver. ++# Close all of them pointing to files matching '/tmp/Gm*'. ++p=$$ ++for n in $(find /proc/$p/fd -lname '/tmp/Gm*' -printf '%P\n'); do ++ exec {n}>&- ++done ++# ----------------------------------------------------------------------------- ++ ++# ----------------------------------------------------------------------------- + + # If you want to override the testdir_prefix_ function, + # or to add more utility functions, use this file. diff --git a/coreutils.changes b/coreutils.changes index eab6af9..dd9e1a7 100644 --- a/coreutils.changes +++ b/coreutils.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Mon Sep 26 20:29:11 UTC 2022 - Bernhard Voelker + +- coreutils-tests-workaround-make-fdleak.patch: Add patch to work around + a GNU make bug which leaks file descriptors when using the jobserver; + this makes some tests fail. +- coreutils.spec: Reference the patch. + ------------------------------------------------------------------- Tue Aug 9 12:13:00 UTC 2022 - Dirk Müller diff --git a/coreutils.spec b/coreutils.spec index 0516330..639fce4 100644 --- a/coreutils.spec +++ b/coreutils.spec @@ -64,6 +64,7 @@ Patch501: coreutils-test_without_valgrind.patch Patch810: coreutils-skip-tests-rm-ext3-perf.patch # Upstream patch - remove with version >9.1: Patch850: gnulib-simple-backup-fix.patch +Patch900: coreutils-tests-workaround-make-fdleak.patch BuildRequires: automake BuildRequires: gmp-devel BuildRequires: hostname @@ -159,6 +160,7 @@ This package contains the documentation for the GNU Core Utilities. %patch810 %patch850 +%patch900 # ================================================ %build @@ -194,13 +196,13 @@ ln -v lib/parse-datetime.{c,y} . chmod a+x tests/misc/sort-mb-tests.sh # Avoid parallel make, because otherwise some timeout based tests like # rm/ext3-perf may fail due to high CPU or IO load. - %make_build check-very-expensive \ + %make_build check-very-expensive VERBOSE=yes \ && install -d -m 755 %{buildroot}%{_docdir}/%{name} \ && xz -c tests/test-suite.log \ > %{buildroot}%{_docdir}/%{name}/test-suite.log.xz %else # Run the shorter check otherwise. - %make_build check + %make_build check VERBOSE=yes %endif # ================================================