eremitein / treble_manifest_caos

forked from https://github.com/phhusson/treble_manifest/tree/android-10.0
1 stars 3 forks source link

Conflict between phh and lineageOS projects from replace.xml #2

Open joshuarwood opened 3 months ago

joshuarwood commented 3 months ago

First up - I wanted to say great work on CAOS11! I tried a number of ROMs for my phone and this was by far the best.

I'm currently trying to compile CAOS11 v316 from the android source tree in an effort to fix a bug related to the sim card reader on my phone. However, I hit an issue when compiling the DownloadProvider and Camera2 packages. Both of them had undefined symbols. These were:

After doing a little investigation it looks like this is related to a mismatch between the phh 11.0.0_r48 and lineage OS 18.1 dependencies in replace.xml. For example, the downloads classes from phh project platform/frameworks/base do not include the PAUSED_MANUAL or STATUS_PAUSED_MANUAL definitions needed by DownloadProvider, which is pulled from the lineageOS 18.1 github repo. However, these definitions are present in the lineageOS 18.1 version of platform/frameworks/base

See: https://github.com/LineageOS/android_frameworks_base/blob/lineage-18.1/core/java/android/app/DownloadManager.java (defines PAUSED_MANUAL) https://github.com/phhusson/platform_frameworks_base/blob/android-11.0.0_r48-phh/core/java/android/app/DownloadManager.java (does not define PAUSED_MANUAL).

Is this intentional? Do you have another script that applies patches to add missing symbols into the phh frameworks or should I switch to the lineageOS frameworks? Alternatively it looks like I can use the default DownloadProvider and Camera2 packages instead of replacing them.

steps to repeat:

repo init - u https://android.googlesource.com/platform/manifest -b android-11.0.0_r48
git clone --single-branch https://github.com/eremitein/treble_manifest_caos -b v316 .repo/local_manifests
repo sync --force-sync --no-tags --no-clone-bundle --optimized-fetch --prune
cd device/phh/treble
bash generate.sh
cd -
. build/envsetup.sh
lunch treble_arm64_avS-userdebug
make -j4 systemimage
joshuarwood commented 3 months ago

I think I may have found the answer to my issue on gitlab.com. It appears that you have an up-to-date version of treble-patches there might fix these issues: https://gitlab.com/eremitein/treble-patches/-/tree/caosr?ref_type=heads

I'll give the apply patches script a try.