09a8f9297c
The tests where only enabled recently in 0d1d43d49c
but apparently fail
for the older version (I didn't have a closer look as they should work
after the next GNS3 release anyway).
45 lines
1.3 KiB
Nix
45 lines
1.3 KiB
Nix
{ callPackage }:
|
|
|
|
let
|
|
stableVersion = "2.2.5";
|
|
previewVersion = stableVersion;
|
|
addVersion = args:
|
|
let version = if args.stable then stableVersion else previewVersion;
|
|
branch = if args.stable then "stable" else "preview";
|
|
in args // { inherit version branch; };
|
|
extraArgs = {
|
|
mkOverride = attrname: version: sha256:
|
|
self: super: {
|
|
${attrname} = super.${attrname}.overridePythonAttrs (oldAttrs: {
|
|
inherit version;
|
|
src = oldAttrs.src.override {
|
|
inherit version sha256;
|
|
};
|
|
doCheck = oldAttrs.doCheck && (attrname != "psutil");
|
|
});
|
|
};
|
|
};
|
|
mkGui = args: callPackage (import ./gui.nix (addVersion args // extraArgs)) { };
|
|
mkServer = args: callPackage (import ./server.nix (addVersion args // extraArgs)) { };
|
|
guiSrcHash = "1yxwbz93x9hn5y6dir8v7bdfsmfgppvjg4z88l8gx82hhf2476fx";
|
|
serverSrcHash = "1d3m8qrz82g8ii6q6j015wqwp6j0415fbqbjvw43zhdx5mnn962d";
|
|
in {
|
|
guiStable = mkGui {
|
|
stable = true;
|
|
sha256Hash = guiSrcHash;
|
|
};
|
|
guiPreview = mkGui {
|
|
stable = false;
|
|
sha256Hash = guiSrcHash;
|
|
};
|
|
|
|
serverStable = mkServer {
|
|
stable = true;
|
|
sha256Hash = serverSrcHash;
|
|
};
|
|
serverPreview = mkServer {
|
|
stable = false;
|
|
sha256Hash = serverSrcHash;
|
|
};
|
|
}
|