-
Notifications
You must be signed in to change notification settings - Fork 264
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
M1 support in ndk-build script #1410
Comments
M1 native support is not ready yet. See #1299. In the mean time you can try to run ndk-build with rosetta2 like: |
error when building with ndkBuild using /Users/mac/Desktop/Consumer-Android/ime/dictionaries/jnidictionaryv2/Android.mk: Build command failed. @hhb how to resolve this issue.? |
Did you try using Rosetta? |
no rosetta for android studio. |
Rosetta is something you install yourself. It's part of macOS, not Studio. |
You will still need rosetta for ndk-build for a little while longer as many of the components listed in #1299 still need fat binaries, but that fix will resolve an ndk-build issue with rosetta. Plan is to have everything in the NDK be fixed to not require rosetta by the time r24 reaches stable (and a lot will be backported to r23). |
For the upcoming r24, we currently have these components as universal binaries: LLVM, make, python3, and shader-tools. The NDK package still needs yasm and simpleperf migrated. CMake and Ninja are shipped independently of the NDK, and they're in progress. (I have them building as universal binaries already, but we need to upgrade the CMake version in the SDK.) |
issue is resolved just changed ndk-build script mentioned in answer https://stackoverflow.com/questions/69541831/unknown-host-cpu-architecture-arm64-android-ndk-siliconm1-apple-macbook-pro |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Should be fixed in r23 build 8486889. |
Also: Remove the special logic for 32-bit x86 on Linux, Darwin, and Windows. The NDK doesn't support any 32-bit hosts anymore. Bug: android/ndk#1410 Test: python3 ./checkbuild.py on M1 macOS (make sure the python3 runs as arm64. It will run /bin/bash as arm64, then `uname -m` as arm64.) Change-Id: If6588b61c74779016a22dc6cada814cd4c6a77f5 (cherry picked from commit b542853) Merged-In: If6588b61c74779016a22dc6cada814cd4c6a77f5
Bug: android/ndk#1410 Test: None Change-Id: Ib315e3a85b3e952ecb7cea8d2351af2f841d8cce (cherry picked from commit a27f773c17e18c41f8075abb06f7bbd35dcb2d3b) Merged-In: Ib315e3a85b3e952ecb7cea8d2351af2f841d8cce
Also: Remove the special logic for 32-bit x86 on Linux, Darwin, and Windows. The NDK doesn't support any 32-bit hosts anymore. Bug: android/ndk#1410 Test: python3 ./checkbuild.py on M1 macOS (make sure the python3 runs as arm64. It will run /bin/bash as arm64, then `uname -m` as arm64.) Change-Id: If6588b61c74779016a22dc6cada814cd4c6a77f5
Bug: android/ndk#1410 Test: None Change-Id: Ib315e3a85b3e952ecb7cea8d2351af2f841d8cce
在Mac M1上使用NDK
export NDK_HOME=/Users/xxx/Library/Android/ndk/android-ndk-r22
export PATH=$NDK_HOME:$PATH
然后运行 ndk-build 的时候报错 ERROR: Unknown host CPU architecture: arm64
是否是不支持Mac M1?
The text was updated successfully, but these errors were encountered: