Reputation: 210
I am fairly new to expo and i took over a mobile app project which started as a native app and then expo and RN was integrated on top of it. I am building a Jenkins pipeline and i've been stuck with this issue for more than one week now. The build fails with this error:
Execution failed for task ':expo-modules-core:configureCMakeRelWithDebInfo[arm64-v8a]'.
Unfortunately this is all i got, i tried to remove the env variable by calling "unset JAVA_TOOL_OPTIONS" before starting the build but it's not working at all. The build is running successfully on my local device (m1 mac) but it doesn't on the pipeline. I'm using jenkins to run a docker container and run the build from there.
Here's the result of expo-env-info:
OS: Linux 5.10 Debian GNU/Linux 11 (bullseye) 11 (bullseye)
Shell: 5.1.4 - /bin/bash 12:53:34
Binaries: 12:53:34
Node: 17.9.0 - ~usr/bin/node 12:53:34
Yarn: 3.4.1 - ~usr/bin/yarn 12:53:34
npm: 8.5.5 - ~usr/bin/npm 12:53:34
npmPackages: 12:53:34
u/expo/metro-config: ^0.10.7 => 0.10.7 12:53:34
expo: 49.0.10 => 49.0.10 12:53:34
react: 18.2.0 => 18.2.0 12:53:34
react-dom: 18.2.0 => 18.2.0 12:53:34
react-native: 0.72.4 => 0.72.4 12:53:34
Expo Workflow: managed
If someone has any clue of what should i do, it will be greatly appreciated, as i'm becoming quite desperate.
Cheers
Upvotes: 1
Views: 506
Reputation: 210
Well, after a few months i was able to find the solution, as simple as it may sound. the problem lied in the "Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8", so in the past i tried to unset this variable via "unset JAVA_TOOL_OPTIONS".
This was in a fastlane pipeline (yes, the jenkins pipeline runs a fastlane pipeline) little did i know that doing
"sh unset JAVA_TOOL_OPTIONS"
and
"sh ./gradlew assembleProductionRelease"
Didn't work in some way, so i had to chain the two commands in one.
So "sh unset JAVA_TOOL_OPTIONS && ./gradlew assembleProductionRelease"
actually works. :)
Upvotes: 0