Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: x86 android support #218

Merged
merged 2 commits into from
Aug 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .mac-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,17 +62,17 @@ echo "Installing rust target(s) ..."
rustup target add aarch64-linux-android \
armv7-linux-androideabi \
x86_64-linux-android \
i686-linux-android \
aarch64-apple-darwin \
x86_64-apple-darwin \
aarch64-apple-ios \
x86_64-apple-ios \
aarch64-apple-ios-sim \
wasm32-unknown-emscripten


echo "Installing nightly toolchain"
rustup install nightly
rustup component add rust-src --toolchain nightly
rustup install nightly
rustup component add rust-src --toolchain nightly
rustup target add wasm32-unknown-emscripten --toolchain nightly

echo
Expand All @@ -81,7 +81,6 @@ cargo install uniffi-bindgen-cpp \
--git https://github.com/NordSecurity/uniffi-bindgen-cpp \
--tag "${UNIFFI_BINDGEN_CPP_VERSION}"


echo
echo "Setting up project ..."
make deps
Expand All @@ -94,7 +93,6 @@ cd "${SCRIPT_DIR}/deps/modules/emsdk" || die "Could not find Emscripten SDK unde
cd "${SCRIPT_DIR}/deps/modules/emsdk/upstream/emscripten" || die "Could not find Emscripten under ${RED}deps/modules/emsdk/upstream/emscripten${NC}!"
npm install


echo
echo "Disabling unneeded webp features"
cd "${SCRIPT_DIR}/deps/modules/libwebp" || die "Could not find libwebp under ${RED}deps/modules/libwep${NC}!"
Expand Down
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -835,16 +835,19 @@ $(RUNTIME_FFI)/$(RUNTIME_FFI_UNIFFI_BINDINGS)/$(CPLUSPLUS): $(RUNTIME_FFI_SRC)
$(eval $(call DEFINE_TARGET,aarch64-linux-android,aarch64-linux-android,arm64-v8a,arm,aarch64))
$(eval $(call DEFINE_TARGET,armv7-linux-androideabi,armv7a-linux-androideabi,armeabi-v7a,arm,armv7))
$(eval $(call DEFINE_TARGET,x86_64-linux-android,x86_64-linux-android,x86_64,x86_64,x86_64))
$(eval $(call DEFINE_TARGET,i686-linux-android,i686-linux-android,x86,x86,x86))

# Define all android deps builds
$(eval $(call NEW_ANDROID_DEPS_BUILD,AARCH64_LINUX_ANDROID))
$(eval $(call NEW_ANDROID_DEPS_BUILD,ARMV7_LINUX_ANDROIDEABI))
$(eval $(call NEW_ANDROID_DEPS_BUILD,X86_64_LINUX_ANDROID))
$(eval $(call NEW_ANDROID_DEPS_BUILD,I686_LINUX_ANDROID))

# Define all android builds
$(eval $(call NEW_ANDROID_BUILD,AARCH64_LINUX_ANDROID))
$(eval $(call NEW_ANDROID_BUILD,ARMV7_LINUX_ANDROIDEABI))
$(eval $(call NEW_ANDROID_BUILD,X86_64_LINUX_ANDROID))
$(eval $(call NEW_ANDROID_BUILD,I686_LINUX_ANDROID))

# Define all apple targets
$(eval $(call DEFINE_APPLE_TARGET,aarch64-apple-darwin,MAC_ARM64,arm64,arm,aarch64,$(APPLE_MACOSX),$(APPLE_MACOSX_PLATFORM),$(APPLE_MACOSX_SDK)))
Expand Down Expand Up @@ -1022,4 +1025,4 @@ help:
@echo " - $(YELLOW)bench$(NC) - run all benchmarks"
@echo " - $(YELLOW)clippy$(NC) - run clippy on all projects"
@echo
@echo
@echo
Loading