lineage-rpi / android_kernel_brcm_rpi

Other
217 stars 63 forks source link

error building lineage-19.1 and lineage-18.1 on 'ARCH=arm' #29

Closed fellow99 closed 2 years ago

fellow99 commented 2 years ago

Describe the bug

$ ARCH=arm CROSS_COMPILE=/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi- make lineageos_rpi4_defconfig HOSTCC scripts/basic/fixdep HOSTCC scripts/kconfig/conf.o HOSTCC scripts/kconfig/confdata.o HOSTCC scripts/kconfig/expr.o LEX scripts/kconfig/lexer.lex.c YACC scripts/kconfig/parser.tab.[ch] HOSTCC scripts/kconfig/lexer.lex.o HOSTCC scripts/kconfig/parser.tab.o HOSTCC scripts/kconfig/preprocess.o HOSTCC scripts/kconfig/symbol.oSS HOSTCC scripts/kconfig/util.o HOSTLD scripts/kconfig/conf scripts/Kconfig.include:43: gold linker '/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi-ld' not supported make[1]: [scripts/kconfig/Makefile:88: lineageos_rpi4_defconfig] Error 1 make: [Makefile:619: lineageos_rpi4_defconfig] Error 2

Steps to reproduce the behaviour

  1. ARCH=arm CROSS_COMPILE=/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi- make clean
  2. ARCH=arm CROSS_COMPILE=/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi- make lineageos_rpi4_defconfig

Device (s)

Raspberry Pi 4 Mod. B

System

Ubuntu 20.04

Logs

No response

Additional context

No response

fellow99 commented 2 years ago

It's ok to build lineage-19.1/18.1 on arm64. Also it is ok to build lineage-17.1/16.0 on arm.

But I strongly need lineage-19.1 on arm, on which I would add SIM7600 HAT supports.

KonstaT commented 2 years ago

There is no 32-bit builds of LineageOS 19 for the Pi 4 so 32-bit kernel build is not supported either.

You can copy arch/arm64/configs/lineageos_rpi4_defconfig to arch/arm/configs/lineageos_rpi4_defconfig and regenerate it with ARCH=arm CROSS_COMPILE=/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi- make lineageos_rpi4_defconfig. It will likely compile but you're not going to do much with the kernel as the Android image is 64-bit and requires 64-bit kernel.

What exactly are you trying to do with the SIM7600 HAT?

fellow99 commented 2 years ago

What exactly are you trying to do with the SIM7600 HAT? I am trying to make a CarPlay device using RPI + SIM7600 + LineageOS + Baidu CarLife. It is hard but I think it will work.

fellow99 commented 2 years ago

There is no 32-bit builds of LineageOS 19 for the Pi 4 so 32-bit kernel build is not supported either.

You can copy arch/arm64/configs/lineageos_rpi4_defconfig to arch/arm/configs/lineageos_rpi4_defconfig and regenerate it with ARCH=arm CROSS_COMPILE=/data/arm-linux-androideabi-4.9/bin/arm-linux-androideabi- make lineageos_rpi4_defconfig. It will likely compile but you're not going to do much with the kernel as the Android image is 64-bit and requires 64-bit kernel.

I got SIM7600's libs only on 32bits. Unfortunately I found that only lineageos 19.1 contains Calls and SMS and SIM functions.

Another way is: How to open up Calls and SMS and SIM functions at lineageos 16/17?

KonstaT commented 2 years ago

Do you have Android specific drivers for that hardware (you can't use libraries for regular distros as Android uses it's own C-library - glibc vs. bionic)? You would need hw specific rild and libril at least.

Some reference on the Android telephony stack as the official Android documentation seems to be missing this. https://lineageos.org/engineering/Telephony/ https://wladimir-tm4pda.github.io/porting/telephony.html (old as it's missing HIDL layer)

No, all my public releases are configured as wifi only tablet so they don't even have Android telephony framework. I have builds that have support Sixfab modem HAT and Quectel EC25. LTE data and SMS works fine. It's also possible to make/receive calls but in-call audio is not working. It's not something that I plan to include in public releases as practically no one has the hardware.

fellow99 commented 2 years ago

Thank you for your docs. I have got SIM7600's Android drivers and related docs, based on Android 7/8/9. Right now I am learning to build Full LineageOS, and trying to add Android modules like telephony framework.