python2: Pass configureFlags to modules as well.
Fixes regression from 086e801d51
.
The switch tu UCS-4 only happened for the main Python interpreter and
libraries, but the extension modules were using the same source but
without any configureFlags, so the extensions still referred to UCS-2
symbols.
Tested module builds of Python 2.7 and all modules except crypto fail.
Also tested against sqlite3 module of Python 2.6, although for other
modules there still seems to be an unrelated build failure with Tcl/Tk
libraries, so we might need to fix that later.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
parent
55e66db0fa
commit
a7028d3d07
|
@ -46,6 +46,8 @@ let
|
|||
touch $out/include/python${majorVersion}/pyconfig.h
|
||||
'';
|
||||
|
||||
configureFlags = "--enable-shared --with-threads --enable-unicode=ucs4";
|
||||
|
||||
buildInputs =
|
||||
optional (stdenv ? cc && stdenv.cc.libc != null) stdenv.cc.libc ++
|
||||
[ bzip2 openssl ]++ optionals includeModules [ db openssl ncurses gdbm readline x11 tcl tk sqlite ]
|
||||
|
@ -58,13 +60,12 @@ let
|
|||
name = "python${if includeModules then "" else "-minimal"}-${version}";
|
||||
pythonVersion = majorVersion;
|
||||
|
||||
inherit majorVersion version src patches buildInputs preConfigure;
|
||||
inherit majorVersion version src patches buildInputs preConfigure
|
||||
configureFlags;
|
||||
|
||||
C_INCLUDE_PATH = concatStringsSep ":" (map (p: "${p}/include") buildInputs);
|
||||
LIBRARY_PATH = concatStringsSep ":" (map (p: "${p}/lib") buildInputs);
|
||||
|
||||
configureFlags = "--enable-shared --with-threads --enable-unicode=ucs4";
|
||||
|
||||
NIX_CFLAGS_COMPILE = optionalString stdenv.isDarwin "-msse2";
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
@ -131,7 +132,7 @@ let
|
|||
if includeModules then null else stdenv.mkDerivation rec {
|
||||
name = "python-${moduleName}-${python.version}";
|
||||
|
||||
inherit src patches preConfigure;
|
||||
inherit src patches preConfigure configureFlags;
|
||||
|
||||
buildInputs = [ python ] ++ deps;
|
||||
|
||||
|
|
|
@ -58,6 +58,8 @@ let
|
|||
touch $out/include/python${majorVersion}/pyconfig.h
|
||||
'';
|
||||
|
||||
configureFlags = "--enable-shared --with-threads --enable-unicode=ucs4";
|
||||
|
||||
buildInputs =
|
||||
optional (stdenv ? cc && stdenv.cc.libc != null) stdenv.cc.libc ++
|
||||
[ bzip2 openssl ]
|
||||
|
@ -73,14 +75,13 @@ let
|
|||
name = "python-${version}";
|
||||
pythonVersion = majorVersion;
|
||||
|
||||
inherit majorVersion version src patches buildInputs preConfigure;
|
||||
inherit majorVersion version src patches buildInputs preConfigure
|
||||
configureFlags;
|
||||
|
||||
LDFLAGS = stdenv.lib.optionalString (!stdenv.isDarwin) "-lgcc_s";
|
||||
C_INCLUDE_PATH = concatStringsSep ":" (map (p: "${p}/include") buildInputs);
|
||||
LIBRARY_PATH = concatStringsSep ":" (map (p: "${p}/lib") buildInputs);
|
||||
|
||||
configureFlags = "--enable-shared --with-threads --enable-unicode=ucs4";
|
||||
|
||||
NIX_CFLAGS_COMPILE = optionalString stdenv.isDarwin "-msse2";
|
||||
DETERMINISTIC_BUILD = 1;
|
||||
|
||||
|
@ -149,7 +150,7 @@ let
|
|||
if includeModules then null else stdenv.mkDerivation rec {
|
||||
name = "python-${moduleName}-${python.version}";
|
||||
|
||||
inherit src patches preConfigure;
|
||||
inherit src patches preConfigure configureFlags;
|
||||
|
||||
buildInputs = [ python ] ++ deps;
|
||||
|
||||
|
|
Loading…
Reference in a new issue