mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-13 09:17:07 +03:00
Adding a new mkDerivation flag for the cross stdenv, selfNativeBuildInput =
true/false, which tells whether the derivation needs itself as buildNativeInput. For example, in order to build cross ncurses, we need the a native build ncurses. (As libtool does not work in stdenv, I have not tested this change, to check whether finally ncurses cross-build) svn path=/nixpkgs/branches/stdenv-updates/; revision=18489
This commit is contained in:
parent
4497215410
commit
28d9e73d34
@ -12,6 +12,8 @@ stdenv.mkDerivation rec {
|
|||||||
--with-shared --includedir=''${out}/include --without-debug
|
--with-shared --includedir=''${out}/include --without-debug
|
||||||
${if unicode then "--enable-widec" else ""}
|
${if unicode then "--enable-widec" else ""}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
selfNativeBuildInput = true;
|
||||||
|
|
||||||
preBuild = ''sed -e "s@\([[:space:]]\)sh @\1''${SHELL} @" -i */Makefile Makefile'';
|
preBuild = ''sed -e "s@\([[:space:]]\)sh @\1''${SHELL} @" -i */Makefile Makefile'';
|
||||||
|
|
||||||
|
@ -111,7 +111,8 @@ rec {
|
|||||||
# builds.
|
# builds.
|
||||||
makeStdenvCross = stdenv: cross: binutilsCross: gccCross: stdenv //
|
makeStdenvCross = stdenv: cross: binutilsCross: gccCross: stdenv //
|
||||||
{ mkDerivation = {name ? "", buildInputs ? [], buildNativeInputs ? [],
|
{ mkDerivation = {name ? "", buildInputs ? [], buildNativeInputs ? [],
|
||||||
propagatedBuildInputs ? [], propagatedBuildNativeInputs ? [], ...}@args: let
|
propagatedBuildInputs ? [], propagatedBuildNativeInputs ? [],
|
||||||
|
selfNativeBuildInput ? false, ...}@args: let
|
||||||
|
|
||||||
# *BuildInputs exists temporarily as another name for
|
# *BuildInputs exists temporarily as another name for
|
||||||
# *HostInputs.
|
# *HostInputs.
|
||||||
@ -135,7 +136,8 @@ rec {
|
|||||||
stdenv.mkDerivation (args // {
|
stdenv.mkDerivation (args // {
|
||||||
name = name + "-" + cross.config;
|
name = name + "-" + cross.config;
|
||||||
buildNativeInputs = buildNativeInputsDrvs
|
buildNativeInputs = buildNativeInputsDrvs
|
||||||
++ [ gccCross binutilsCross ];
|
++ [ gccCross binutilsCross ] ++
|
||||||
|
stdenv.lib.optional selfNativeBuildInput buildDrv;
|
||||||
buildInputs = buildInputsDrvs;
|
buildInputs = buildInputsDrvs;
|
||||||
propagatedBuildInputs = propagatedBuildInputsDrvs;
|
propagatedBuildInputs = propagatedBuildInputsDrvs;
|
||||||
propagatedBuildNativeInputs = propagatedBuildNativeInputsDrvs;
|
propagatedBuildNativeInputs = propagatedBuildNativeInputsDrvs;
|
||||||
|
Loading…
Reference in New Issue
Block a user