HeavyX/derivations.nix
Sebastien Bourdeauducq b17ec6fb1f llvm: only build x86 and riscv
Attempting to fix llvm-lld breakage on msp430 by disabling msp430.
2019-06-05 23:19:51 +08:00

35 lines
1.5 KiB
Nix

{ pkgs }:
rec {
yosys = pkgs.callPackage ./eda/yosys.nix {};
symbiyosys = pkgs.symbiyosys.override { inherit yosys; };
nmigen = pkgs.callPackage ./eda/nmigen.nix { inherit yosys; };
scala-spinalhdl = pkgs.callPackage ./eda/scala-spinalhdl.nix {};
jtagtap = pkgs.callPackage ./cores/jtagtap.nix { inherit nmigen; };
minerva = pkgs.callPackage ./cores/minerva.nix { inherit nmigen; inherit jtagtap; };
vexriscv-small = pkgs.callPackage ./cores/vexriscv.nix {
inherit scala-spinalhdl;
name = "vexriscv-small";
scalaToRun = "vexriscv.demo.GenSmallAndProductive";
};
heavycomps = pkgs.callPackage ./heavycomps.nix { inherit nmigen; };
binutils-riscv = pkgs.callPackage ./compilers/binutils.nix { platform = "riscv32"; };
llvm_7 = pkgs.llvm_7.overrideAttrs(oa: {
name = oa.name + "-riscv";
cmakeFlags = oa.cmakeFlags ++ ["-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=RISCV" "-DLLVM_TARGETS_TO_BUILD=X86"];
});
rustc = (pkgs.rustc.overrideAttrs(oa: {
name = "${oa.pname}-${oa.version}-riscv";
configureFlags = oa.configureFlags ++ [ "--enable-lld" ];
})).override {
inherit llvm_7;
pkgsBuildBuild = pkgs.pkgsBuildBuild // { inherit llvm_7; };
pkgsBuildHost = pkgs.pkgsBuildHost // { inherit llvm_7; };
pkgsBuildTarget = pkgs.pkgsBuildTarget // { inherit llvm_7; };
};
rust-riscv32imc-crates = pkgs.callPackage ./compilers/rust-riscv32imc-crates.nix { inherit rustc; };
cargo = pkgs.cargo.override { inherit rustc; };
}