microg / android_external_MicroGUiTools

UI helpers used in GmsCore and UnifiedNlp
Apache License 2.0
32 stars 27 forks source link

Compilation failure with Android.mk #10

Open nachtgeist opened 6 years ago

nachtgeist commented 6 years ago

I'm trying to integrate android_packages_apps_UnifiedNlp (non-gms version) into my ROM build as instructed per https://github.com/microg/android_packages_apps_UnifiedNlp/blob/master/README.md#aosp-build-system-integration

However I get these build errors:

FAILED: /bin/bash -c "(rm -rf /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src/R.stamp && mkdir -p /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src/ ) && (mkdir -p /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src ) && (mkdir -p /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/ ) && (/srv/storage/dhr/local/los/src-los/out/host/linux-x86/bin/aapt package --auto-add-overlay --rename-manifest-package com.google.android.gms -z --extra-packages android.support.v7.appcompat:org.microg.nlp:org.microg.tools.ui  --pseudo-localize -m  -J /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src -M /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/AndroidManifest.xml -P /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/public_resources.xml -S packages/apps/UnifiedNlp/unifiednlp-base/src/main/res -S packages/apps/UnifiedNlp/../../../frameworks/support/v7/appcompat/res -S packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res  -I /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/framework-res_intermediates/package-export.apk -I /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/org.cyanogenmod.platform-res_intermediates/package-export.apk -G /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/proguard_options --min-sdk-version 25 --target-sdk-version 25 --version-code 25 --version-name 7.1.2   --skip-symbols-without-default-localization ) && (for GENERATED_MANIFEST_FILE in \`find /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src -name Manifest.java 2> /dev/null\`; do dir=\`awk '/package/{gsub(/\\./,\"/\",\$2);gsub(/;/,\"\",\$2);print \$2;exit}' \$GENERATED_MANIFEST_FILE\`; mkdir -p /srv/storage/dhr/local/los/src-los/out/target/common/R/\$dir; /srv/storage/dhr/local/los/src-los/out/host/linux-x86/bin/acp -fp \$GENERATED_MANIFEST_FILE /srv/storage/dhr/local/los/src-los/out/target/common/R/\$dir; done ) && (for GENERATED_R_FILE in \`find /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src -name R.java 2> /dev/null\`; do dir=\`awk '/package/{gsub(/\\./,\"/\",\$2);gsub(/;/,\"\",\$2);print \$2;exit}' \$GENERATED_R_FILE\`; mkdir -p /srv/storage/dhr/local/los/src-los/out/target/common/R/\$dir; /srv/storage/dhr/local/los/src-los/out/host/linux-x86/bin/acp -fp \$GENERATED_R_FILE /srv/storage/dhr/local/los/src-los/out/target/common/R/\$dir || exit 31; /srv/storage/dhr/local/los/src-los/out/host/linux-x86/bin/acp -fp \$GENERATED_R_FILE /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src/R.stamp || exit 32; done ) && (touch /srv/storage/dhr/local/los/src-los/out/target/common/obj/APPS/NetworkLocation_intermediates/src/R.stamp )"
packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values/themes.xml:19: error: Error retrieving parent for item: No resource found that matches the given name '@style/PreferenceFixTheme.Light.NoActionBar'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:5: error: Error: No resource found that matches the given name: attr 'preferenceTheme'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:8: error: Error retrieving parent for item: No resource found that matches the given name '@style/PreferenceFragment'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:14: error: Error retrieving parent for item: No resource found that matches the given name '@style/PreferenceThemeOverlay.v14.Material'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:15: error: Error: No resource found that matches the given name: attr 'preferenceCategoryStyle'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:17: error: Error: No resource found that matches the given name: attr 'preferenceFragmentCompatStyle'.

packages/apps/UnifiedNlp/../../../external/MicroGUiTools/microg-ui-tools/src/main/res/values-v14/themes.xml:16: error: Error: No resource found that matches the given name: attr 'preferenceFragmentStyle'.

I'm guessing this is due to the dependency on com.takisoft.fix:preference-v6:25.0.0.1 introduced by 4f3d77f9be908150956f247a69015fa2a740b682 which was not also added to Android.mk.

How can this be solved? Thanks!

puffyCid commented 6 years ago

Any more info on this? Its also affecting a ROM I'm trying to build as well Thanks!

nachtgeist commented 6 years ago

The Makefile-integration seems abandoned to me. As a workaround I switched to building this manually via gradle and later on, during the ROM build, just pull in the final .apk.

Jose92 commented 6 years ago

By replacing the package com.takisoft.fix:preference-v6:25.0.0.1 by com.support:preference-v7:25.0.0. It is also necessary to modify the android.mk file to add this dependency Hopefully a correction will be made

TanmayN commented 5 years ago

By replacing the package com.takisoft.fix:preference-v6:25.0.0.1 by com.support:preference-v7:25.0.0. It is also necessary to modify the android.mk file to add this dependency Hopefully a correction will be made

Is there any way you could elaborate on this? I tried replacing the takisoft.fix dependency with the android support library in my build.gradle, but it didn't seem to change anything. I also tried adding the support library to Android.mk in the extra libraries section.