Merge pull request #4318 from wmertens/fix_python_darwin

Python on Darwin: Don't depend on glibcLocales
This commit is contained in:
Domen Kožar 2014-09-29 14:35:16 +02:00
commit 83a749aa66

View file

@ -40,6 +40,9 @@ let
# helpers # helpers
# glibcLocales doesn't build on Darwin
localePath = optionalString (! stdenv.isDarwin) "${pkgs.glibcLocales}/lib/locale/locale-archive";
callPackage = pkgs.newScope pythonPackages; callPackage = pkgs.newScope pythonPackages;
# global distutils config used by buildPythonPackage # global distutils config used by buildPythonPackage
@ -2319,7 +2322,7 @@ let
}; };
preBuild = '' preBuild = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';
@ -4030,7 +4033,7 @@ let
}; };
preBuild = '' preBuild = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';
@ -4791,7 +4794,7 @@ let
doCheck = false; doCheck = false;
preBuild = '' preBuild = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';
@ -4963,7 +4966,7 @@ let
# some files in tests dir include unicode names # some files in tests dir include unicode names
preBuild = '' preBuild = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';
@ -5006,7 +5009,7 @@ let
}; };
preCheck = '' preCheck = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';
@ -6088,7 +6091,7 @@ let
preCheck = '' preCheck = ''
export LANG="en_US.UTF-8" export LANG="en_US.UTF-8"
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
''; '';
meta = { meta = {
@ -7946,8 +7949,7 @@ let
preConfigure = '' preConfigure = ''
export LANG="en_US.UTF-8"; export LANG="en_US.UTF-8";
'' + stdenv.lib.optionalString stdenv.isLinux '' export LOCALE_ARCHIVE=${localePath}
export LOCALE_ARCHIVE="${pkgs.glibcLocales}/lib/locale/locale-archive";
''; '';
patchPhase = '' patchPhase = ''
@ -8005,7 +8007,7 @@ let
preCheck = '' preCheck = ''
export LANG="en_US.UTF-8" export LANG="en_US.UTF-8"
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
''; '';
meta = with stdenv.lib; { meta = with stdenv.lib; {
@ -8068,7 +8070,7 @@ let
preCheck = '' preCheck = ''
export LANG="en_US.UTF-8" export LANG="en_US.UTF-8"
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
''; '';
buildInputs = [ pytest py mock ]; buildInputs = [ pytest py mock ];
@ -8529,7 +8531,7 @@ let
version = "1.2.7"; version = "1.2.7";
preBuild = '' preBuild = ''
export LOCALE_ARCHIVE=${pkgs.glibcLocales}/lib/locale/locale-archive export LOCALE_ARCHIVE=${localePath}
export LC_ALL="en_US.UTF-8" export LC_ALL="en_US.UTF-8"
''; '';