summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorHarmen Stoppels <harmenstoppels@gmail.com>2023-09-11 19:45:53 +0200
committerGitHub <noreply@github.com>2023-09-11 10:45:53 -0700
commita0bd53148be23b598052b7851ca83ce35c3d7cfc (patch)
treee1165b568093dc1adaff4683b15156e2a10cc28b /var
parent3302b176fd60c4a8e09726f70667af1f3172d5b7 (diff)
downloadspack-a0bd53148be23b598052b7851ca83ce35c3d7cfc.tar.gz
spack-a0bd53148be23b598052b7851ca83ce35c3d7cfc.tar.bz2
spack-a0bd53148be23b598052b7851ca83ce35c3d7cfc.tar.xz
spack-a0bd53148be23b598052b7851ca83ce35c3d7cfc.zip
glibc: fix deps, drop pre 2.17 (#39806)
* glibc: add missing deps, drop < 2.17 Building glibc 2.17 requires linking libgcc_{s,eh}.a, which themselves depend on whatever glibc the current gcc uses for its runtime libraries. Newer gcc depends on gnu extensions of libdl it seems, so that means you simply cannot build old glibc with gcc-using-new-glibc. The relevant fix in glibc is this commit: commit 95f5a9a866695da4e038aa4e6ccbbfd5d9cf63b7 Author: Joseph Myers <joseph@codesourcery.com> Date: Tue Jul 3 19:14:59 2012 +0000 Avoid use of libgcc_s and libgcc_eh when building glibc. See also references to that commit in the glibc mailing list. * update the gmake bound * add --without-selinux
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/gawk/package.py1
-rw-r--r--var/spack/repos/builtin/packages/glibc/32cf406.patch21
-rw-r--r--var/spack/repos/builtin/packages/glibc/4a531bb.patch123
-rw-r--r--var/spack/repos/builtin/packages/glibc/7c8a673.patch21
-rw-r--r--var/spack/repos/builtin/packages/glibc/fb21f89.patch13
-rw-r--r--var/spack/repos/builtin/packages/glibc/package.py61
-rw-r--r--var/spack/repos/builtin/packages/glibc/texi.patch15
7 files changed, 23 insertions, 232 deletions
diff --git a/var/spack/repos/builtin/packages/gawk/package.py b/var/spack/repos/builtin/packages/gawk/package.py
index 56455d67f7..46f5034ad4 100644
--- a/var/spack/repos/builtin/packages/gawk/package.py
+++ b/var/spack/repos/builtin/packages/gawk/package.py
@@ -28,6 +28,7 @@ class Gawk(AutotoolsPackage, GNUMirrorPackage):
tags = ["build-tools", "core-packages"]
+ version("5.2.2", sha256="3c1fce1446b4cbee1cd273bd7ec64bc87d89f61537471cd3e05e33a965a250e9")
version("5.2.1", sha256="673553b91f9e18cc5792ed51075df8d510c9040f550a6f74e09c9add243a7e4f")
version("5.1.1", sha256="d87629386e894bbea11a5e00515fc909dc9b7249529dad9e6a3a2c77085f7ea2")
version("5.1.0", sha256="cf5fea4ac5665fd5171af4716baab2effc76306a9572988d5ba1078f196382bd")
diff --git a/var/spack/repos/builtin/packages/glibc/32cf406.patch b/var/spack/repos/builtin/packages/glibc/32cf406.patch
deleted file mode 100644
index 223301de39..0000000000
--- a/var/spack/repos/builtin/packages/glibc/32cf406.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From 32cf40699346d37fabfa887bbd95e95004799ae1 Mon Sep 17 00:00:00 2001
-From: Andreas Schwab <schwab@redhat.com>
-Date: Mon, 6 Sep 2010 14:55:59 +0200
-Subject: [PATCH] Don't mix pattern rules with normal rules
-
-diff --git a/manual/Makefile b/manual/Makefile
-index c5866eb9def..b1f5fa73e5e 100644
---- a/manual/Makefile
-+++ b/manual/Makefile
-@@ -232,7 +232,10 @@ ifdef objpfx
- .PHONY: stubs
- stubs: $(objpfx)stubs
- endif
--$(objpfx)stubs ../po/manual.pot $(objpfx)stamp%:
-+$(objpfx)stubs ../po/manual.pot:
-+ $(make-target-directory)
-+ touch $@
-+$(objpfx)stamp%:
- $(make-target-directory)
- touch $@
-
diff --git a/var/spack/repos/builtin/packages/glibc/4a531bb.patch b/var/spack/repos/builtin/packages/glibc/4a531bb.patch
deleted file mode 100644
index ca4566df5a..0000000000
--- a/var/spack/repos/builtin/packages/glibc/4a531bb.patch
+++ /dev/null
@@ -1,123 +0,0 @@
-commit 4a531bb0b3b582cb693de9f76d2d97d970f9a5d5
-Author: H.J. Lu <hongjiu.lu@intel.com>
-Date: Fri Dec 24 20:14:37 2010 -0500
-
- Remove `.ctors' and `.dtors' output sections
-
-diff --git a/config.h.in b/config.h.in
-index 18bf01a38c..9e797eb5b7 100644
---- a/config.h.in
-+++ b/config.h.in
-@@ -201,6 +201,9 @@
- /* Define if multi-arch DSOs should be generated. */
- #undef USE_MULTIARCH
-
-+/* Define if `.ctors' and `.dtors' sections shouldn't be used. */
-+#define NO_CTORS_DTORS_SECTIONS
-+
- /*
- ^L */
-
-diff --git a/elf/sofini.c b/elf/sofini.c
-index 5e06f0ca92..13e74b7903 100644
---- a/elf/sofini.c
-+++ b/elf/sofini.c
-@@ -1,12 +1,14 @@
- /* Finalizer module for ELF shared C library. This provides terminating
- null pointer words in the `.ctors' and `.dtors' sections. */
-
-+#ifndef NO_CTORS_DTORS_SECTIONS
- static void (*const __CTOR_END__[1]) (void)
- __attribute__ ((used, section (".ctors")))
- = { 0 };
- static void (*const __DTOR_END__[1]) (void)
- __attribute__ ((used, section (".dtors")))
- = { 0 };
-+#endif
-
- /* Terminate the frame unwind info section with a 4byte 0 as a sentinel;
- this would be the 'length' field in a real FDE. */
-diff --git a/elf/soinit.c b/elf/soinit.c
-index 6fecbb5674..1db676af01 100644
---- a/elf/soinit.c
-+++ b/elf/soinit.c
-@@ -3,6 +3,7 @@
- the `.ctors' and `.dtors' sections so the lists are terminated, and
- calling those lists of functions. */
-
-+#ifndef NO_CTORS_DTORS_SECTIONS
- #include <libc-internal.h>
- #include <stdlib.h>
-
-@@ -40,3 +41,4 @@ __libc_fini (void)
-
- void (*_fini_ptr) (void) __attribute__ ((section (".fini_array")))
- = &__libc_fini;
-+#endif
-diff --git a/sysdeps/i386/init-first.c b/sysdeps/i386/init-first.c
-index c6355a8b7b..2af042fe4b 100644
---- a/sysdeps/i386/init-first.c
-+++ b/sysdeps/i386/init-first.c
-@@ -59,7 +59,9 @@ _init (int argc, ...)
- {
- init (&argc);
-
-+#ifndef NO_CTORS_DTORS_SECTIONS
- __libc_global_ctors ();
-+#endif
- }
- #endif
-
-diff --git a/sysdeps/mach/hurd/i386/init-first.c b/sysdeps/mach/hurd/i386/init-first.c
-index f9a7a58deb..60823bd789 100644
---- a/sysdeps/mach/hurd/i386/init-first.c
-+++ b/sysdeps/mach/hurd/i386/init-first.c
-@@ -92,7 +92,7 @@ posixland_init (int argc, char **argv, char **envp)
- __getopt_clean_environment (envp);
- #endif
-
--#ifdef SHARED
-+#if defined SHARED && !defined NO_CTORS_DTORS_SECTIONS
- __libc_global_ctors ();
- #endif
- }
-diff --git a/sysdeps/mach/hurd/powerpc/init-first.c b/sysdeps/mach/hurd/powerpc/init-first.c
-index 20fa1d4f12..21b5054b0a 100644
---- a/sysdeps/mach/hurd/powerpc/init-first.c
-+++ b/sysdeps/mach/hurd/powerpc/init-first.c
-@@ -82,7 +82,7 @@ posixland_init (int argc, char **argv, char **envp)
- __getopt_clean_environment (__environ);
- #endif
-
--#ifdef SHARED
-+#if defined SHARED && !defined NO_CTORS_DTORS_SECTIONS
- __libc_global_ctors ();
- #endif
- }
-diff --git a/sysdeps/sh/init-first.c b/sysdeps/sh/init-first.c
-index d816625ef4..1f3a821fea 100644
---- a/sysdeps/sh/init-first.c
-+++ b/sysdeps/sh/init-first.c
-@@ -59,7 +59,9 @@ _init (int argc, ...)
- {
- init (&argc);
-
-+#ifndef NO_CTORS_DTORS_SECTIONS
- __libc_global_ctors ();
-+#endif
- }
- #endif
-
-diff --git a/sysdeps/unix/sysv/linux/init-first.c b/sysdeps/unix/sysv/linux/init-first.c
-index 7b2333d4bf..a60212f4ed 100644
---- a/sysdeps/unix/sysv/linux/init-first.c
-+++ b/sysdeps/unix/sysv/linux/init-first.c
-@@ -93,7 +93,7 @@ _init (int argc, char **argv, char **envp)
- __getopt_clean_environment (envp);
- #endif
-
--#ifdef SHARED
-+#if defined SHARED && !defined NO_CTORS_DTORS_SECTIONS
- __libc_global_ctors ();
- #endif
- }
diff --git a/var/spack/repos/builtin/packages/glibc/7c8a673.patch b/var/spack/repos/builtin/packages/glibc/7c8a673.patch
deleted file mode 100644
index 0903ebab76..0000000000
--- a/var/spack/repos/builtin/packages/glibc/7c8a673.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit 7c8a67320e26b8c11108bf0a3410d3aef9cf3486
-Author: Ulrich Drepper <drepper@redhat.com>
-Date: Sat Jan 31 00:21:15 2009 +0000
-
- * elf/Makefile (ld.so): Adjust the sed script to insert _begin in to
-
- newer linker scripts.
-
-diff --git a/elf/Makefile b/elf/Makefile
-index 8079fe9f96..e44ff1d382 100644
---- a/elf/Makefile
-+++ b/elf/Makefile
-@@ -304,7 +304,7 @@ $(objpfx)ld.so: $(objpfx)librtld.os $(ld-map)
- $(LDFLAGS-rtld) -Wl,-z,defs -Wl,--verbose 2>&1 | \
- LC_ALL=C \
- sed -e '/^=========/,/^=========/!d;/^=========/d' \
-- -e 's/\. = 0 + SIZEOF_HEADERS;/& _begin = . - SIZEOF_HEADERS;/' \
-+ -e 's/\. = .* + SIZEOF_HEADERS;/& _begin = . - SIZEOF_HEADERS;/' \
- > $@.lds
- $(LINK.o) -nostdlib -nostartfiles -shared -o $@ \
- $(LDFLAGS-rtld) -Wl,-z,defs $(z-now-$(bind-now)) \
diff --git a/var/spack/repos/builtin/packages/glibc/fb21f89.patch b/var/spack/repos/builtin/packages/glibc/fb21f89.patch
deleted file mode 100644
index 14f05fdb3f..0000000000
--- a/var/spack/repos/builtin/packages/glibc/fb21f89.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff --git a/sunrpc/rpc_clntout.c b/sunrpc/rpc_clntout.c
-index ec040c775e2..ce4d2a4c953 100644
---- a/sunrpc/rpc_clntout.c
-+++ b/sunrpc/rpc_clntout.c
-@@ -31,7 +31,7 @@
- */
- #include <stdio.h>
- #include <string.h>
--#include <rpc/types.h>
-+#include "rpc/types.h"
- #include "rpc_parse.h"
- #include "rpc_util.h"
- #include "proto.h"
diff --git a/var/spack/repos/builtin/packages/glibc/package.py b/var/spack/repos/builtin/packages/glibc/package.py
index b0566f0427..38c568c9e4 100644
--- a/var/spack/repos/builtin/packages/glibc/package.py
+++ b/var/spack/repos/builtin/packages/glibc/package.py
@@ -44,17 +44,11 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage):
version("2.19", sha256="18ad6db70724699d264add80b1f813630d0141cf3a3558b4e1a7c15f6beac796")
version("2.18", sha256="c8e727b5feef883184241a4767725ec280c0288794bc5cd4432497370db47734")
version("2.17", sha256="a3b2086d5414e602b4b3d5a8792213feb3be664ffc1efe783a829818d3fca37a")
- version("2.16.0", sha256="a75be51658cc1cfb6324ec6dbdbed416526c44c14814823129f0fcc74c279f6e")
- version("2.15", sha256="da6b95d14b722539c2ec02e7ae1221318dba3d27f19c098a882ffa71bb429c20")
- version("2.14.1", sha256="f80c40897df49c463a6d5a45f734acbfe1bf42ef209a92a5c217aeb383631bdb")
- version("2.13", sha256="bd90d6119bcc2898befd6e1bbb2cb1ed3bb1c2997d5eaa6fdbca4ee16191a906")
- version("2.12.2", sha256="6b7392a7b339a3f2db6e4bc8d5418cf29116d9e7e36b313e845cb65e449c5346")
- version("2.11.3", sha256="ddc3210f4029991f5142fda7f269f9bfb197917e5d9445ba2d90d31f74cc2765")
- version("2.10.1", sha256="cd9743db33389e7b4eb2942a4f365d12fc015f115113b230152280c43ccc7e3f")
- version("2.9", sha256="e0210dec2a4ca0a03d8ee26e2a4ebccc915d99f4cdb1489ff0f9f4ce7bda3e30")
- version("2.8", sha256="a5b91339355a7bbafc5f44b524556f7f25de83dd56f2c00ef9240dabd6865663")
- version("2.7", sha256="f5ef515cb70f8d4cfcee0b3aac05b73def60d897bdb7a71f4356782febfe415a")
- version("2.6.1", sha256="6be7639ccad715d25eef560ce9d1637ef206fb9a162714f6ab8167fc0d971cae")
+
+ # Spack commit 29aa7117f42f758bc537e03e4bedf66ced0accfa has older versions
+ # of glibc, but they are removed, because glibc < 2.17 links against
+ # libgcc_s and libgcc_eh, see glibc commit "Avoid use of libgcc_s and
+ # libgcc_eh when building glibc." 95f5a9a866695da4e038aa4e6ccbbfd5d9cf63b7
# Fix for newer GCC, related to -fno-common
patch("locs.patch", when="@2.23:2.25")
@@ -63,21 +57,9 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage):
# _obstack_compat symbol is not initialized
patch("39b1f61.patch", when="@:2.17")
- # docs: install fails with "unknown command hsep / vsep"
- patch("texi.patch", when="@2.16.0")
-
- # rpc/types.h include issue, should be from local version, not system.
- patch("fb21f89.patch", when="@:2.16")
-
- # Use init_array (modified commit 4a531bb to unconditionally define
- # NO_CTORS_DTORS_SECTIONS)
- patch("4a531bb.patch", when="@:2.12")
-
- # make: mixed implicit and static pattern rules (trivial issue in docs)
- patch("32cf406.patch", when="@:2.10")
-
- # linker flag output regex
- patch("7c8a673.patch", when="@:2.9")
+ def setup_build_environment(self, env):
+ if self.spec.satisfies("@:2.21"):
+ env.append_flags("LDFLAGS", "-no-pie")
def patch(self):
# Support gmake >= 4
@@ -88,15 +70,13 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage):
string=True,
)
- # Suport gcc >= 5
+ # Support gcc >= 10
filter_file(
- "3.4* | 4.[0-9]* )",
- "3.4* | 4.[0-9]* | [5-9].* | [1-9][0-9]*)",
+ "4.[3-9].* | 4.[1-9][0-9].* | [5-9].* )",
+ "4.[3-9].* | 4.[1-9][0-9].* | [5-9].* | [1-9][0-9]*)",
"configure",
string=True,
)
-
- # Support gcc >= 10
filter_file(
"4.[4-9].* | 4.[1-9][0-9].* | [5-9].* )",
"4.[4-9].* | 4.[1-9][0-9].* | [5-9].* | [1-9][0-9]*)",
@@ -104,18 +84,20 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage):
string=True,
)
- # Support binutils
- filter_file(
- "2.1[3-9]*)",
- "2.1[3-9]*|2.1[0-9][0-9]*|2.[2-9][0-9]*|[3-9].*|[1-9][0-9]*)",
- "configure",
- string=True,
- )
-
depends_on("bison", type="build")
depends_on("texinfo", type="build")
depends_on("gettext", type="build")
depends_on("perl", type="build")
+ depends_on("gawk", type="build")
+ depends_on("sed", type="build")
+ depends_on("gmake", type="build")
+
+ # See 2d7ed98add14f75041499ac189696c9bd3d757fe
+ depends_on("gmake@:4.3", type="build", when="@:2.36")
+
+ # From 2.29: generates locale/C-translit.h
+ # before that it's a test dependency.
+ depends_on("python@3.4:", type="build", when="@2.29:")
depends_on("linux-headers")
@@ -128,6 +110,7 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage):
return [
"--enable-kernel=4.4.1",
"--with-headers={}".format(self.spec["linux-headers"].prefix.include),
+ "--without-selinux",
]
def build(self, spec, prefix):
diff --git a/var/spack/repos/builtin/packages/glibc/texi.patch b/var/spack/repos/builtin/packages/glibc/texi.patch
deleted file mode 100644
index 1bffc5db04..0000000000
--- a/var/spack/repos/builtin/packages/glibc/texi.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-diff --git a/manual/stdio.texi b/manual/stdio.texi
-index be769a5..7b436f0 100644
---- a/manual/stdio.texi
-+++ b/manual/stdio.texi
-@@ -3137,7 +3137,7 @@ The postfix tag corresponds to bytes, kilobytes, megabytes, gigabytes,
- etc. The full table is:
-
- @ifinfo
--@multitable @hsep @vsep {' '} {2^10 (1024)} {zetta} {Upper} {10^24 (1000)}
-+@multitable {' '} {2^10 (1024)} {zetta} {Upper} {10^24 (1000)}
- @item low @tab Multiplier @tab From @tab Upper @tab Multiplier
- @item ' ' @tab 1 @tab @tab ' ' @tab 1
- @item k @tab 2^10 (1024) @tab kilo @tab K @tab 10^3 (1000)
---
-1.8.0.1