redroid-doc icon indicating copy to clipboard operation
redroid-doc copied to clipboard

Build Redroid 14 with MindTheGapps "upsilon" will encounter "unrecognized property 'preprocessed'" ERROR

Open titusbiao opened this issue 1 year ago • 2 comments

Hello,

Following the "Build Redroid with Docker" document, I can successfully build my Redroid 12 with MindTheGapps "sigma". Also, following this instruction to ignore one paragraph, I can successfully build my Redroid 13 with MindTheGapps "tau".

Now I try to build Redroid 14 (14.0.0_r21) with MindTheGapps "upsilon". Ooops! New problem occurs! It will prompt:

error: vendor/gapps/arm/Android.bp:15:14: unrecognized property "preprocessed"
error: vendor/gapps/arm/Android.bp:28:14: unrecognized property "preprocessed"
error: vendor/gapps/arm/Android.bp:41:14: unrecognized property "preprocessed"
error: vendor/gapps/arm/Android.bp:53:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:14:14: unrecognized property "preprocessed"
error: vendor/gapps/arm/Android.bp:65:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:26:14: unrecognized property "preprocessed"
error: vendor/gapps/x86_64/Android.bp:15:14: unrecognized property "preprocessed"
error: vendor/gapps/arm/Android.bp:79:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:38:14: unrecognized property "preprocessed"
error: vendor/gapps/x86_64/Android.bp:28:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:50:14: unrecognized property "preprocessed"
error: vendor/gapps/x86_64/Android.bp:41:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:63:14: unrecognized property "preprocessed"
error: vendor/gapps/x86_64/Android.bp:55:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:76:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:89:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:15:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:28:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:41:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:53:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:65:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:77:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:91:14: unrecognized property "preprocessed"
error: vendor/gapps/arm64/Android.bp:105:14: unrecognized property "preprocessed"
error: vendor/gapps/x86/Android.bp:15:14: unrecognized property "preprocessed"
error: vendor/gapps/x86/Android.bp:28:14: unrecognized property "preprocessed"
error: vendor/gapps/x86/Android.bp:41:14: unrecognized property "preprocessed"
error: vendor/gapps/x86/Android.bp:55:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:109:14: unrecognized property "preprocessed"
error: vendor/gapps/common/Android.bp:122:14: unrecognized property "preprocessed"
13:14:55 soong bootstrap failed with: exit status 1

#### failed to build some targets (04:04 (mm:ss)) ####

When we look at the Android.bp (several places, /arm, /arm64/, /common/, /x86/, /x86_64/) in the official MindTheGapps "upsilon" Gitlab repository, we can find such "preprocessed: true," lines.

Then, following comment by @jimtangshfx at #660, (1) I use the following commands to delete all the lines containing "preprocessed: true," :

sed -i '/preprocessed/d' ~/redroid/vendor/gapps/common/Android.bp
sed -i '/preprocessed/d' ~/redroid/vendor/gapps/arm/Android.bp
sed -i '/preprocessed/d' ~/redroid/vendor/gapps/arm64/Android.bp
sed -i '/preprocessed/d' ~/redroid/vendor/gapps/x86/Android.bp
sed -i '/preprocessed/d' ~/redroid/vendor/gapps/x86_64/Android.bp

(2)Echo the command:

echo "BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true" >> device/redroid/redroid_x86_64/BoardConfig.mk
echo "BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true" >> device/redroid/redroid_x86_64_only/BoardConfig.mk
echo "BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true" >> device/redroid/redroid_arm64/BoardConfig.mk
echo "BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true" >> device/redroid/redroid_arm64_only/BoardConfig.mk

However, when I start to build, the system will HANG OUT as this:

titusbiao@redroid-builder:/src$ m -j$(nproc)
06:30:50 Build sandboxing disabled due to nsjail error.
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=14
PRODUCT_INCLUDE_TAGS=com.android.mainline
TARGET_PRODUCT=redroid_arm64
TARGET_BUILD_VARIANT=userdebug
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=generic
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=generic
HOST_OS=linux
HOST_OS_EXTRA=Linux-6.8.0-1010-gcp-x86_64-Ubuntu-20.04.6-LTS
HOST_CROSS_OS=windows
BUILD_ID=UQ1A.240105.004.A1
OUT_DIR=out
============================================
[ 99% 413/414] test android/soong/apex
   32:14 analyzing Android.bp files and generating ninja file at out/soong/build.ninja

What shall I do? Just wait? Or is there anything wrong?

Many thanks,

titusbiao avatar Jul 23 '24 07:07 titusbiao

Here are some alternatives:

  1. https://github.com/ayasa520/redroid-script Build your Redroid 14 release without any references to GApps (remove the ~/redroid/vendor/gapps folder, the mindthegapps.xml manifest and any references to it in the .mk files) and then use the redroid-script to install GApps into the finalized container (you must modify it a little to use your redroid14 container).

  2. https://github.com/opengapps/aosp_build Try OpenGApps instead of MindTheGApps https://github.com/remote-android/redroid-doc/issues/48#issuecomment-1076246868

brunoaduarte avatar Jul 23 '24 07:07 brunoaduarte

Here are some alternatives:

  1. https://github.com/ayasa520/redroid-script Build your Redroid 14 release without any references to GApps (remove the ~/redroid/vendor/gapps folder, the mindthegapps.xml manifest and any references to it in the .mk files) and then use the redroid-script to install GApps into the finalized container (you must modify it a little to use your redroid14 container).
  2. https://github.com/opengapps/aosp_build Try OpenGApps instead of MindTheGApps How can I flash GApps/Magisk? #48 (comment)

Many thanks, and I'll have a try in solution 1.

For solution 2, OpenGApps only up to Android 11......and, we're talking about Android 14......So, except MindTheGapps, any ideas on NikGApps or BiTGApps?

titusbiao avatar Jul 23 '24 07:07 titusbiao