diff options
author | Nikolay Amiantov <ab@fmap.me> | 2016-04-14 19:00:39 +0300 |
---|---|---|
committer | Nikolay Amiantov <ab@fmap.me> | 2016-04-25 13:24:39 +0300 |
commit | 5ff40ddedfe3188749faa21d71ac013277aff1d1 (patch) | |
tree | 04a39e7c45ffbd82e17fc22c2a4998d0d34787f3 /pkgs/development/interpreters/python | |
parent | c779e30d531032a7744685e80c2143b358efe1b0 (diff) | |
download | nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar.gz nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar.bz2 nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar.lz nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar.xz nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.tar.zst nixlib-5ff40ddedfe3188749faa21d71ac013277aff1d1.zip |
add get* helper functions and mass-replace manual outputs search with them
Diffstat (limited to 'pkgs/development/interpreters/python')
6 files changed, 12 insertions, 12 deletions
diff --git a/pkgs/development/interpreters/python/2.6/default.nix b/pkgs/development/interpreters/python/2.6/default.nix index 96b44ddc17f3..2196bb7e8b86 100644 --- a/pkgs/development/interpreters/python/2.6/default.nix +++ b/pkgs/development/interpreters/python/2.6/default.nix @@ -53,8 +53,8 @@ let ++ optional zlibSupport zlib; mkPaths = paths: { - C_INCLUDE_PATH = concatStringsSep ":" (map (p: "${p.dev or p}/include") paths); - LIBRARY_PATH = concatStringsSep ":" (map (p: "${p.lib or (p.out or p)}/lib") paths); + C_INCLUDE_PATH = makeSearchPathOutput "dev" "include" paths; + LIBRARY_PATH = makeLibraryPath paths; }; # Build the basic Python interpreter without modules that have diff --git a/pkgs/development/interpreters/python/2.7/default.nix b/pkgs/development/interpreters/python/2.7/default.nix index f1ae897ea4ac..6b336766db78 100644 --- a/pkgs/development/interpreters/python/2.7/default.nix +++ b/pkgs/development/interpreters/python/2.7/default.nix @@ -102,8 +102,8 @@ let propagatedBuildInputs = optional stdenv.isDarwin configd; mkPaths = paths: { - C_INCLUDE_PATH = concatStringsSep ":" (map (p: "${p.dev or p}/include") paths); - LIBRARY_PATH = concatStringsSep ":" (map (p: "${p.lib or (p.out or p)}/lib") paths); + C_INCLUDE_PATH = makeSearchPathOutput "dev" "include" paths; + LIBRARY_PATH = makeLibraryPath paths; }; # Build the basic Python interpreter without modules that have diff --git a/pkgs/development/interpreters/python/3.2/default.nix b/pkgs/development/interpreters/python/3.2/default.nix index c0b5d3401ddd..91f962efcf4a 100644 --- a/pkgs/development/interpreters/python/3.2/default.nix +++ b/pkgs/development/interpreters/python/3.2/default.nix @@ -44,8 +44,8 @@ stdenv.mkDerivation { ${optionalString stdenv.isDarwin ''export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -msse2"''} configureFlagsArray=( --enable-shared --with-threads --with-wide-unicode - CPPFLAGS="${concatStringsSep " " (map (p: "-I${p.dev or p}/include") buildInputs)}" - LDFLAGS="${concatStringsSep " " (map (p: "-L${p.lib or (p.out or p)}/lib") buildInputs)}" + CPPFLAGS="${makeSearchPathOutput "dev" "include" buildInputs}" + LDFLAGS="${makeLibraryPath buildInputs}" LIBS="${optionalString (!stdenv.isDarwin) "-lcrypt"} ${optionalString (ncurses != null) "-lncurses"}" ) ''; diff --git a/pkgs/development/interpreters/python/3.3/default.nix b/pkgs/development/interpreters/python/3.3/default.nix index a46ef7c056b2..b9cb46562122 100644 --- a/pkgs/development/interpreters/python/3.3/default.nix +++ b/pkgs/development/interpreters/python/3.3/default.nix @@ -46,8 +46,8 @@ stdenv.mkDerivation { ${optionalString stdenv.isDarwin ''export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -msse2"''} configureFlagsArray=( --enable-shared --with-threads - CPPFLAGS="${concatStringsSep " " (map (p: "-I${p.dev or p}/include") buildInputs)}" - LDFLAGS="${concatStringsSep " " (map (p: "-L${p.lib or (p.out or p)}/lib") buildInputs)}" + CPPFLAGS="${makeSearchPathOutput "dev" "include" buildInputs}" + LDFLAGS="${makeLibraryPath buildInputs}" LIBS="${optionalString (!stdenv.isDarwin) "-lcrypt"} ${optionalString (ncurses != null) "-lncurses"}" ) ''; diff --git a/pkgs/development/interpreters/python/3.4/default.nix b/pkgs/development/interpreters/python/3.4/default.nix index 8d87c6abfbb4..6a3ab25c5d40 100644 --- a/pkgs/development/interpreters/python/3.4/default.nix +++ b/pkgs/development/interpreters/python/3.4/default.nix @@ -58,8 +58,8 @@ stdenv.mkDerivation { ''} configureFlagsArray=( --enable-shared --with-threads - CPPFLAGS="${concatStringsSep " " (map (p: "-I${p.dev or p}/include") buildInputs)}" - LDFLAGS="${concatStringsSep " " (map (p: "-L${p.lib or (p.out or p)}/lib") buildInputs)}" + CPPFLAGS="${makeSearchPathOutput "dev" "include" buildInputs}" + LDFLAGS="${makeLibraryPath buildInputs}" LIBS="${optionalString (!stdenv.isDarwin) "-lcrypt"} ${optionalString (ncurses != null) "-lncurses"}" ) ''; diff --git a/pkgs/development/interpreters/python/3.5/default.nix b/pkgs/development/interpreters/python/3.5/default.nix index 4bc39f4c2b3a..504c85ac38d2 100644 --- a/pkgs/development/interpreters/python/3.5/default.nix +++ b/pkgs/development/interpreters/python/3.5/default.nix @@ -58,8 +58,8 @@ stdenv.mkDerivation { ''} configureFlagsArray=( --enable-shared --with-threads - CPPFLAGS="${concatStringsSep " " (map (p: "-I${p.dev or p}/include") buildInputs)}" - LDFLAGS="${concatStringsSep " " (map (p: "-L${p.lib or (p.out or p)}/lib") buildInputs)}" + CPPFLAGS="${makeSearchPathOutput "dev" "include" buildInputs}" + LDFLAGS="${makeLibraryPath buildInputs}" LIBS="${optionalString (!stdenv.isDarwin) "-lcrypt"} ${optionalString (ncurses != null) "-lncurses"}" ) ''; |