Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LineageOS 19 complains about GmsCore required libraries #13

Closed
waltercool opened this issue Oct 25, 2022 · 7 comments
Closed

LineageOS 19 complains about GmsCore required libraries #13

waltercool opened this issue Oct 25, 2022 · 7 comments

Comments

@waltercool
Copy link

waltercool commented Oct 25, 2022

[  0% 12/44161] Verifying uses-libraries: vendor/partner_gms/GmsCore/GmsCore.apk
FAILED: out/target/common/obj/APPS/GmsCore_intermediates/enforce_uses_libraries.status
/bin/bash -c "(rm -f out/target/common/obj/APPS/GmsCore_intermediates/enforce_uses_libraries.status ) && (build/soong/scripts/manifest_check.py           --enforce-uses-libraries        --enforce-uses-libraries-status out/target/common/obj/APPS/GmsCore_intermediates/enforce_uses_libraries.status      --aapt out/host/linux-x86/bin/aapt      --uses-library com.android.location.provider            --dexpreopt-config out/target/product/beyond1lte/obj/JAVA_LIBRARIES/com.android.location.provider_intermediates/dexpreopt.config            vendor/partner_gms/GmsCore/GmsCore.apk )"
error: mismatch in the <uses-library> tags between the build system and the manifest:
        - required libraries in build system: [com.android.location.provider]
                         vs. in the manifest: [com.android.location.provider]
        - optional libraries in build system: []
                         vs. in the manifest: [androidx.window.extensions, androidx.window.sidecar]
        - tags in the manifest (vendor/partner_gms/GmsCore/GmsCore.apk):
                uses-library:'com.android.location.provider'            uses-library-not-required:'androidx.window.extensions'          uses-library-not-required:'androidx.window.sidecar'
note: the following options are available:
        - to temporarily disable the check on command line, rebuild with RELAX_USES_LIBRARY_CHECK=true (this will set compiler filter "verify" and disable AOT-compilation in dexpreopt)
        - to temporarily disable the check for the whole product, set PRODUCT_BROKEN_VERIFY_USES_LIBRARIES := true in the product makefiles
        - to fix the check, make build system properties coherent with the manifest
        - see build/make/Changes.md for details

@waltercool waltercool changed the title LineageOS complains about GmsCore required libraries LineageOS 19 complains about GmsCore required libraries Oct 25, 2022
@ghost
Copy link

ghost commented Oct 27, 2022

I just ran into this while building microg for LineageOS 18.1.

I see this PR; however being impatient I manually applied the change.

Also ty @mikalackis for the tip about android.permission.MANAGE_USB. I suspect that has saved me some grief.

@ale5000-git
Copy link

This is already fixed by: #12

@GitteHuber
Copy link

Building 19 works fine for me, but building 18.1 fails with

FAILED: ninja: 'out/target/common/obj/JAVA_LIBRARIES/androidx.window.extensions_intermediates/javalib.jar', needed by 'out/target/product/avicii/obj/APPS/GmsCore_intermediates/dexpreopt.zip', missing and no known rule to make it
I'm using the same prebuilts for both build attempts:
<project name="lineageos4microg/android_vendor_partner_gms" path="vendor/partner_gms" remote="github" revision="master" />

Are there any other dependencies that have to met (or repos to be added) in 18.1? Are there device specific differences concerning these new optional dependencies?

@petefoth
Copy link
Contributor

building 18.1 fails with

FAILED: ninja: 'out/target/common/obj/JAVA_LIBRARIES/androidx.window.extensions_intermediates/javalib.jar', needed by 'out/target/product/avicii/obj/APPS/GmsCore_intermediates/dexpreopt.zip', missing and no known rule to make it I'm using the same prebuilts for both build attempts: <project name="lineageos4microg/android_vendor_partner_gms" path="vendor/partner_gms" remote="github" revision="master" />

I'm getting this build error too when I try to build 18.1. Any ideas for fixes or workarounds?

@giovEra
Copy link

giovEra commented Dec 16, 2022

When I build LOS-18.1, I use this Android.mk for the GmsCore, and I have no compile errors and the rom (seems to) work correctly (I am currently building LOS-18.1 for two devices).

@petefoth
Copy link
Contributor

Your Android.mk is missing the two lines added in this commit and this commit to fix the issue with building 19.1

LOCAL_USES_LIBRARIES := com.android.location.provider
LOCAL_OPTIONAL_USES_LIBRARIES := androidx.window.extensions androidx.window.sidecar

So it may be that fixing the 19.1 builds has broke 19.1. I'll experiment and report back

@petefoth
Copy link
Contributor

Yes, the fixes for LOS 19 broke the LOS 18 builds - see #17. That was fixed in #18

Closing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants