From a7e8775c3082fe6d10c9339177fc236a6ee7d0d8 Mon Sep 17 00:00:00 2001 From: Sergio Gasquez Arcos Date: Fri, 17 Nov 2023 11:09:58 +0100 Subject: [PATCH] fix(rust-training-esp32c3) Rust training builder (#58) --- rust-training-esp32c3/compile.sh | 2 +- rust-training-esp32c3/fetch.sh | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/rust-training-esp32c3/compile.sh b/rust-training-esp32c3/compile.sh index 7f34e87..1e16133 100755 --- a/rust-training-esp32c3/compile.sh +++ b/rust-training-esp32c3/compile.sh @@ -35,7 +35,7 @@ if [ -f ${HOME}/build-in/Cargo.toml ]; then exit 1 ;; esac - cd espressif-trainings/${PROJECT_PATH} + cd std-training/${PROJECT_PATH} cp ${HOME}/build-in/Cargo.toml Cargo.toml fi diff --git a/rust-training-esp32c3/fetch.sh b/rust-training-esp32c3/fetch.sh index 579cafe..401bb97 100755 --- a/rust-training-esp32c3/fetch.sh +++ b/rust-training-esp32c3/fetch.sh @@ -2,6 +2,11 @@ set -ef +export IDF_PATH="/home/esp/.espressif/frameworks/esp-idf" +export IDF_TOOLS_PATH=/home/esp/.espressif +. /home/esp/.espressif/frameworks/esp-idf/export.sh +export ESP_IDF_TOOLS_INSTALL_DIR=fromenv + echo "Compiling $1" cd /home/esp/std-training/$1 @@ -17,5 +22,4 @@ if [ -f cfg.toml.example ]; then sed -i 's/mqtt_host = "yourpc.local"/mqtt_host = "host"/g' cfg.toml fi -$HOME/.cargo/bin/cargo clean $HOME/.cargo/bin/cargo build --release