refactor: updates build scripts

Updates build scripts to account for the updated naming convention.
Updates bindings accordingly.
This commit is contained in:
coreyphillips
2024-10-29 19:47:33 -04:00
parent 693106a2e1
commit 58870cab6a
26 changed files with 929 additions and 857 deletions

View File

@@ -23,7 +23,7 @@ const setupAndroidCommand = `
cargo install cargo-ndk && \\
rustup target add aarch64-linux-android armv7-linux-androideabi i686-linux-android x86_64-linux-android && \\
cargo ndk -o ./app/src/main/jniLibs --manifest-path ./Cargo.toml -t armeabi-v7a -t arm64-v8a -t x86 -t x86_64 build --release && \\
cargo run --bin uniffi-bindgen generate --library ./target/release/libpubkymobile.dylib --language kotlin --out-dir ./app/src/main/java/tech/forgen/todolist/rust
cargo run --bin uniffi-bindgen generate --library ./target/release/libpubkycore.dylib --language kotlin --out-dir ./app/src/main/java/tech/forgen/todolist/rust
`;
const postSetupAndroid = async () => {
@@ -38,8 +38,8 @@ const postSetupAndroid = async () => {
'todolist',
'rust',
'uniffi',
'pubkymobile',
'pubkymobile.kt'
'pubkycore',
'pubkycore.kt'
);
const androidMobileKt = path.resolve(
'android',
@@ -47,8 +47,8 @@ const postSetupAndroid = async () => {
'main',
'java',
'uniffi',
'pubkymobile',
'pubkymobile.kt'
'pubkycore',
'pubkycore.kt'
);
// Create the destination directory if it doesn't exist