[FIXED] Gradle suddenly doesn't build Arm8Release any more

Issue

When I say

./gradlew installArm8Release

I get this error:

:app:generateJsonModelArm8Release UP-TO-DATE
:app:externalNativeBuildArm8Release FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:externalNativeBuildArm8Release'.
> java.io.FileNotFoundException: D:\TestApp\app\.externalNativeBuild\cmake\arm8Release\arm64-v8a\android_gradle_build.json (The system cannot find the file specified)

I believe my Gradle configuration has somehow been corrupted because as you can see it says on :app:generateJsonModelArm8Release that it is up to date but as you can see from the error below android_gradle_build.json isn’t there at all.

The following line works fine, though:

./gradlew installArm7Release

It’s only Arm8Release that fails although it used to work before. This makes me think that somehow something got corrupted. I have already tried the following:

./gradlew clean
./gradlew cleanBuildCache

All to no avail. It refuses to build the Arm8Release target. I have also tried deleting the .externalNativeBuild directory and running

./gradlew wrapper

again. But it didn’t solve the issue either.

I have also rebooted the system to make sure any gradle daemon is gone but the error is still there.

I’m pretty much out of ideas now. All targets are working fine except Arm8Release. What else can I try?

Solution

Just for the record: Deleting really everything from my build directory except the source and resource files solved this issue. So it seems like

./gradlew clean
./gradlew cleanBuildCache

doesn’t really clean everything

Answered By – Andreas

Answer Checked By – Timothy Miller (Easybugfix Admin)

Leave a Reply

(*) Required, Your email will not be published