about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/glibc
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2021-07-23 09:26:00 +0000
committerAlyssa Ross <hi@alyssa.is>2021-07-23 09:26:00 +0000
commitab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d (patch)
tree504b28a058661f6c1cbb7d3f580020e50367ca7f /nixpkgs/pkgs/development/libraries/glibc
parent55cc63c079f49e81d695a25bc2f5b3902f2bd290 (diff)
parentb09661d41fb93562fd53f31574dbf781b130ac44 (diff)
downloadnixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar.gz
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar.bz2
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar.lz
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar.xz
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.tar.zst
nixlib-ab63e0bb8dcf2b1bf8d4a26ed360af777b8f241d.zip
Merge commit 'b09661d41fb93562fd53f31574dbf781b130ac44'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/glibc')
-rw-r--r--nixpkgs/pkgs/development/libraries/glibc/2.32-master.patch.gzbin66850 -> 0 bytes
-rw-r--r--nixpkgs/pkgs/development/libraries/glibc/2.33-master.patch.gzbin0 -> 56984 bytes
-rw-r--r--nixpkgs/pkgs/development/libraries/glibc/common.nix23
-rw-r--r--nixpkgs/pkgs/development/libraries/glibc/dont-use-system-ld-so-cache.patch60
4 files changed, 53 insertions, 30 deletions
diff --git a/nixpkgs/pkgs/development/libraries/glibc/2.32-master.patch.gz b/nixpkgs/pkgs/development/libraries/glibc/2.32-master.patch.gz
deleted file mode 100644
index 8ea998b5bea2..000000000000
--- a/nixpkgs/pkgs/development/libraries/glibc/2.32-master.patch.gz
+++ /dev/null
Binary files differdiff --git a/nixpkgs/pkgs/development/libraries/glibc/2.33-master.patch.gz b/nixpkgs/pkgs/development/libraries/glibc/2.33-master.patch.gz
new file mode 100644
index 000000000000..59230761cd43
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/glibc/2.33-master.patch.gz
Binary files differdiff --git a/nixpkgs/pkgs/development/libraries/glibc/common.nix b/nixpkgs/pkgs/development/libraries/glibc/common.nix
index 93f8f7a8641d..e651a8effac9 100644
--- a/nixpkgs/pkgs/development/libraries/glibc/common.nix
+++ b/nixpkgs/pkgs/development/libraries/glibc/common.nix
@@ -41,9 +41,9 @@
 } @ args:
 
 let
-  version = "2.32";
-  patchSuffix = "-48";
-  sha256 = "0di848ibffrnwq7g2dvgqrnn4xqhj3h96csn69q4da51ymafl9qn";
+  version = "2.33";
+  patchSuffix = "-47";
+  sha256 = "sha256-LiVWAA4QXb1X8Layoy/yzxc73k8Nhd/8z9i35RoGd/8=";
 in
 
 assert withLinuxHeaders -> linuxHeaders != null;
