Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
These are my tests for this PR: https://github.com/NixOS/nixpkgs/pull/18386
rec {
myNixpkgsFunc = import ./nixpkgs;
myNixpkgs = myNixpkgsFunc {};
baseNixpkgsFunc = import ((import <nixpkgs> { }).fetchFromGitHub {
owner = "NixOS";
repo = "nixpkgs";
rev = "d4eac0278ca188aa236b6a7f0fbb15f8ee4273d0";
sha256 = "0mpx6bjvix7dfmgn6a2chmmicamz9v941fki0lgzfk2gw90fqg6w";
});
baseNixpkgs = baseNixpkgsFunc {};
myTestsPass = (import ./nixpkgs/test/cross_system.nix).testsPass;
gcc6Same = myNixpkgs.gcc6 == baseNixpkgs.gcc6;
gcc5Same = myNixpkgs.gcc5 == baseNixpkgs.gcc5;
gcc49Same = myNixpkgs.gcc49 == baseNixpkgs.gcc49;
gcc48Same = myNixpkgs.gcc48 == baseNixpkgs.gcc48;
gcc45Same = myNixpkgs.gcc45 == baseNixpkgs.gcc45;
gccSame = gcc6Same && gcc5Same && gcc49Same && gcc45Same;
libtoolSame = myNixpkgs.libtool == baseNixpkgs.libtool;
guileSame = myNixpkgs.guile == baseNixpkgs.guile;
testsPass = myTestsPass && gccSame && libtoolSame && guileSame;
derivations = rec {
recurseForDerivations = assert testsPass; true;
rpiCrossSystem = {
config = "armv6l-unknown-linux-gnueabi";
bigEndian = false;
arch = "arm";
float = "hard";
fpu = "vfp";
withTLS = true;
libc = "glibc";
platform = myNixpkgs.platforms.raspberrypi;
openssl.system = "linux-generic32";
gcc = {
arch = "armv6";
fpu = "vfp";
float = "softfp";
abi = "aapcs-linux";
};
};
rpiPkgs = myNixpkgsFunc { crossSystem = rpiCrossSystem; };
rpiHello = rpiPkgs.hello.crossDrv;
rpiPkgsBase = baseNixpkgsFunc { crossSystem = rpiCrossSystem; };
rpiHelloBase = rpiPkgsBase.hello.crossDrv;
releaseCross = import ./nixpkgs/pkgs/top-level/release-cross.nix;
# These are all the jobs from
# https://hydra.nixos.org/eval/1291742#tabs-still-succeed
bootstrapTools = {
recurseForDerivations = true;
armv5tel = releaseCross.bootstrapTools.armv5tel;
armv6l = releaseCross.bootstrapTools.armv6l;
armv7l = releaseCross.bootstrapTools.armv7l;
};
crossMingw32 = {
recurseForDerivations = true;
boehmgc = releaseCross.crossMingw32.boehmgc.crossDrv {};
gmp = releaseCross.crossMingw32.gmp.crossDrv {};
libffi = releaseCross.crossMingw32.libffi.crossDrv {};
libtool = releaseCross.crossMingw32.libtool.crossDrv {};
libunistring = releaseCross.crossMingw32.libunistring.crossDrv {};
};
crossMingwW64 = {
recurseForDerivations = true;
boehmgc = releaseCross.crossMingwW64.boehmgc.crossDrv {};
gmp = releaseCross.crossMingwW64.gmp.crossDrv {};
libffi = releaseCross.crossMingwW64.libffi.crossDrv {};
libtool = releaseCross.crossMingwW64.libtool.crossDrv {};
libunistring = releaseCross.crossMingwW64.libunistring.crossDrv {};
};
crossShevaplugLinux = {
recurseForDerivations = true;
bison = releaseCross.crossSheevaplugLinux.bison.crossDrv {};
busybox = releaseCross.crossSheevaplugLinux.busybox.crossDrv {};
coreutils = releaseCross.crossSheevaplugLinux.coreutils.crossDrv {};
dropbear = releaseCross.crossSheevaplugLinux.dropbear.crossDrv {};
gcc = releaseCross.crossSheevaplugLinux.gccCrossStageFinal {};
};
fuloongminipc = {
recurseForDerivations = true;
coreutils = releaseCross.fuloongminipc.coreutils.crossDrv {};
ed = releaseCross.fuloongminipc.ed.crossDrv {};
patch = releaseCross.fuloongminipc.patch.crossDrv {};
};
rpi = {
recurseForDerivations = true;
binutils = releaseCross.rpi.binutils.crossDrv {};
coreutils = releaseCross.rpi.coreutils.crossDrv {};
ddrescue = releaseCross.rpi.ddrescue.crossDrv {};
ed = releaseCross.rpi.ed.crossDrv {};
lynx = releaseCross.rpi.lynx.crossDrv {};
mpg123 = releaseCross.rpi.mpg123.crossDrv {};
patch = releaseCross.rpi.patch.crossDrv {};
patchelf = releaseCross.rpi.patchelf.crossDrv {};
unzip = releaseCross.rpi.unzip.crossDrv {};
vim = releaseCross.rpi.vim.crossDrv {};
};
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment