nixos: stage-1: Don't try to test binaries when cross-compiling.
This commit is contained in:
parent
aebb024b2f
commit
b28cb72908
|
@ -37,7 +37,7 @@ let
|
||||||
# we just copy what we need from Glibc and use patchelf to make it
|
# we just copy what we need from Glibc and use patchelf to make it
|
||||||
# work.
|
# work.
|
||||||
extraUtils = pkgs.runCommandCC "extra-utils"
|
extraUtils = pkgs.runCommandCC "extra-utils"
|
||||||
{ buildInputs = [pkgs.nukeReferences];
|
{ nativeBuildInputs = [pkgs.buildPackages.nukeReferences];
|
||||||
allowedReferences = [ "out" ]; # prevent accidents like glibc being included in the initrd
|
allowedReferences = [ "out" ]; # prevent accidents like glibc being included in the initrd
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
|
@ -132,6 +132,7 @@ let
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
if [ -z "${toString pkgs.stdenv.isCross}" ]; then
|
||||||
# Make sure that the patchelf'ed binaries still work.
|
# Make sure that the patchelf'ed binaries still work.
|
||||||
echo "testing patched programs..."
|
echo "testing patched programs..."
|
||||||
$out/bin/ash -c 'echo hello world' | grep "hello world"
|
$out/bin/ash -c 'echo hello world' | grep "hello world"
|
||||||
|
@ -144,6 +145,7 @@ let
|
||||||
$out/bin/mdadm --version
|
$out/bin/mdadm --version
|
||||||
|
|
||||||
${config.boot.initrd.extraUtilsCommandsTest}
|
${config.boot.initrd.extraUtilsCommandsTest}
|
||||||
|
fi
|
||||||
''; # */
|
''; # */
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue