forked from M-Labs/artiq-zynq
follow changes in zynq-rs
This commit is contained in:
parent
dffe00990b
commit
eab839aed0
@ -1,23 +0,0 @@
|
|||||||
{ pkgs }:
|
|
||||||
pkgs.rustPlatform.buildRustPackage rec {
|
|
||||||
pname = "cargo-xbuild";
|
|
||||||
version = "0.5.21";
|
|
||||||
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "rust-osdev";
|
|
||||||
repo = pname;
|
|
||||||
rev = "v${version}";
|
|
||||||
sha256 = "08mpnj3l6bcm1jg22lw1gcs0lkm4320fwl4p5y1s44w64963kzf7";
|
|
||||||
};
|
|
||||||
|
|
||||||
patches = [ ./cargo-xbuild.patch ];
|
|
||||||
|
|
||||||
cargoSha256 = "1pj4x8y5vfpnn8vhxqqm3vicn29870r3jh0b17q3riq4vz1a2afp";
|
|
||||||
|
|
||||||
meta = with pkgs.stdenv.lib; {
|
|
||||||
description = "Automatically cross-compiles the sysroot crates core, compiler_builtins, and alloc";
|
|
||||||
homepage = "https://github.com/rust-osdev/cargo-xbuild";
|
|
||||||
license = with licenses; [ mit asl20 ];
|
|
||||||
maintainers = with maintainers; [ johntitor xrelkd ];
|
|
||||||
};
|
|
||||||
}
|
|
@ -13,7 +13,7 @@ let
|
|||||||
version = "0.1.0";
|
version = "0.1.0";
|
||||||
|
|
||||||
src = ./src;
|
src = ./src;
|
||||||
cargoSha256 = "10hap25cy2qgwr7b86jid73i6fp480iym29r3r97jindfxk0svi0";
|
cargoSha256 = "152k0jvx02a66dafyc25pz60wlg7i3kln9hh7nwl2wcanmqzzkbw";
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
pkgs.gnumake
|
pkgs.gnumake
|
||||||
@ -23,7 +23,7 @@ let
|
|||||||
pkgs.llvmPackages_9.clang-unwrapped
|
pkgs.llvmPackages_9.clang-unwrapped
|
||||||
];
|
];
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
export XARGO_RUST_SRC="${rustPlatform.rust.rustc.src}/src"
|
export XARGO_RUST_SRC="${rustPlatform.rust.rustc.src}/library"
|
||||||
export CARGO_HOME=$(mktemp -d cargo-home.XXX)
|
export CARGO_HOME=$(mktemp -d cargo-home.XXX)
|
||||||
make VARIANT=${variant}
|
make VARIANT=${variant}
|
||||||
'';
|
'';
|
||||||
|
@ -2,10 +2,10 @@ let
|
|||||||
zynq-rs = (import ./zynq-rs.nix);
|
zynq-rs = (import ./zynq-rs.nix);
|
||||||
pkgs = import <nixpkgs> { overlays = [ (import "${zynq-rs}/nix/mozilla-overlay.nix") ]; };
|
pkgs = import <nixpkgs> { overlays = [ (import "${zynq-rs}/nix/mozilla-overlay.nix") ]; };
|
||||||
rustPlatform = (import "${zynq-rs}/nix/rust-platform.nix" { inherit pkgs; });
|
rustPlatform = (import "${zynq-rs}/nix/rust-platform.nix" { inherit pkgs; });
|
||||||
|
cargo-xbuild = (import zynq-rs).cargo-xbuild;
|
||||||
artiq-fast = <artiq-fast>;
|
artiq-fast = <artiq-fast>;
|
||||||
artiqpkgs = import "${artiq-fast}/default.nix" { inherit pkgs; };
|
artiqpkgs = import "${artiq-fast}/default.nix" { inherit pkgs; };
|
||||||
vivado = import "${artiq-fast}/vivado.nix" { inherit pkgs; };
|
vivado = import "${artiq-fast}/vivado.nix" { inherit pkgs; };
|
||||||
cargo-xbuild = import ./cargo-xbuild.nix { inherit pkgs; };
|
|
||||||
zc706-szl = (import zynq-rs).zc706-szl;
|
zc706-szl = (import zynq-rs).zc706-szl;
|
||||||
in
|
in
|
||||||
pkgs.stdenv.mkDerivation {
|
pkgs.stdenv.mkDerivation {
|
||||||
@ -17,7 +17,7 @@ in
|
|||||||
pkgs.llvmPackages_9.llvm
|
pkgs.llvmPackages_9.llvm
|
||||||
pkgs.llvmPackages_9.clang-unwrapped
|
pkgs.llvmPackages_9.clang-unwrapped
|
||||||
pkgs.cacert
|
pkgs.cacert
|
||||||
cargo-xbuild
|
(cargo-xbuild.overrideAttrs(oa: { patches = oa.patches ++ [ ./xbuild_override_compiler_builtins.patch ]; } ))
|
||||||
|
|
||||||
pkgs.openocd
|
pkgs.openocd
|
||||||
pkgs.openssh pkgs.rsync
|
pkgs.openssh pkgs.rsync
|
||||||
@ -29,7 +29,7 @@ in
|
|||||||
(import "${zynq-rs}/nix/mkbootimage.nix" { inherit pkgs; })
|
(import "${zynq-rs}/nix/mkbootimage.nix" { inherit pkgs; })
|
||||||
];
|
];
|
||||||
|
|
||||||
XARGO_RUST_SRC = "${rustPlatform.rust.rustc.src}/src";
|
XARGO_RUST_SRC = "${rustPlatform.rust.rustc.src}/library";
|
||||||
OPENOCD_ZYNQ = "${zynq-rs}/openocd";
|
OPENOCD_ZYNQ = "${zynq-rs}/openocd";
|
||||||
SZL = "${zc706-szl}/szl.elf";
|
SZL = "${zc706-szl}/szl.elf";
|
||||||
}
|
}
|
||||||
|
20
src/Cargo.lock
generated
20
src/Cargo.lock
generated
@ -58,7 +58,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "core_io"
|
name = "core_io"
|
||||||
version = "0.1.20200410"
|
version = "0.1.20200410"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"memchr",
|
"memchr",
|
||||||
]
|
]
|
||||||
@ -188,11 +188,11 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libasync"
|
name = "libasync"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"embedded-hal",
|
"embedded-hal",
|
||||||
"libcortex_a9",
|
"libcortex_a9",
|
||||||
"nb 0.1.3",
|
"nb 1.0.0",
|
||||||
"pin-utils",
|
"pin-utils",
|
||||||
"smoltcp",
|
"smoltcp",
|
||||||
]
|
]
|
||||||
@ -200,7 +200,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libboard_zynq"
|
name = "libboard_zynq"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bit_field",
|
"bit_field",
|
||||||
"embedded-hal",
|
"embedded-hal",
|
||||||
@ -224,7 +224,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libconfig"
|
name = "libconfig"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"core_io",
|
"core_io",
|
||||||
"fatfs",
|
"fatfs",
|
||||||
@ -235,7 +235,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libcortex_a9"
|
name = "libcortex_a9"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bit_field",
|
"bit_field",
|
||||||
"libregister",
|
"libregister",
|
||||||
@ -251,7 +251,7 @@ checksum = "c7d73b3f436185384286bd8098d17ec07c9a7d2388a6599f824d8502b529702a"
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libregister"
|
name = "libregister"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bit_field",
|
"bit_field",
|
||||||
"vcell",
|
"vcell",
|
||||||
@ -261,7 +261,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "libsupport_zynq"
|
name = "libsupport_zynq"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#7360984efbd772ae992ef00af09786b0ae8430f0"
|
source = "git+https://git.m-labs.hk/M-Labs/zynq-rs.git#6266d280951c3fe5d4963a4b1ca45ce369d6b773"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"compiler_builtins",
|
"compiler_builtins",
|
||||||
"libboard_zynq",
|
"libboard_zynq",
|
||||||
@ -273,9 +273,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "linked_list_allocator"
|
name = "linked_list_allocator"
|
||||||
version = "0.8.5"
|
version = "0.8.6"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "660b26e6156a7d00eefb19052fe1943cf5ab2f353a723a577fad6ba2f99d1f90"
|
checksum = "84565678e403453d1a27a0886882b3b271701e65146d972d9d7d9a4c4a0ff498"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "log"
|
name = "log"
|
||||||
|
@ -3,6 +3,6 @@ let
|
|||||||
in
|
in
|
||||||
pkgs.fetchgit {
|
pkgs.fetchgit {
|
||||||
url = "https://git.m-labs.hk/M-Labs/zynq-rs.git";
|
url = "https://git.m-labs.hk/M-Labs/zynq-rs.git";
|
||||||
rev = "7360984efbd772ae992ef00af09786b0ae8430f0";
|
rev = "6266d280951c3fe5d4963a4b1ca45ce369d6b773";
|
||||||
sha256 = "10xrkhvrs6p0pn50cccvbnzi7l9lp8a6xmqy0pv5vg0f1qq3zxif";
|
sha256 = "13cnxlnafj5s0rd9a9k369b6xfb1gnvp40vfk81kbr1924a1c04d";
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user