iyegoroff / react-native-image-filter-kit

Various image filters for iOS & Android
MIT License
317 stars 42 forks source link

Library doesn't build on `arm64` with `buildToolsVersion` > 33 (RN 0.71) #140

Open inssein opened 1 year ago

inssein commented 1 year ago

Just creating an issue before I get a chance to dive in, but currently getting this error when building with RN 0.71 on and M1 mac:

dyld[82242]: Library not loaded: @rpath/libclang_android.dylib
  Referenced from: <C2603478-F6A1-3EC6-AD02-674D107403F2> /Users/inssein/Library/Android/sdk/build-tools/33.0.1/llvm-rs-cc
  Reason: tried: '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/../lib64/libclang_android.dylib' (no such file), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/lib64/libclang_android.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/../lib64/libclang_android.dylib' (no such file), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/lib64/libclang_android.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')), '/System/Volumes/Preboot/Cryptexes/OS@rpath/libclang_android.dylib' (no such file), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/../lib64/libclang_android.dylib' (no such file), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/lib64/libclang_android.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/../lib64/libclang_android.dylib' (no such file), '/Users/inssein/Library/Android/sdk/build-tools/33.0.1/lib64/libclang_android.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')), '/usr/lib/libclang_android.dylib' (no such file, not in dyld cache)

The current workaround seems to be to fallback to buildToolsVersion of 32.0.0.

AlbinNewSeed commented 1 year ago

Getting this error as well. App builds on windows machine but not on m1 Mac. Did you solve it?

ricardopetrere commented 3 months ago

Same here, as well as @AlbinNewSeed 's answer. Reverted Build Tools to 32.0.0 no my Mac, now it worked