I'm trying to compile an android app in a raspberry. When I use gradlew assembleRelease I get this error. I don't find anything about it on internet...
((
AAPT2 aapt2-7.2.0-7984345-linux Daemon #0: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �@��@8
> :app:mergeReleaseResources @#!@@@����T�T�: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #0: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #0: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: ELF: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #0: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 2: Syntax error: "(" unexpected
AAPT2 aapt2-7.2.0-7984345-linux Daemon #1: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �@��@8
> :app:mergeReleaseResources @#!@@@����T�T�: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #1: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #1: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: ELF: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #1: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 2: Syntax error: "(" unexpected
AAPT2 aapt2-7.2.0-7984345-linux Daemon #2: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �@��@8
> :app:mergeReleaseResources @#!@@@����T�T�: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #2: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: �: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #2: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 1: ELF: not found
AAPT2 aapt2-7.2.0-7984345-linux Daemon #2: Unexpected error output: /root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/aapt2: 2: Syntax error: "(" unexpected
> Task :app:mergeReleaseResources FAILED
Can someone help me? :(
As far as I know, Google does not provide
aapt2binary forarmdevices. You can build your yourself, or use this repository, which contains workflow to build it with Github Actions. Then you can replaceaapt2binary under/root/.gradle/caches/transforms-3/b4396707ed6be3225c88a086a05435f8/transformed/aapt2-7.2.0-7984345-linux/(path from error) with binary matching your architecture.Keep in mind, that Android Gradle Plugin does not use
aapt2binary from sdk's build tools, so we are replacing it in gradle caches directory, not build tools directory.