xiaomi-mt6853-devs/android_device_xiaomi_cannon

lineageOS 20 Build Source error when I use the device cannon

Closed this issue · 12 comments

snyyns commented

1701847570513

when i comment these codes in device/xiaomi/cannon/device.mk appear these errors (these packages do not find in phone,so i comment)

[ 1% 264/15154] //system/sepolicy:recovery_sepolicy.cil Building cil for recovery_sepolicy.cil
FAILED: out/soong/.intermediates/system/sepolicy/recovery_sepolicy.cil/android_common/recovery_
sepolicy.cil
out/host/linux-x86/bin/checkpolicy -C -M -c 30 -o out/soong/.intermediates/system/sepolicy/reco
very_sepolicy.cil/android_common/recovery_sepolicy.cil out/soong/.intermediates/system/sepolicy
/recovery_sepolicy.conf/android_common/recovery_sepolicy.conf # hash of input list: a316674d1dc
0868a105f79e687a4b6449e6a8801cfa3253b9c426787c1c40d09
device/xiaomi/cannon/sepolicy/vendor/hal_power_default.te:7:ERROR 'unknown type vendor_power_pr
op' at token ';' on line 91073:
#line 7
allow hal_power_default vendor_power_prop:property_service set;
checkpolicy: error(s) encountered while parsing configuration

Would you please tell me how to solve this problem?

Read the error message, it's pretty clear

snyyns commented

But this te file is similar to the te file of other device trees, and also does not define this vendor_power_prop type.

snyyns commented

If I add this additional vendor_power_prop type, there will be other errors, I think it should be deviated from the core of the problem

snyyns commented

Read the error message, it's pretty clear

Would you please tell me how to solve this problem?

You haven't cloned all dependencies, read your errors and also lineage.dependencies file in the tree

i'm having the same problem. i've checked the dependencies and i'm getting the same error.

Steps to reproduce the error:

git clone https://github.com/xiaomi-mt6853-devs/android_device_xiaomi_cannon device/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_kernel_xiaomi_cannon kernel/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_vendor_xiaomi_cannon vendor/xiaomi/cannon
git clone https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr device/mediatek/sepolicy_vndr  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_mediatek hardware/mediatek  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_xiaomi hardware/xiaomi -b lineage-20

source build/envsetup.sh
lunch lineage_cannon-userdebug
brunch lineage_cannon-userdebug

The original poster

i'm having the same problem. i've checked the dependencies and i'm getting the same error.

Steps to reproduce the error:

git clone https://github.com/xiaomi-mt6853-devs/android_device_xiaomi_cannon device/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_kernel_xiaomi_cannon kernel/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_vendor_xiaomi_cannon vendor/xiaomi/cannon
git clone https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr device/mediatek/sepolicy_vndr  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_mediatek hardware/mediatek  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_xiaomi hardware/xiaomi -b lineage-20

source build/envsetup.sh
lunch lineage_cannon-userdebug
brunch lineage_cannon-userdebug

OP has dependency issues, they're probably missing hardware/mediatek. About the sepolicy issues I'll check it out. I have no issues on my side with LineageOS 20

Issue is obvious @gsuzeda, you're not using mediatek sepolicy from LineageOS org. Read lineage.dependencies same for @snyyns.

snyyns commented

Issue is obvious @gsuzeda, you're not using mediatek sepolicy from LineageOS org. Read lineage.dependencies same for @snyyns.

Excuse me, has this problem been solved? The type cannot be found
device/xiaomi/cannon/sepolicy/vendor/hal_power_default.te:7:ERROR 'unknown type vendor_power_prop' at token ';' on line 91077:
#line 7

snyyns commented

i'm having the same problem. i've checked the dependencies and i'm getting the same error.

Steps to reproduce the error:

git clone https://github.com/xiaomi-mt6853-devs/android_device_xiaomi_cannon device/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_kernel_xiaomi_cannon kernel/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_vendor_xiaomi_cannon vendor/xiaomi/cannon
git clone https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr device/mediatek/sepolicy_vndr  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_mediatek hardware/mediatek  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_xiaomi hardware/xiaomi -b lineage-20

source build/envsetup.sh
lunch lineage_cannon-userdebug
brunch lineage_cannon-userdebug

Please use this git.
Https://github.com/LineageOS/android_device_mediatek_sepolicy_vndr.git.
Not this.
Https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr.git

I'm closing this, there is no issue with the source

i'm having the same problem. i've checked the dependencies and i'm getting the same error.
Steps to reproduce the error:

git clone https://github.com/xiaomi-mt6853-devs/android_device_xiaomi_cannon device/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_kernel_xiaomi_cannon kernel/xiaomi/cannon  -b lineage-20
git clone https://github.com/xiaomi-mt6853-devs/android_vendor_xiaomi_cannon vendor/xiaomi/cannon
git clone https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr device/mediatek/sepolicy_vndr  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_mediatek hardware/mediatek  -b lineage-20
git clone https://github.com/LineageOS/android_hardware_xiaomi hardware/xiaomi -b lineage-20

source build/envsetup.sh
lunch lineage_cannon-userdebug
brunch lineage_cannon-userdebug

Please use this git. Https://github.com/LineageOS/android_device_mediatek_sepolicy_vndr.git. Not this. Https://github.com/xiaomi-mt6853-devs/android_device_mediatek_sepolicy_vndr.git

That is helpful, thanks.