From 1afd2bbcf76417dab955044033b933edfa65ac4e Mon Sep 17 00:00:00 2001 From: yahmad Date: Mon, 12 Dec 2022 21:07:42 +0100 Subject: [PATCH] Resolves: #2151938 Increase the max number of open files to 20. --- ...s-increase-the-max-number-of-open-fi.patch | 50 +++++++++++++++++++ binutils.spec | 9 +++- 2 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 binutils-increase-the-max-number-of-open-fi.patch diff --git a/binutils-increase-the-max-number-of-open-fi.patch b/binutils-increase-the-max-number-of-open-fi.patch new file mode 100644 index 0000000..fcec7c0 --- /dev/null +++ b/binutils-increase-the-max-number-of-open-fi.patch @@ -0,0 +1,50 @@ +From edf0f284b13293bb9740795131d18fe281139c48 Mon Sep 17 00:00:00 2001 +From: "H.J. Lu" +Date: Sat, 16 Jan 2021 18:36:40 -0800 +Subject: [PATCH] PR binutils/23460: Increase the max number of open files to + 20 + +Increase the max number of open files to 20 for PR binutils/23460 test +which may have more than 16 file descriptors open: + +lr-x------ 1 hjl hjl 64 Jan 16 16:49 0 -> /dev/null +l-wx------ 1 hjl hjl 64 Jan 16 16:49 1 -> pipe:[14151430] +lr-x------ 1 hjl hjl 64 Jan 16 16:49 10 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460c.o +lr-x------ 1 hjl hjl 64 Jan 16 16:49 11 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460d.o +lr-x------ 1 hjl hjl 64 Jan 16 16:49 12 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460e.o +lr-x------ 1 hjl hjl 64 Jan 16 16:49 13 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460f.o +lrwx------ 1 hjl hjl 64 Jan 16 16:49 14 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/stTLiXpO +lrwx------ 1 hjl hjl 64 Jan 16 16:49 15 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/stTLiXpO +l-wx------ 1 hjl hjl 64 Jan 16 16:49 2 -> pipe:[14151430] +lr-x------ 1 hjl hjl 64 Jan 16 16:49 3 -> pipe:[13933216] +l-wx------ 1 hjl hjl 64 Jan 16 16:49 4 -> pipe:[13933216] +lr-x------ 1 hjl hjl 64 Jan 16 16:49 5 -> pipe:[13990857] +l-wx------ 1 hjl hjl 64 Jan 16 16:49 6 -> pipe:[13990857] +lr-x------ 1 hjl hjl 64 Jan 16 16:49 7 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/libpr23460.a +lr-x------ 1 hjl hjl 64 Jan 16 16:49 8 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460a.o +lr-x------ 1 hjl hjl 64 Jan 16 16:49 9 -> /export/build/gnu/tools-build/x86_64-linux-toolchain/build-x86_64-linux/binutils/src/binutils-build/ld/tmpdir/pr23460b.o + + PR binutils/23460 + * testsuite/ld-plugin/lto.exp: Increase the max number of open + files to 20 for PR binutils/23460 test. +--- + ld/ChangeLog | 6 ++++++ + ld/testsuite/ld-plugin/lto.exp | 2 +- + 2 files changed, 7 insertions(+), 1 deletion(-) + +diff --git a/ld/testsuite/ld-plugin/lto.exp b/ld/testsuite/ld-plugin/lto.exp +index 3c129760498..dbda6c4465d 100644 +--- a/ld/testsuite/ld-plugin/lto.exp ++++ b/ld/testsuite/ld-plugin/lto.exp +@@ -721,7 +721,7 @@ if { [at_least_gcc_version 4 7] } { + ] \ + ] + set exec_output [run_host_cmd "sh" \ +- "-c \"ulimit -n 16; \ ++ "-c \"ulimit -n 20; \ + $ar -rc $plug_opt \ + tmpdir/libpr23460.a \ + tmpdir/pr23460a.o \ +-- +2.38.1 + diff --git a/binutils.spec b/binutils.spec index 2154bf0..2db879d 100644 --- a/binutils.spec +++ b/binutils.spec @@ -2,7 +2,7 @@ Summary: A GNU collection of binary utilities Name: binutils%{?_with_debug:-debug} Version: 2.35.2 -Release: 30%{?dist} +Release: 31%{?dist} License: GPLv3+ URL: https://sourceware.org/binutils @@ -416,6 +416,10 @@ Patch59: binutils-ld-ir-plugin.patch # Lifetime: Fixed in 2.39 (maybe ?) Patch60: binutils-autoconf-version.patch +# Purpose: Increase the max number of open files to 20 for upstream binutils +# PR23460 test which may have more than 16 file descriptors open +# Lifetime: Fixed in 2.39 +Patch61: binutils-increase-the-max-number-of-open-fi.patch #---------------------------------------------------------------------------- Provides: bundled(libiberty) @@ -1268,6 +1272,9 @@ exit 0 #---------------------------------------------------------------------------- %changelog +* Mon Dec 12 2022 Yara Ahmamd -2.35.2-31 +- Increase the max number of open files to 20. (#2151938) + * Mon Dec 12 2022 Nick Clifton - 2.35.2-30 - Disable building GOLD for cross-binutils.