155 questions
0
votes
0
answers
49
views
AAPT2 TLS Handshake Failure After Upgrading to Android SDK 35, AGP 8.2.2, and JDK 17 on Windows
I recently upgraded my old Android project (previously targetSdkVersion 28 and compileSdkVersion 28) to API 35.
Here’s what I changed:
1: Installed JDK 17 (Temurin 17.0.18)
2: Installed Android Studio ...
1
vote
1
answer
271
views
aapt2 Error when compile Task ":app:processDebugResources FAILED"
Since I upgrade the Android Studio for API 36 I can't to work with any project without appt2 error at compile. Like below. How I can to fix this?
Thanks.
"Execution failed for task ':app:...
1
vote
1
answer
1k
views
AAPT2 error when upgrading compileSdkVersion and targetSdkVersion from 34 to 35
I'm trying to update my Android project from compileSdkVersion 34 and targetSdkVersion 34 to version 35. However, after updating, my project fails to build and I get the following AAPT2 error in ...
0
votes
0
answers
68
views
Encoding resources to binary on Android
I am in the process of making an app, and have almost finished it but got stuck with making my plaintext AndroidManifest.xml binary on Android itself, I have a Flutter project using some Kotlin code, ...
1
vote
1
answer
945
views
Flutter APK Build Fails: AAPT2 Error - "RES_TABLE_TYPE_TYPE entry offsets overlap actual entry data" for android-35
I am trying to build a Flutter APK using the command:
flutter build apk
But I am getting this error:
* What went wrong:
Execution failed for task ':flutter_plugin_android_lifecycle:...
5
votes
0
answers
734
views
Is it possible to obtain the aapt2 binary file built for the arm64 architecture?
I was trying various methods to use apktool on my Android-based server.
My Android server runs on an arm64 architecture, but when I extracted the aapt2 binary file required for APK building from ...
1
vote
0
answers
125
views
How to disable new JVM resource compiler in Android Gradle plugin for release apk
As per Android Gradle Plugin 4.2.0 (March 2021) release notes
New JVM resource compiler
A new JVM resource compiler in Android Gradle plugin 4.2 tool replaces portions of the AAPT2 resource compiler, ...
2
votes
0
answers
388
views
Android: How to configure stable resource id's with aapt2
In my android app I use custom notification sounds from the raw folder for my notification channels. The sounds are passed to the notification channels as URI with Uri.parse("android.resource://...
0
votes
1
answer
2k
views
Build Failed with Exception AAPT2 aapt2-7.0.0-7396180-osx Daemon #0: Unexpected error during link, attempting to stop daemon
I'm upgrading my application from flutter 2.5.0 to 3.19.0 and continuously getting the same error I have tried with multiple Gradle versions but nothing worked
I have tried different Gradle version ...
3
votes
0
answers
939
views
Android Studio says that "Cannot resolve external dependency because no repositories are defined" despite of I have repositories defined
I imported an app from an old version of eclipse, and after fixing all the problems with the build.gradle, I'm trying to run the app but Android Studio says:
Execution failed for task ':...
0
votes
1
answer
160
views
AndroidManifest.xml:3: error: resource mipmap/launcher_icon (aka com.xyz.dbdb:mipmap/launcher_icon) not found
In the process of generating a .aab file for Google Play Store am trying to run the following command as a part of the process:
aapt2.exe link --proto-format -o base.zip -I android.jar --manifest ...
0
votes
1
answer
659
views
Jenkins -AAPT2 - Daemon startup failed
I'm currently working on automating the APK build process, setting up a Jenkins pipeline for the project. My Jenkins is on a Docker container that has npm, Ionic, OpenJDK, Android SDK, and Gradle ...
0
votes
1
answer
397
views
Getting an error in android studio while launching or building app "Execution failed for task ':app:processDebugResources'"?
My android studio was working perfect and well after I newly installed in my new windows.
I opened android studio about 15 days later (Now) and updated some dependencies. I get this error while ...
3
votes
1
answer
4k
views
AAPT2 aapt2-4.1.0-6503028-osx Daemon #0: Unexpected error during link, attempting to stop daemon
What went wrong:
Execution failed for task ':app:processDebugResources'.
A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
AAPT2 aapt2-4.1.0-6503028-osx ...
2
votes
1
answer
5k
views
AAPT2 aapt2-4.1.3-6503028-osx Daemon #0: Unexpected error during link, attempting to stop daemon. This should not happen under normal circumstances,
React Native version 63.5,
AAPT2 aapt2-4.1.3-6503028-osx Daemon #0: Unexpected error during link, attempting to stop daemon. This should not happen under normal circumstances.
Even after undoing the ...
0
votes
1
answer
990
views
Flutter - Android Studio Flamingo Execution Failed
Execution failed for task ':app:processDebugResources'.
Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
Failed to transform core-1.6.0.aar (androidx.core:core:1.6.0) to ...
1
vote
1
answer
351
views
How to fix: AndroidManifest.xml:26: error: attribute 'android:name'
To build my APK file I run the following command:
/opt/android/build-tools/android-7.0/aapt2 link compiled_res/resources.zip /opt/android/platforms/android-23/android.jar --manifest App-APK/...
3
votes
1
answer
907
views
Problem with AAPT2 - AAPT2 aapt2-7.2.0-7984345-linux Daemon #0: Unexpected error output: �: not found
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: ...
3
votes
0
answers
389
views
Android aapt2 tool fails with "failed to open file: The device does not recognize the command"?
as part of a custom Android build chain, I am calling "aapt2 link" in order to link the files generated by a previous call to "aapt2 compile" together. This works fine on Mac, but ...
0
votes
1
answer
311
views
AAPT: error: invalid resource type 'attr' for parent of style, after updating gradle
After upgrading from Gradle wrapper 4.4.1 to 6.1.1, along with going from Android build tools 2.3.0 to 4.0.0, builds all of a sudden fail with the following error:
res/values/treeview_styles.xml:3:5-6:...
2
votes
1
answer
3k
views
Visual Studio fails to compile .NET MAUI project on Android
When I want to build my .NET MAUI Application on Android, I get this error:
1> C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\33.0.4\tools\Xamarin.Android.Aapt2.targets(212,3): ...
0
votes
1
answer
435
views
Converting standard xml file to formated binary AXMl file
I'm trying to convert a standard XML file
Like
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="30dp"
android:height="30dp"
...
5
votes
1
answer
597
views
why aapt2 does not generate the same ID than aapt? and what the purpose of Ids located inside R.java?
With the equivalent command line, why aapt.exe output different ids than aapt2.exe? also how work exacly the r.java? I use aapt and aapt2 to produce the r.java like this :
"aapt.exe" package ...
0
votes
0
answers
621
views
Get the content from the output APK of aapt2 link
I'm trying to create Android App Bundle (.aab) as it is described here Build your app from the command line.
I first compile the resources:
aapt2 compile res/drawable-hdpi/icon.png -o ...
2
votes
1
answer
292
views
How from aapt2 generate the same ID that was generated by aapt?
For some raison I do not yet understand, aapt and aapt2 do not output the same ID. is their any way to force aapt2 to output the same ID generated by aapt ?
7
votes
2
answers
8k
views
AAPT2 warning about "Unknown chunk type"
I'm building an Android app targeting Android API 33 (Android 13). When I build the app on the command line using gradlew, I see the following warning:
aapt2 W 09-02 02:57:09 6715 6715 LoadedArsc....
1
vote
0
answers
205
views
Android AAPT2 link fails with "conflicting values"
i'm trying to build an Android app referencing the androidx.legacy:legacy-support-v13 package, and unfortunately the AAPT2 link phase always fails for me with these three errors:
values.xml, line 4 — ...
1
vote
1
answer
2k
views
Android Build with command-line tools
I try to understand how a .apk file is built from source code. I know that with Android Studio or with the command gradlew the build can be done easily. The Android Sdk provides multiple tools that ...
3
votes
1
answer
4k
views
Build android inside docker
Im trying do build an android app made with ionic angular inside a docker image built and im getting the following error
The image is build correctly however when i try to run the command
./gradlew ...
3
votes
0
answers
348
views
Error using aapt2 link command with androidx appcompat library
I'm attempting to create Java sources for the R class using aapt2, however it results in errors that I'm having trouble working out how to resolve. The library in question is the androidx appcompat ...
1
vote
1
answer
703
views
Bundletool build-bundle error: Protocol message end-group tag did not match expected tag
I am trying to turn an apk into aab, decompile with apktool, and build with aapt2 and bundletool (all in command line, without gradle).
After decompile, aapt2 compile and link looks good, but when I ...
1
vote
2
answers
2k
views
Jenkins - Execution failed for task ':app:mergeDebugResources'
I am trying to work with Jenkins however I cannot build the apk with it as I am having issue with AAPT2 and Gradle.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for ...
0
votes
1
answer
349
views
aapt2 link errors about resource files not found
While trying to use aapt2 to link some resources, I got this error message error: resource drawable/googleg_standard_color_18 (aka com.google.android.gms.auth.api:drawable/googleg_standard_color_18) ...
0
votes
1
answer
85
views
The data is invalid. (13) . AAPT2 . file missing
One of the autogenerated files (R file) is showing missing while building the project.
ext.kotlin_version = "1.5.0"
classpath 'com.android.tools.build:gradle:4.2.0'
compileSdkVersion 30
...
58
votes
10
answers
100k
views
Android Gradle build error "AAPT2 aapt2-4.1.0-6503028-windows Daemon #0: Unexpected error during link, attempting to stop daemon."
I got this error while trying to build an Android app:
Execution failed for task ':admin:processDebugResources'.
A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$...
0
votes
1
answer
363
views
Error when running the flutter run - AAPT2
I'm trying to implement mercadopago px, but at run time it returns an error
AAPT2 aapt2-4.1.3-6503028-linux Daemon # 2: Unexpected error during compile
I looked for some solutions Link , some say it ...
-2
votes
1
answer
256
views
Aapt does not run on arm architecture
I'm using Nethunter, and the architecture is Linux arm, and I would love to use the apktool tool, I'm studying and reading pentest books, but I can't practice if I don't apply what's there, the ...
0
votes
2
answers
3k
views
Android studio with aapt2 windows problems
Aapt2 error in android studio when generating apk
This problem started as soon as I updated android studio to 4.1.1.
I already uninstalled and installed it, I deleted it gradle I already did several ...
12
votes
4
answers
20k
views
Why is Android Studio failing to build, with an AAPT2 error on images?
After a recent update, Android Studio fails to build an unmodified project with errors along these lines:
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$...
4
votes
1
answer
1k
views
Switch from aapt to aapt2 for native app packaging
We have a great build system, so we're not looking to use gradle. Right now, we use appt to build an APK and it works great and the APK runs well. I see that aapt2 is the future, though, and so we'd ...
6
votes
3
answers
10k
views
Android Studio - Rebuild Project - Could not download aapt2-4.1.0-6503028-windows.jar
This is the configuration I have on my project:
Android Studio 4.1 (September 23, 2020)
Android Gradle Plugin Version 4.1.0
Gradle Version 6.7
Compile SDK 29 (Android 10.0 Q)
Build Tools 29.0.2
Min ...
0
votes
1
answer
406
views
AndroidManifest.xml inside APK is not converted to binary
The apk that I build using gradlew assembleVariant builds OK, but for some reason the AndroidManifest.xml inside the apk is not in binary format. I can open it just fine in a text editor, which is ...
1
vote
0
answers
172
views
Error while running flutter run command in command prompt : [Fatal Error] aapt2-3.5.0-5435860.pom:2:1: Content is not allowed in prolog
flutter run
Launching lib\main.dart on Redmi 8A Dual in debug mode...
Running Gradle task 'assembleDebug'...
[Fatal Error] aapt2-3.5.0-5435860.pom:2:1: Content is not allowed in prolog.
Running Gradle ...
1
vote
0
answers
300
views
What is the proper way to include multiple resource sources with AAPT2?
With the previous AAPT it was possible to include multiple resource sources with the -S parameter as follows:
aapt.exe package -S res -S extract\design\res -S extract\appcompat-v7\res -I "%...
1
vote
0
answers
2k
views
My every project build error Execution failed for task ':app:processDebugResources'
My every project build error AAPT2 process unexpectedly exit since a week. I don't know why?
I tried almost every solution on internet.
I also reinstall my windows 10 and Android studio.
Still the ...
1
vote
0
answers
521
views
Why aapt2 generate compile error "Check failed"?
I'm running AAPT2 from the command line:
%PATH_AAPT2%\aapt2.exe compile -v --dir res -o build
Many resource files are compiled. But after a time aapt2 is aborting with the message
Check failed: ...
0
votes
1
answer
501
views
process unexpectedly exit , AAPT2 errors
The actual problem is that the syncing process is going great without any errors.But after sync was successful when i try to build the app, there are 2 errors shown:
A failure occurred while executing ...
0
votes
0
answers
246
views
Running Gradle task 'assembleDebug'... [Fatal Error] aapt2-3.5.0-5435860.pom:2:1: Content is not allowed in prolog
No errors when flutter doctor command was executed. I tried with updating Gradle with the latest version 6.4 and setting at env variable path as well, in the dist folder as well it is showing ...
11
votes
6
answers
18k
views
Android studio AAPT: error failed writing to R.txt: the data is invalid
I am having an issue with building new projects on android studio. I keep on getting the error:
Execution failed for task ':app:processDebugResources'.
> A failure occurred while executing com....
0
votes
0
answers
120
views
Differences on generating PNG from XML by gradle
In my project I have xml drawable with gradient and aapt tag
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:width="...