From bbe68256b8b120eda5e8c5333bcdc0a9af377999 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Jun 29 2021 19:35:06 +0000 Subject: import gcc-toolset-11-make-4.3-2.el8 --- diff --git a/.gcc-toolset-11-make.metadata b/.gcc-toolset-11-make.metadata new file mode 100644 index 0000000..ebf9a3e --- /dev/null +++ b/.gcc-toolset-11-make.metadata @@ -0,0 +1 @@ +3c40e5b49b893dbb14f1e2e1f8fe89b7298cc51d SOURCES/make-4.3.tar.gz diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b01473c --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/make-4.3.tar.gz diff --git a/SOURCES/make-4.0-noclock_gettime.patch b/SOURCES/make-4.0-noclock_gettime.patch new file mode 100644 index 0000000..d2ea0a6 --- /dev/null +++ b/SOURCES/make-4.0-noclock_gettime.patch @@ -0,0 +1,25 @@ +diff -up make-3.82/configure\~ make-3.82/configure +--- make-3.82/configure~ 2010-07-28 07:41:51.000000000 +0200 ++++ make-3.82/configure 2010-08-11 15:07:50.000000000 +0200 +@@ -7215,7 +7215,7 @@ return clock_gettime (); + return 0; + } + _ACEOF +-for ac_lib in '' rt posix4; do ++for ac_lib in '' posix4; do + if test -z "$ac_lib"; then + ac_res="none required" + else + +--- a/configure 2021-06-10 17:42:59.552623763 -0400 ++++ b/configure 2021-06-10 17:41:27.867071403 -0400 +@@ -16054,7 +16054,7 @@ return clock_gettime (); + return 0; + } + _ACEOF +-for ac_lib in '' posix4; do ++for ac_lib in '' rt posix4; do + if test -z "$ac_lib"; then + ac_res="none required" + else + diff --git a/SOURCES/make-4.3-cloexec.patch b/SOURCES/make-4.3-cloexec.patch new file mode 100644 index 0000000..c680367 --- /dev/null +++ b/SOURCES/make-4.3-cloexec.patch @@ -0,0 +1,36 @@ +From d79fe162c009788888faaf0317253b6f0cac7092 Mon Sep 17 00:00:00 2001 +From: Kevin Buettner +Date: Thu, 23 Apr 2020 17:05:34 -0400 +Subject: [SV 58232] Disable inheritance of jobserver FDs for recursive make + +A parent make will invoke a sub-make with close-on-exec disabled for +the jobserver pipe FDs. Force close-on-exec to be to be enabled in +the sub-make so the pipe is not always passed to child jobs. + +I have a test case which, when invoked with a suitable -j switch, +will hang if the recipe inherits the jobserver pipe. This test case +was inspired by a real world case in which testing GDB on Fedora +would hang due to some poorly written test GDB cases having been +passed the jobserver file descriptors. + +* src/posixos.c (jobserver_parse_auth): Call fd_noinherit() for +jobserver pipe descriptors. + +Copyright-paperwork-exempt: yes + +diff --git a/src/posixos.c b/src/posixos.c +index 525f292c..eab175a4 100644 +--- a/src/posixos.c ++++ b/src/posixos.c +@@ -145,6 +145,11 @@ jobserver_parse_auth (const char *auth) + /* When using pselect() we want the read to be non-blocking. */ + set_blocking (job_fds[0], 0); + ++ /* By default we don't send the job pipe FDs to our children. ++ See jobserver_pre_child() and jobserver_post_child(). */ ++ fd_noinherit (job_fds[0]); ++ fd_noinherit (job_fds[1]); ++ + return 1; + } + diff --git a/SOURCES/make-4.3-getcwd.patch b/SOURCES/make-4.3-getcwd.patch new file mode 100644 index 0000000..7f6f18f --- /dev/null +++ b/SOURCES/make-4.3-getcwd.patch @@ -0,0 +1,12 @@ +diff -Nrup a/src/makeint.h b/src/makeint.h +--- a/src/makeint.h 2016-05-21 16:22:32.000000000 -0400 ++++ b/src/makeint.h 2016-09-22 16:12:38.606702160 -0400 +@@ -596,7 +596,7 @@ long int lseek (); + # endif + + # ifdef HAVE_GETCWD +-# if !defined(VMS) && !defined(__DECC) ++# if !defined(VMS) && !defined(__DECC) && !defined(getcwd) + char *getcwd (); + # endif + # else diff --git a/SOURCES/make-4.3-j8k.patch b/SOURCES/make-4.3-j8k.patch new file mode 100644 index 0000000..60a0c7f --- /dev/null +++ b/SOURCES/make-4.3-j8k.patch @@ -0,0 +1,25 @@ +diff -Nrup a/src/main.c b/src/main.c +--- a/src/main.c 2016-05-31 03:17:26.000000000 -0400 ++++ b/src/main.c 2016-09-22 16:18:52.283889265 -0400 +@@ -2051,6 +2051,21 @@ main (int argc, char **argv, char **envp + } + #endif + ++#ifdef PIPE_BUF ++ if (job_slots > PIPE_BUF) ++#elif defined _POSIX_PIPE_BUF ++ if (job_slots > _POSIX_PIPE_BUF) ++#else ++ if (job_slots > 512) ++#endif ++ { ++ O (error, NILF, ++ _("More parallel jobs (-jN) than this platform can handle requested.")); ++ O (error, NILF, _("Resetting to single job (-j1) mode.")); ++ job_slots = 1; ++ } ++ ++ + /* If we have >1 slot at this point, then we're a top-level make. + Set up the jobserver. + diff --git a/SPECS/make.spec b/SPECS/make.spec new file mode 100644 index 0000000..97dee42 --- /dev/null +++ b/SPECS/make.spec @@ -0,0 +1,105 @@ +# -*- coding: utf-8 -*- +%global __python /usr/bin/python3 +%{?scl:%{?scl_package:%scl_package make}} +Summary: A GNU tool which simplifies the build process for users +Name: %{?scl_prefix}make +Epoch: 1 +Version: 4.3 +Release: 2%{?dist} +License: GPLv3+ +URL: http://www.gnu.org/software/make/ +Source: ftp://ftp.gnu.org/gnu/make/make-%{version}.tar.gz + +%if 0%{?rhel} > 0 +# This gives the user the option of saying --with guile, but defaults to WITHOUT +%bcond_with guile +%else +# This gives the user the option of saying --without guile, but defaults to WITH +%bcond_without guile +%endif + +Patch0: make-4.3-getcwd.patch + +# Assume we don't have clock_gettime in configure, so that +# make is not linked against -lpthread (and thus does not +# limit stack to 2MB). +Patch1: make-4.0-noclock_gettime.patch + +# BZs #142691, #17374 +Patch2: make-4.3-j8k.patch + +# https://bugzilla.redhat.com/show_bug.cgi?id=1827850 +# https://savannah.gnu.org/bugs/?58232 +# Remove on next make rebase +Patch3: make-4.3-cloexec.patch + +# autoreconf +BuildRequires: make +BuildRequires: autoconf, automake, gettext-devel +BuildRequires: procps +BuildRequires: perl-interpreter +%if %{with guile} +BuildRequires: pkgconfig(guile-2.2) +%endif +BuildRequires: gcc + +%description +A GNU tool for controlling the generation of executables and other +non-source files of a program from the program's source files. Make +allows users to build and install packages without any significant +knowledge about the details of the build process. The details about +how the program should be built are provided for make in the program's +makefile. + +%package devel +Summary: Header file for externally visible definitions + +%description devel +The make-devel package contains gnumake.h. + +%prep +%autosetup -p1 -n make-%{version} + +rm -f tests/scripts/features/parallelism.orig + +%build + +%configure \ +%if %{with guile} + --with-guile +%else + --without-guile +%endif + +%make_build + +%install +%make_install +ln -sf make ${RPM_BUILD_ROOT}/%{_bindir}/gmake +ln -sf make.1 ${RPM_BUILD_ROOT}/%{_mandir}/man1/gmake.1 +rm -f ${RPM_BUILD_ROOT}/%{_infodir}/dir + +%find_lang make + +%check +echo ============TESTING=============== +/usr/bin/env LANG=C make check && true +echo ============END TESTING=========== + +%files -f make.lang +%license COPYING +%doc NEWS README AUTHORS +%{_bindir}/* +%{_mandir}/man*/* +%{_infodir}/*.info* +%{_includedir}/gnumake.h + +%files devel +%{_includedir}/gnumake.h + +%changelog +* Mon Jun 21 2021 Martin Cermak - 1:4.3-2 +- CI gating related NVR bump and rebuild + +* Thu Jun 10 2021 DJ Delorie - 1:4.3-1 +- Initial sources for DTS 11 (#1958351)