@@ -60,14 +60,14 @@ stdenv.mkDerivation ({
   patches =
     [
       /* No tarballs for stable upstream branch, only https://sourceware.org/git/glibc.git and using git would complicate bootstrapping.
-          $ git fetch --all -p && git checkout origin/release/2.32/master && git describe
-          glibc-2.32-48-g16949aeaa0
-          $ git show --minimal --reverse glibc-2.32.. | gzip -9n --rsyncable - > 2.32-master.patch.gz
+          $ git fetch --all -p && git checkout origin/release/2.33/master && git describe
+          glibc-2.33-47-gb5711025bc
+          $ git show --minimal --reverse glibc-2.33.. | gzip -9n --rsyncable - > 2.33-master.patch.gz
 
          To compare the archive contents zdiff can be used.
-          $ zdiff -u 2.32-master.patch.gz ../nixpkgs/pkgs/development/libraries/glibc/2.32-master.patch.gz
+          $ zdiff -u 2.33-master.patch.gz ../nixpkgs/pkgs/development/libraries/glibc/2.33-master.patch.gz
        */
-      ./2.32-master.patch.gz
+      ./2.33-master.patch.gz
 
       /* Allow NixOS and Nix to handle the locale-archive. */
       ./nix-locale-archive.patch
@@ -153,10 +153,15 @@ stdenv.mkDerivation ({
       "--enable-add-ons"
       "--sysconfdir=/etc"
       "--enable-stackguard-randomization"
-      "--enable-static-pie"
       "--enable-bind-now"
       (lib.withFeatureAs withLinuxHeaders "headers" "${linuxHeaders}/include")
       (lib.enableFeature profilingLibraries "profile")
+    ] ++ lib.optionals (stdenv.hostPlatform.isx86_64 || stdenv.hostPlatform.isi686 || stdenv.hostPlatform.isAarch64) [
+      # This feature is currently supported on
+      # i386, x86_64 and x32 with binutils 2.29 or later,
+      # and on aarch64 with binutils 2.30 or later.
+      # https://sourceware.org/glibc/wiki/PortStatus
+      "--enable-static-pie"
     ] ++ lib.optionals withLinuxHeaders [
       "--enable-kernel=3.2.0" # can't get below with glibc >= 2.26
     ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
diff --git a/nixpkgs/pkgs/development/libraries/glibc/dont-use-system-ld-so-cache.patch b/nixpkgs/pkgs/development/libraries/glibc/dont-use-system-ld-so-cache.patch
index f84b1049adf8..0e0315aca270 100644
--- a/nixpkgs/pkgs/development/libraries/glibc/dont-use-system-ld-so-cache.patch
+++ b/nixpkgs/pkgs/development/libraries/glibc/dont-use-system-ld-so-cache.patch
@@ -1,19 +1,8 @@
-diff -Naur glibc-2.27-orig/elf/ldconfig.c glibc-2.27/elf/ldconfig.c
---- glibc-2.27-orig/elf/ldconfig.c	2018-02-01 11:17:18.000000000 -0500
-+++ glibc-2.27/elf/ldconfig.c	2018-02-17 22:43:17.232175182 -0500
-@@ -51,7 +51,7 @@
- #endif
- 
- #ifndef LD_SO_CONF
--# define LD_SO_CONF SYSCONFDIR "/ld.so.conf"
-+# define LD_SO_CONF PREFIX "/etc/ld.so.conf"
- #endif
- 
- /* Get libc version number.  */
-diff -Naur glibc-2.27-orig/elf/Makefile glibc-2.27/elf/Makefile
---- glibc-2.27-orig/elf/Makefile	2018-02-01 11:17:18.000000000 -0500
-+++ glibc-2.27/elf/Makefile	2018-02-17 22:44:50.334006750 -0500
-@@ -559,13 +559,13 @@
+diff --git a/elf/Makefile b/elf/Makefile
+index 5d666b1b..a5017e9c 100644
+--- a/elf/Makefile
++++ b/elf/Makefile
+@@ -669,14 +669,14 @@ $(objpfx)sln: $(sln-modules:%=$(objpfx)%.o)
  
  $(objpfx)ldconfig: $(ldconfig-modules:%=$(objpfx)%.o)
  
@@ -26,16 +15,45 @@ diff -Naur glibc-2.27-orig/elf/Makefile glibc-2.27/elf/Makefile
 -CFLAGS-dl-cache.c += $(SYSCONF-FLAGS)
 -CFLAGS-cache.c += $(SYSCONF-FLAGS)
 -CFLAGS-rtld.c += $(SYSCONF-FLAGS)
+-CFLAGS-dl-usage.c += $(SYSCONF-FLAGS) \
 +CFLAGS-dl-cache.c += $(PREFIX-FLAGS)
 +CFLAGS-cache.c += $(PREFIX-FLAGS)
 +CFLAGS-rtld.c += $(PREFIX-FLAGS)
++CFLAGS-dl-usage.c += $(PREFIX-FLAGS) \
+   -D'RTLD="$(rtlddir)/$(rtld-installed-name)"'
  
  cpp-srcs-left := $(all-rtld-routines:=.os)
- lib := rtld
-diff -Naur glibc-2.27-orig/sysdeps/generic/dl-cache.h glibc-2.27/sysdeps/generic/dl-cache.h
---- glibc-2.27-orig/sysdeps/generic/dl-cache.h	2018-02-01 11:17:18.000000000 -0500
-+++ glibc-2.27/sysdeps/generic/dl-cache.h	2018-02-17 22:45:20.471598816 -0500
-@@ -28,7 +28,7 @@
+diff --git a/elf/dl-diagnostics.c b/elf/dl-diagnostics.c
+index bef224b3..8e166b12 100644
+--- a/elf/dl-diagnostics.c
++++ b/elf/dl-diagnostics.c
+@@ -205,7 +205,7 @@ print_paths (void)
+ {
+   _dl_diagnostics_print_labeled_string ("path.prefix", PREFIX);
+   _dl_diagnostics_print_labeled_string ("path.rtld", RTLD);
+-  _dl_diagnostics_print_labeled_string ("path.sysconfdir", SYSCONFDIR);
++  _dl_diagnostics_print_labeled_string ("path.sysconfdir", PREFIX "/etc");
+
+   unsigned int index = 0;
+   static const char *system_dirs = SYSTEM_DIRS "\0";
+diff --git a/elf/ldconfig.c b/elf/ldconfig.c
+index 28ed637a..6f07b79a 100644
+--- a/elf/ldconfig.c
++++ b/elf/ldconfig.c
+@@ -57,7 +57,7 @@
+ #define TLS_HWCAP_BIT 63
+ 
+ #ifndef LD_SO_CONF
+-# define LD_SO_CONF SYSCONFDIR "/ld.so.conf"
++# define LD_SO_CONF PREFIX "/etc/ld.so.conf"
+ #endif
+ 
+ /* Get libc version number.  */
+diff --git a/sysdeps/generic/dl-cache.h b/sysdeps/generic/dl-cache.h
+index 964d50a4..2224d651 100644
+--- a/sysdeps/generic/dl-cache.h
++++ b/sysdeps/generic/dl-cache.h
+@@ -35,7 +35,7 @@
  #endif
  
  #ifndef LD_SO_CACHE