mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-04-15 02:31:57 +00:00
revert to switching rust versions as required
This commit is contained in:
parent
02fec3d581
commit
5bb7813234
17 changed files with 133 additions and 7 deletions
docs
scripts
|
@ -72,7 +72,7 @@ Install [Rust](https://www.rust-lang.org/tools/install) via [rustup.rs](https://
|
|||
```
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
||||
source ~/.bashrc
|
||||
rustup install 1.85.1
|
||||
rustup install 1.85.1 1.81.0
|
||||
rustup default 1.85.1
|
||||
cargo install cargo-ndk --version 2.12.7 --locked
|
||||
```
|
||||
|
@ -209,11 +209,11 @@ brew install brotli cairo coreutils gdbm gettext glib gmp libevent libidn2 libng
|
|||
```
|
||||
<!-- TODO: determine which of the above list are not needed at all. -->
|
||||
|
||||
Download and install [Rust](https://www.rust-lang.org/tools/install). [Rustup](https://rustup.rs/) is recommended for Rust setup. Use `rustc` to confirm successful installation. Install toolchain 1.85.1 and `cbindgen` and `cargo-lipo` too. You will also have to add the platform target(s) `aarch64-apple-ios` and/or `aarch64-apple-darwin`. You can use the command(s):
|
||||
Download and install [Rust](https://www.rust-lang.org/tools/install). [Rustup](https://rustup.rs/) is recommended for Rust setup. Use `rustc` to confirm successful installation. Install toolchains 1.81.0 and 1.85.1 and `cbindgen` and `cargo-lipo` too. You will also have to add the platform target(s) `aarch64-apple-ios` and/or `aarch64-apple-darwin`. You can use the command(s):
|
||||
```
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
||||
source ~/.bashrc
|
||||
rustup install 1.85.1
|
||||
rustup install 1.85.1 1.81.0
|
||||
rustup default 1.85.1
|
||||
cargo install cargo-ndk --version 2.12.7 --locked
|
||||
cargo install cbindgen cargo-lipo
|
||||
|
@ -306,7 +306,7 @@ Run `flutter doctor` in PowerShell to confirm its installation.
|
|||
### Rust
|
||||
Install [Rust](https://www.rust-lang.org/tools/install) on the Windows host (not in WSL2). Download the installer from [rustup.rs](https://rustup.rs), make sure it works on the commandline (you may need to open a new terminal), and install the following versions:
|
||||
```
|
||||
rustup install 1.85.1
|
||||
rustup install 1.85.1 1.81.0
|
||||
rustup default 1.85.1
|
||||
cargo install cargo-ndk --version 2.12.7 --locked
|
||||
```
|
||||
|
|
|
@ -8,7 +8,14 @@ mkdir -p build
|
|||
PLUGINS_DIR=../../crypto_plugins
|
||||
|
||||
(cd "${PLUGINS_DIR}"/flutter_liblelantus/scripts/android && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd "${PLUGINS_DIR}"/flutter_libepiccash/scripts/android && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd "${PLUGINS_DIR}"/frostdart/scripts/android && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -8,7 +8,14 @@ mkdir -p build
|
|||
PLUGINS_DIR=../../crypto_plugins
|
||||
|
||||
(cd "${PLUGINS_DIR}"/flutter_liblelantus/scripts/android && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd "${PLUGINS_DIR}"/flutter_libepiccash/scripts/android && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd "${PLUGINS_DIR}"/frostdart/scripts/android && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -10,7 +10,14 @@ mkdir -p build
|
|||
PLUGINS_DIR=../../crypto_plugins
|
||||
|
||||
(cd "${PLUGINS_DIR}"/flutter_liblelantus/scripts/android && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd "${PLUGINS_DIR}"/flutter_libepiccash/scripts/android && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd "${PLUGINS_DIR}"/frostdart/scripts/android && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -11,7 +11,14 @@ rustup target add aarch64-apple-ios
|
|||
rustup target add x86_64-apple-ios
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/ios && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/ios && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/ios && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -11,7 +11,14 @@ rustup target add aarch64-apple-ios
|
|||
rustup target add x86_64-apple-ios
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/ios && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/ios && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/ios && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -13,7 +13,14 @@ rustup target add aarch64-apple-ios
|
|||
rustup target add x86_64-apple-ios
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/ios && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/ios && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/ios && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -9,7 +9,14 @@ set -x -e
|
|||
mkdir -p build
|
||||
./build_secure_storage_deps.sh
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/linux && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/linux && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/linux && ./build_all.sh )
|
||||
|
||||
./build_secp256k1.sh
|
||||
|
|
|
@ -9,7 +9,14 @@ set -x -e
|
|||
mkdir -p build
|
||||
./build_secure_storage_deps.sh
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/linux && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/linux && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/linux && ./build_all.sh )
|
||||
|
||||
./build_secp256k1.sh
|
||||
|
|
|
@ -12,7 +12,14 @@ set -x -e
|
|||
mkdir -p build
|
||||
./build_secure_storage_deps.sh &
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/linux && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/linux && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/frostdart/scripts/linux && ./build_all.sh )
|
||||
|
||||
./build_secp256k1.sh
|
||||
|
|
|
@ -2,8 +2,15 @@
|
|||
|
||||
set -x -e
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/macos && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/macos && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -2,8 +2,15 @@
|
|||
|
||||
set -x -e
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/macos && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/macos && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
|
@ -4,8 +4,15 @@ set -x -e
|
|||
|
||||
# todo: revisit following at some point
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/macos && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/macos && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/macos && ./build_all.sh )
|
||||
|
||||
wait
|
||||
|
|
21
scripts/rust_version.sh
Executable file
21
scripts/rust_version.sh
Executable file
|
@ -0,0 +1,21 @@
|
|||
#!/bin/sh
|
||||
|
||||
|
||||
set_rust_to_everything_else() {
|
||||
if rustup toolchain list | grep -q "1.85.1"; then
|
||||
rustup default 1.85.1
|
||||
else
|
||||
echo "Rust version 1.85.1 is not installed. Please install it using 'rustup install 1.85.1'." >&2
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
set_rust_version_for_libepiccash() {
|
||||
if rustup toolchain list | grep -q "1.81.0"; then
|
||||
rustup default 1.81
|
||||
else
|
||||
echo "Rust version 1.81.0 is not installed. Please install it using 'rustup install 1.81.0'." >&2
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
|
@ -3,7 +3,14 @@
|
|||
set -x -e
|
||||
|
||||
mkdir -p build
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/windows && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/windows && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/windows && ./build_all.sh )
|
||||
|
||||
|
|
|
@ -3,7 +3,14 @@
|
|||
set -x -e
|
||||
|
||||
mkdir -p build
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/windows && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/windows && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/windows && ./build_all.sh )
|
||||
|
||||
|
|
|
@ -5,7 +5,14 @@ set -x -e
|
|||
# todo: revisit following at some point
|
||||
|
||||
mkdir -p build
|
||||
|
||||
# libepiccash requires old rust
|
||||
source ../rust_version.sh
|
||||
set_rust_version_for_libepiccash
|
||||
(cd ../../crypto_plugins/flutter_libepiccash/scripts/windows && ./build_all.sh )
|
||||
# set rust (back) to a more recent stable release after building epiccash
|
||||
set_rust_to_everything_else
|
||||
|
||||
(cd ../../crypto_plugins/flutter_liblelantus/scripts/windows && ./build_all.sh )
|
||||
(cd ../../crypto_plugins/frostdart/scripts/windows && ./build_all.sh )
|
||||
|
||||
|
|
Loading…
Reference in a new issue