flutter_charset_detector icon indicating copy to clipboard operation
flutter_charset_detector copied to clipboard

android:attr/lStar not found.

Open sotowang opened this issue 1 year ago • 3 comments

I get this error when i am building my app. the version is flutter_charset_detector: ^3.1.0

Task failed with an exception.
What went wrong:
Execution failed for task ':flutter_charset_detector_android:verifyReleaseResources'.
 A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
  Android resource linking failed
     ERROR:/Users/stw/AndroidStudioProjects/audio_book/build/flutter_charset_detector_android/intermediates/merged_res/release/values/values.xml:194: AAPT: error: resource android:attr/lStar not found.

sotowang avatar Aug 14 '24 10:08 sotowang

Can you provide a minimal reproduction?

Googling around for your error text, it seems to be related to compileSdkVersion and targetSdkVersion. What are your values for these?

amake avatar Aug 18 '24 14:08 amake

Did this fix the problem for you? https://github.com/sotowang/flutter_charset_detector/commit/8146af3349282b6fe9f15b0be63067931283885f

amake avatar Aug 18 '24 14:08 amake

Same error: After upgrade to the latest Flutter SDK 3.24.0 When build APK i got: immagine

And96 avatar Aug 20 '24 08:08 And96

Check https://pub.dev/packages/charset_converter/changelog

with new version 2.2.1: "Fix missing lStar resource for Android with Flutter 3.24 (thanks to moffatman)"

And96 avatar Aug 26 '24 08:08 And96

Fixed my project editing, build.gradle file in this way, adding "subprojects {..." This force all packages to be compiled with 1.8 and sdk 34

If somene need this is the full file build,gradle (in Android directory) https://pastebin.com/2AQ3rcgR

this is the settings.gradle file https://pastebin.com/iUYL1DvQ

this is the build.gradle (in android/app) https://pastebin.com/udBd3UBE

It works perfecly now. With latest flutter version available. 3.24.1 :)

And96 avatar Aug 26 '24 09:08 And96

This should be addressed in flutter_charset_detector_android 3.0.0 / flutter_charset_detector 4.0.0.

amake avatar Aug 26 '24 14:08 amake

For me the problem is solved. You can close the issue.

And96 avatar Aug 26 '24 20:08 And96