Skip to content

Commit

Permalink
Build Android on Linux with features
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexeyVavilin committed Nov 17, 2023
1 parent 23eeb83 commit b2129ab
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/lib-react-native/android/build/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const ARCHS: [Arch; 4] = [
];

const LIB: &str = "libeversdk.so";
const NDK_URL: &str = "http://dl.google.com/android/repository/android-ndk-r17c-darwin-x86_64.zip";
const NDK_URL: &str = "http://dl.google.com/android/repository/android-ndk-r17c-linux-x86_64.zip";

fn main() {
let target_arg = env::args().nth(1).unwrap_or("".to_string());
Expand All @@ -63,7 +63,7 @@ fn main() {
&builder.lib_dir.join("NDK").join(arch.ndk).join("bin"),
));
std::env::set_var("PATH", path);
assert!(exec("cargo", &["+1.67.0-x86_64-apple-darwin", "build", "--target", arch.target, "--release"]).success());
assert!(exec("cargo", &["+1.67.0-x86_64-unknown-linux-gnu", "build", "--target", arch.target, "--release"]).success());
}

let out_dir = builder.package_dir.join("src/main/jniLibs");
Expand Down
2 changes: 1 addition & 1 deletion packages/lib-react-native/android/lib/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ crate-type = [ 'cdylib' ]
[dependencies]
lazy_static = '1.4.0'
jni = { default-features = false, version = '0.12.0' }
ton_client = { git = 'https://github.com/tonlabs/ever-sdk.git', tag = '1.45.0' }
ton_client = { git = 'https://github.com/tonlabs/ever-sdk.git', tag = '1.45.0', default-features = false, features = [ 'std', 'rustls-tls-webpki-roots' ] }

[profile.release]
lto = true

0 comments on commit b2129ab

Please sign in to comment.