Update cargo dependencies, add config and gitignore

This commit is contained in:
Blizzard Finnegan 2023-06-28 09:07:31 -04:00
parent f95c88fd30
commit 94303826eb
Signed by: blizzardfinnegan
GPG key ID: 61C1E13067E0018E
4 changed files with 22 additions and 3 deletions

2
.cargo/config.toml Normal file
View file

@ -0,0 +1,2 @@
[target.aarch64-unknown-linux-musl]
linker = "lld"

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
/target

View file

@ -1,18 +1,22 @@
[package]
name = "disco_accuracy_over_life"
version = "5.0.0-alpha"
version = "5.0.0-alpha.1"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
serialport = { version = "4.2.0", default-features = false }
chrono = "0.4.24"
config = "0.13.3"
derivative = "2.2.0"
fern = "0.6.2"
futures = "0.3.28"
log = "0.4.17"
once_cell = "1.17.1"
ordered-float = "3.7.0"
rppal = "0.14.1"
rust-ini = "0.19.0"
clap = { version = "4.3.2", features = ["derive"] }
[dev-dependencies]
time = "0.2.23"

View file

@ -1,4 +1,16 @@
{pkgs ? import <nixpkgs> {} }:
pkgs.mkShell {
nativeBuildInputs = with pkgs; [ cargo clang libclang rustc pkg-config libudev-zero tesseract opencv leptonica ];
buildInputs = with pkgs; [ lld rustup ];
RUSTUP_HOME = toString ./.rustup;
CARGO_HOME = toString ./.cargo;
RUSTUP_TOOLCHAIN = "stable";
HOST_ARCH = "x86_64-unknown-linux-gnu";
CARGO_BUILD_TARGET = "aarch64-unknown-linux-musl";
shellHook = ''
export PATH=$PATH:${CARGO_HOME}/bin
export PATH=$PATH:${RUSTUP_HOME}/toolchains/${RUSTUP_TOOLCHAIN}-${HOST_ARCH}/bin/
rustup target add "${HOST_ARCH}"
rustup target add "${CARGO_BUILD_TARGET}"
'';
}