Author: ludo
Date: Fri Feb 17 22:12:40 2012
New Revision: 32374
URL: https://nixos.org/websvn/nix/?rev=32374&sc=1
Log:
GNU libc: Backport Hurd-related changes from glibc 2.12 in trunk.
Modified:
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/common.nix
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/default.nix
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/common.nix
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/default.nix
Modified:
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/common.nix
==============================================================================
---
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/common.nix
Fri Feb 17 22:02:37 2012 (r32373)
+++
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/common.nix
Fri Feb 17 22:12:40 2012 (r32374)
@@ -5,13 +5,14 @@
{ name, fetchurl, stdenv, installLocales ? false
, gccCross ? null, kernelHeaders ? null
-, machHeaders ? null, hurdHeaders ? null, mig ? null, fetchgit ? null
+, machHeaders ? null, hurdHeaders ? null, libpthreadHeaders ? null
+, mig ? null, fetchgit ? null
, profilingLibraries ? false, meta
, preConfigure ? "", ... }@args :
let
# For GNU/Hurd, see below.
- version = if hurdHeaders != null then "20100512" else "2.13";
+ version = if hurdHeaders != null then "20111025" else "2.13";
needsPortsNative = stdenv.isMips || stdenv.isArm;
needsPortsCross = cross.arch == "mips" || cross.arch == "arm";
@@ -30,6 +31,7 @@
assert (mig != null) -> (machHeaders != null);
assert (machHeaders != null) -> (hurdHeaders != null);
+assert (hurdHeaders != null) -> (libpthreadHeaders != null);
assert (hurdHeaders != null) -> (fetchgit != null);
stdenv.mkDerivation ({
@@ -146,8 +148,8 @@
# maintained by the Hurd folks, `tschwinge/Roger_Whittaker' branch.
# See <http://www.gnu.org/software/hurd/source_repositories/glibc.html>.
url = "git://git.sv.gnu.org/hurd/glibc.git";
- sha256 =
"f3590a54a9d897d121f91113949edbaaf3e30cdeacbb8d0a44de7b6564f6643e";
- rev = "df4c3faf0ccc848b5a8086c222bdb42679a9798f";
+ sha256 =
"3fb3dd7030a4b6d3e144fa94c32a0c4f46f17f94e2dfbc6bef41cfc3198725ca";
+ rev = "d740cf9d201dc9ecb0335b0a585828dea9cce793";
}
else fetchurl {
url = "mirror://gnu/glibc/glibc-${version}.tar.bz2";
@@ -203,11 +205,15 @@
then {
# Work around the fact that the configure snippet that looks for
# <hurd/version.h> does not honor `--with-headers=$sysheaders' and that
- # glibc expects both Mach and Hurd headers to be in the same place.
- CPATH = "${hurdHeaders}/include:${machHeaders}/include";
+ # glibc expects Mach, Hurd, and pthread headers to be in the same place.
+ CPATH =
"${hurdHeaders}/include:${machHeaders}/include:${libpthreadHeaders}/include";
# `fetchgit' is a function and thus should not be passed to the
# `derivation' primitive.
fetchgit = null;
+
+ # Install NSS stuff in the right place.
+ # XXX: This will be needed for all new glibcs and isn't Hurd-specific.
+ makeFlags = ''vardbdir="$out/var/db"'';
}
else { }))
Modified:
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/default.nix
==============================================================================
---
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/default.nix
Fri Feb 17 22:02:37 2012 (r32373)
+++
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.13/default.nix
Fri Feb 17 22:12:40 2012 (r32374)
@@ -1,8 +1,10 @@
{ stdenv, fetchurl, kernelHeaders
-, machHeaders ? null, hurdHeaders ? null, mig ? null, fetchgit ? null
+, machHeaders ? null, hurdHeaders ? null, libpthreadHeaders ? null
+, mig ? null, fetchgit ? null
, installLocales ? true
, profilingLibraries ? false
, gccCross ? null
+, debugSymbols ? false
}:
assert stdenv.gcc.gcc != null;
@@ -12,7 +14,7 @@
cross = if gccCross != null then gccCross.target else null;
in
build cross ({
- name = "glibc";
+ name = "glibc${if debugSymbols then "-debug" else ""}";
inherit fetchurl stdenv kernelHeaders installLocales profilingLibraries
gccCross;
@@ -38,11 +40,23 @@
//
+ (if debugSymbols
+ then {
+ # Build with debugging symbols, but leave optimizations on and don't
+ # attempt to keep the build tree.
+ dontStrip = true;
+ dontCrossStrip = true;
+ NIX_STRIP_DEBUG = 0;
+ }
+ else {})
+
+ //
+
(if hurdHeaders != null
then rec {
- inherit machHeaders hurdHeaders mig fetchgit;
+ inherit machHeaders hurdHeaders libpthreadHeaders mig fetchgit;
- propagatedBuildInputs = [ machHeaders hurdHeaders ];
+ propagatedBuildInputs = [ machHeaders hurdHeaders libpthreadHeaders ];
passthru = {
# When building GCC itself `propagatedBuildInputs' above is not
Modified:
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/common.nix
==============================================================================
---
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/common.nix
Fri Feb 17 22:02:37 2012 (r32373)
+++
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/common.nix
Fri Feb 17 22:12:40 2012 (r32374)
@@ -5,13 +5,14 @@
{ name, fetchurl, stdenv, installLocales ? false
, gccCross ? null, kernelHeaders ? null
-, machHeaders ? null, hurdHeaders ? null, mig ? null, fetchgit ? null
+, machHeaders ? null, hurdHeaders ? null, libpthreadHeaders ? null
+, mig ? null, fetchgit ? null
, profilingLibraries ? false, meta
, preConfigure ? "", ... }@args :
let
# For GNU/Hurd, see below.
- version = if hurdHeaders != null then "20100512" else "2.14.1";
+ version = if hurdHeaders != null then "20111025" else "2.14.1";
needsPortsNative = stdenv.isMips || stdenv.isArm;
needsPortsCross = cross.arch == "mips" || cross.arch == "arm";
@@ -30,6 +31,7 @@
assert (mig != null) -> (machHeaders != null);
assert (machHeaders != null) -> (hurdHeaders != null);
+assert (hurdHeaders != null) -> (libpthreadHeaders != null);
assert (hurdHeaders != null) -> (fetchgit != null);
stdenv.mkDerivation ({
@@ -146,8 +148,8 @@
# maintained by the Hurd folks, `tschwinge/Roger_Whittaker' branch.
# See <http://www.gnu.org/software/hurd/source_repositories/glibc.html>.
url = "git://git.sv.gnu.org/hurd/glibc.git";
- sha256 =
"f3590a54a9d897d121f91113949edbaaf3e30cdeacbb8d0a44de7b6564f6643e";
- rev = "df4c3faf0ccc848b5a8086c222bdb42679a9798f";
+ sha256 =
"3fb3dd7030a4b6d3e144fa94c32a0c4f46f17f94e2dfbc6bef41cfc3198725ca";
+ rev = "d740cf9d201dc9ecb0335b0a585828dea9cce793";
}
else fetchurl {
url = "mirror://gnu/glibc/glibc-${version}.tar.bz2";
@@ -203,11 +205,15 @@
then {
# Work around the fact that the configure snippet that looks for
# <hurd/version.h> does not honor `--with-headers=$sysheaders' and that
- # glibc expects both Mach and Hurd headers to be in the same place.
- CPATH = "${hurdHeaders}/include:${machHeaders}/include";
+ # glibc expects Mach, Hurd, and pthread headers to be in the same place.
+ CPATH =
"${hurdHeaders}/include:${machHeaders}/include:${libpthreadHeaders}/include";
# `fetchgit' is a function and thus should not be passed to the
# `derivation' primitive.
fetchgit = null;
+
+ # Install NSS stuff in the right place.
+ # XXX: This will be needed for all new glibcs and isn't Hurd-specific.
+ makeFlags = ''vardbdir="$out/var/db"'';
}
else { }))
Modified:
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/default.nix
==============================================================================
---
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/default.nix
Fri Feb 17 22:02:37 2012 (r32373)
+++
nixpkgs/branches/stdenv-updates/pkgs/development/libraries/glibc/2.14/default.nix
Fri Feb 17 22:12:40 2012 (r32374)
@@ -1,8 +1,10 @@
{ stdenv, fetchurl, kernelHeaders
-, machHeaders ? null, hurdHeaders ? null, mig ? null, fetchgit ? null
+, machHeaders ? null, hurdHeaders ? null, libpthreadHeaders ? null
+, mig ? null, fetchgit ? null
, installLocales ? true
, profilingLibraries ? false
, gccCross ? null
+, debugSymbols ? false
}:
assert stdenv.gcc.gcc != null;
@@ -12,7 +14,7 @@
cross = if gccCross != null then gccCross.target else null;
in
build cross ({
- name = "glibc";
+ name = "glibc${if debugSymbols then "-debug" else ""}";
inherit fetchurl stdenv kernelHeaders installLocales profilingLibraries
gccCross;
@@ -38,11 +40,23 @@
//
+ (if debugSymbols
+ then {
+ # Build with debugging symbols, but leave optimizations on and don't
+ # attempt to keep the build tree.
+ dontStrip = true;
+ dontCrossStrip = true;
+ NIX_STRIP_DEBUG = 0;
+ }
+ else {})
+
+ //
+
(if hurdHeaders != null
then rec {
- inherit machHeaders hurdHeaders mig fetchgit;
+ inherit machHeaders hurdHeaders libpthreadHeaders mig fetchgit;
- propagatedBuildInputs = [ machHeaders hurdHeaders ];
+ propagatedBuildInputs = [ machHeaders hurdHeaders libpthreadHeaders ];
passthru = {
# When building GCC itself `propagatedBuildInputs' above is not
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits