Closed interstates21 closed 2 months ago
Guten Tag, Hans here! 🍻
Thank you for reporting ze issue. It looks like you encountered a build error after updating to v4.5.3. However, I need to ask you to try building ze VisionCamera Example app to see if ze issue persists there. It helps us understand if it's related to our library or your specific setup.
Also, please provide ze full build logs in case this happens again, so mrousavy can better diagnose ze problem. To capture logs, you can use adb logcat
for Android.
If you find this repository helpful and want ze issue to get more attention, consider sponsoring mrousavy here. Your support is always appreciated!
Note: If you think I made a mistake, please ping
@mrousavy
to take a look.
Even I am facing this issue with 4.5.3. Switching to 4.5.1 and modifying camerax_version
from 1.5.0-alpha01
to 1.4.0-rc01
helped me build my app.
@DragonDare please help to modifying camerax_version where this page located and please share screen
getting error when make production build
* What went wrong:
Execution failed for task ':app:packageStagingReleaseBundle'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.PackageBundleTask$BundleToolWorkAction
> Unrecognized native architecture for directory 'lib/riscv64'.
i downgraded library from 4.5.3 to 4.5.2
i face this error when trying to upload the app to Play Store v4.5.2 and v4.5.3 the error is : 'riscv64' architecture is only supported for application targeting WearOS.
@DragonDare please help to modifying camerax_version where this page located and please share screen
getting error when make production build
* What went wrong: Execution failed for task ':app:packageStagingReleaseBundle'. > A failure occurred while executing com.android.build.gradle.internal.tasks.PackageBundleTask$BundleToolWorkAction > Unrecognized native architecture for directory 'lib/riscv64'.
i downgraded library from 4.5.3 to 4.5.2
Steps:
"react-native-vision-camera": "4.5.1"
. Change version to 4.5.1 in package.json.node_modules\react-native-vision-camera\android\build.gradle
and change line 185 to def camerax_version = "1.4.0-beta02"
.Gradle clean and try to build again. should work
go to your cache folder /Users/oleksiikupin/.gradle/caches/transforms-3//transformed/jetified-camera-core-1.5.0-alpha01/
and delete the riscv64
folder in jni
folder
another way is using target ABI when build but I haven't tried it yet
source and explanation:
https://stackoverflow.com/questions/78609800/agp-8-0-so-is-not-an-abi-for-3rd-party-library
https://stackoverflow.com/questions/76753627/how-to-fix-android-project-build-failing-with-so-is-not-an-abi
https://issuetracker.google.com/issues/279516850
I am pretty sure this is not a VisionCamera issue. CameraX is just already ready for RISCv64, while some other native libs (like RN) are not.
Add this to your app's build.gradle:
android {
// ..
defaultConfig {
// ..
ndk {
abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64"
}
@DragonDare please help to modifying camerax_version where this page located and please share screen getting error when make production build
* What went wrong: Execution failed for task ':app:packageStagingReleaseBundle'. > A failure occurred while executing com.android.build.gradle.internal.tasks.PackageBundleTask$BundleToolWorkAction > Unrecognized native architecture for directory 'lib/riscv64'.
i downgraded library from 4.5.3 to 4.5.2
Steps:
"react-native-vision-camera": "4.5.1"
. Change version to 4.5.1 in package.json.- yarn/npm install.
- Go to
node_modules\react-native-vision-camera\android\build.gradle
and change line 185 todef camerax_version = "1.4.0-beta02"
.Gradle clean and try to build again. should work
Thanks it's work for me ❤️
i have the same problem
I am pretty sure this is not a VisionCamera issue. CameraX is just already ready for RISCv64, while some other native libs (like RN) are not.
Add this to your app's build.gradle:
android { // .. defaultConfig { // .. ndk { abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64" }
This didn't work. Still getting the `
jni extracted from path E:.gradle\caches\transforms-3\59932ef85550e6bd54309370421ab708\transformed\jetified-camera-core-1.5.0-alpha01\jni\riscv64\libimage_processing_util_jni.so is not an ABI` error
go to your cache folder
/Users/oleksiikupin/.gradle/caches/transforms-3//transformed/jetified-camera-core-1.5.0-alpha01/
and delete theriscv64
folder injni
file another is using target ABI when build but I haven't tried it yet source and explanation: https://stackoverflow.com/questions/78609800/agp-8-0-so-is-not-an-abi-for-3rd-party-library https://stackoverflow.com/questions/76753627/how-to-fix-android-project-build-failing-with-so-is-not-an-abi https://issuetracker.google.com/issues/279516850
This, however worked! Thank You! Now I can use the latest version of vision camera (4.5.3) as well.
I am pretty sure this is not a VisionCamera issue. CameraX is just already ready for RISCv64, while some other native libs (like RN) are not.
Add this to your app's build.gradle:
android { // .. defaultConfig { // .. ndk { abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64" }
it didn't work for me either
@DragonDare please help to modifying camerax_version where this page located and please share screen getting error when make production build
* What went wrong: Execution failed for task ':app:packageStagingReleaseBundle'. > A failure occurred while executing com.android.build.gradle.internal.tasks.PackageBundleTask$BundleToolWorkAction > Unrecognized native architecture for directory 'lib/riscv64'.
i downgraded library from 4.5.3 to 4.5.2
Steps:
"react-native-vision-camera": "4.5.1"
. Change version to 4.5.1 in package.json.- yarn/npm install.
- Go to
node_modules\react-native-vision-camera\android\build.gradle
and change line 185 todef camerax_version = "1.4.0-beta02"
.Gradle clean and try to build again. should work
Indeed! This solution works. It is extremely effective.
i have the same problem
@DragonDare please help to modifying camerax_version where this page located and please share screen getting error when make production build
* What went wrong: Execution failed for task ':app:packageStagingReleaseBundle'. > A failure occurred while executing com.android.build.gradle.internal.tasks.PackageBundleTask$BundleToolWorkAction > Unrecognized native architecture for directory 'lib/riscv64'.
i downgraded library from 4.5.3 to 4.5.2
Steps:
"react-native-vision-camera": "4.5.1"
. Change version to 4.5.1 in package.json.- yarn/npm install.
- Go to
node_modules\react-native-vision-camera\android\build.gradle
and change line 185 todef camerax_version = "1.4.0-beta02"
.Gradle clean and try to build again. should work
Indeed! This solution works. It is extremely effective.
Oh!!, Thankss It Workedd for me.
go to your cache folder
/Users/oleksiikupin/.gradle/caches/transforms-3//transformed/jetified-camera-core-1.5.0-alpha01/
and delete theriscv64
folder injni
folder another way is using target ABI when build but I haven't tried it yet source and explanation: https://stackoverflow.com/questions/78609800/agp-8-0-so-is-not-an-abi-for-3rd-party-library https://stackoverflow.com/questions/76753627/how-to-fix-android-project-build-failing-with-so-is-not-an-abi https://issuetracker.google.com/issues/279516850
Thankss.
I'm facing an issue when trying to build my Expo project using EAS. The build works fine locally after applying a solution suggested by @DragonDare , but when I try to submit the project to EAS, I encounter the following error:
`FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':app:mergeReleaseNativeLibs'.
jni extracted from path /home/expo/.gradle/caches/transforms-3/707afcf529a3c4be15bcde4b3c1b766c/transformed/jetified-camera-core-1.5.0-alpha01/jni/riscv64/libimage_processing_util_jni.so is not an ABI
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. Get more help at https://help.gradle.org.
BUILD FAILED in 9m 26s
Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0. You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins. For more on this, please refer to https://docs.gradle.org/8.3/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.
1109 actionable tasks: 1109 executed Error: Gradle build failed with unknown error. See logs for the "Run gradlew" phase for more information. `
If someone also don't want to manually change the build.gradle file. Version 4.3.2
works for me without any flaws and it seems to be the last version where node_modules\react-native-vision-camera\android\build.gradle
has def camerax_version = "1.4.0-beta02"
. Thanks for finding the fix @DragonDare ✌🏼
Thanks, guys, downgrading from "react-native-vision-camera": "^4.5.3"
to 4.5.1
worked without any additional changes.
How were you trying to build the app?
I updated react-native-vision-camera to v4.5.3 the app crashes at a build time on android.
Downgrading to v4.5.1 solves the issue
Full build logs
Project dependencies
VisionCamera Version
4.5.3
Target platforms
Android
Operating system
MacOS
Can you build the VisionCamera Example app?
I didn't try (⚠️ your issue might get ignored & closed if you don't try this)
Additional information