Armbian + KODI (Ubuntu\Debian) for SD & USB & eMMC

Balbes is on vacation, So he will do it once he is back. Even I am waiting to compile 5.3 but it is failing every-time I try.

https://github.com/superna9999/linux/tree/amlogic/v5.3/g12a-integ-5.4 <= the main integration branch that I track and use as the source for my own branch. Uses 5.3-rc1 as the base.

https://github.com/superna9999/linux/tree/linux-5.2-le-amlogic <= has more stuff that LE needs for GX hardware ā€¦ not currently tested by me. Uses 5.3-rc1 as the base

https://github.com/chewitt/linux/tree/narmstrong-5.3-integ-rebase-chewitt <= is my current working branch (Neils integ branch rebased against torvalds/master (5.3-rc4) + commits we need for LE).

In 5.3 the vdec is currently broken. The additional changes for more codecs and G12 support need to be rebased against the now-merged initial driver (which does not support G12 hardware). Itā€™s WIP but might be a few more days.

G12 hardware now has multi-channel audio, although channel mappings are messed up due to issues with eld detection from HDMI. Itā€™s best to stick to 2.0 output until the eld issues are resolved. Itā€™s also something that is being actively worked on.

GX hardware has working multi-channel output again in my branch ā€¦ I found the couple of very hacky commits needed to enable it again yesterday. Long-term a proper audio driver will be written by Baylibre to make the hacky stuff not-needed, but that will take time (end of year maybe).

The above branches are rebased as required. If you use them as sources, donā€™t assume or rely on them being static (especially mine).

1 Like

I have been trying to compile this with the pkgbuild i have been using for 5.0 and 5.2 after making changes to the 5.3 I have been getting errors which i need to look into to compile successfully.

Does these need patches also? Or these are patches already for amlogic socs?

is your buildā€™s target platform mainly vim
1, 2 or 3 finally ? that could help @chewitt to be more precise

Yes its just the VIMs thatsy were looking for amlogic kernels only.

I know little about the Armbian build-system so depending on what the actual ā€œerrorsā€ are? Iā€™m probably not much help. Iā€™m just flagging some 5.3 kernel sources that should be working. Iā€™ve booted VIM1/2/3 on 5.3-rc4 from my own branch in the last 24h so ā€œit works for meā€ and LE. I canā€™t really speak for the other branches but in recent days @narmstrong and I spent time to solve missing patches for audio things so Iā€™d assume theyā€™re good (and at least a good starting point).

I have been following balbes pkgbuild.
https://github.com/150balbes/PKGBUILDs/tree/amlogic/test/linux-vim1
While using his kernel base but I tried neils kernel with 5.3rc1 and it failed on depmod with missing directory and file. Which i believe to be my mistake with the updated Pkgbuild. I will try to share the pkgbuild i have been using and detailed error ones I am at my desk.

Thanks for your response.

Regarding this. I am not building Armbian instead i am just compiling kernel to be used with Manjaro arm tool to make manjaro images.

Hey @chewitt

> DEPMOD  5.3.0-rc1-1
> /usr/sbin/ln: failed to create symbolic link '/build/pkg/linux5-3-vim1/lib/modules/5.3.0-1/extramodules': No such file or directory
> ==> ERROR: A failure occurred in package_linux5-3-vim1().
>     Aborting...
> ==> !!!!! Package failed to build !!!!!
>   -> Cleaning build files from rootfs

I tried commenting the symbolic link in the PKGBUILD as the neilarmstrongs base doesnt have extra module.

then I go the below error.

  DEPMOD  5.3.0-rc1-1
depmod: ERROR: could not open directory /build/pkg/linux5-3-vim1/lib/modules/5.3.0-1: No such file or directory
depmod: FATAL: could not search modules: No such file or directory
==> ERROR: A failure occurred in package_linux5-3-vim1().
    Aborting...
==> !!!!! Package failed to build !!!!!
  -> Cleaning build files from rootfs

maybe @Spikerguy should try to build @chewitt 's kernel 5.3-rc4 from his codebase as this is proven to build (and boot on vim1)ā€¦

Yes will try this tonight hopefully if I get home ealry.
Strit have helped me by compiling the kernel already but it doesnt seem to boot so maybe I need to try to the patches again.

i can give a try: build chewitt kernel and inject it in the sd card flashed from your 5.2 based manjaro image, could that make enough sense to you ?

@chewitt : is this command correct to fetch your said branch source ?
git clone --single-branch --branch amlogic/v5.3/g12a-integ-5.4 https://github.com/superna9999/linux.git

I wonder why the expected result is as much as 6857977 source filesā€¦

EDIT: I finally used the download zip function from the web page : that took less time to proceed the 211484134 bytes of the zip file

https://github.com/chewitt/linux/commits/narmstrong-5.3-integ-rebase-chewitt is based on the branch you indicated but rebased to 5.3-rc4 and including a large collection of patches that LE requires for G12 and GX platforms (Neils integ branch is focussed on G12). Some of the extra patches are already submitted and merged for 5.4, while others are marked as WIP because they either need to be sent to the mailing list or depend on something else being merged first. I have shitty git habits so the branch has been rebased many times in the last few days as I acquire patches and clean commits up so they can be picked ā€¦ and iā€™m not finished with it yet, but itā€™s usually in a working state (YMMV).

git clone -b narmstrong-5.3-integ-rebase-chewitt https://github.com/chewitt/linux

If you download the zip you have the files but no git history to troublshoot from. If it works, great. If it doesnā€™t work itā€™ll be impossible to figure out which commit caused the issue.

3 Likes

Ok, i managed to build something out of branch narmstrong-5.3-integ-rebase-chewitt of GitHub - chewitt/linux: Linux kernel source tree -- WARNING I REBASE MY BRANCHES! commit aea90d .
Using gcc-linaro-aarch64-linux-gnu-7.3.1-2018.05
and replacing chewittā€™s arch/arm64/configs/defconfig (propably copy of fenix/packages/linux-mainline/configs/VIM1.config at master Ā· numbqq/fenix Ā· GitHub) w/ same file from khadasā€™ 5.0.4 kernel tree,
Iā€™ve run, inside the docker env provided w/ fenix 0.7 ā€¦

source env/setenv.sh
cd build/linux-narmstrong-5.3-integ-rebase-chewitt
make ARCH=arm64 defconfig
make -j4 ARCH=arm64 CROSS_COMPILE=/home/khadas/fenix/build/gcc-linaro-aarch64-linux-gnu-7.3.1-2018.05/bin/aarch64-linux-gnu- Image dtbs modules

without errors,
NOTE: I applied no patch
so now, how to reinject/redo all resulting files into a running SD card built w/ your img @Spikerguy ? especially the uInitrd, zImage, etcā€¦ ?

http://paste.ubuntu.com/p/bg5btY36ST/ <= thatā€™s the defconfig iā€™m using (not from fenix). It will be a bit spartan for a desktop distro, but it has all the Amlogic related options youā€™ll need. Note that both lima and panfrost are enabled in the config. The LE build-system auto-disables them for G12 images which use mali_kbase and leaves them enabled for GX images.

1 Like

Try to replace the files like the uImage in boot directory and lib directory and then try it.

I have put chewits branch only compiling. It takes long time for me to compile coz of qemu.

I hope it gets successful this time. I will test and let you if the image works.

thanks to @chewitt as I managed to have a booting manjaro using his kernel 5.3rc4 source code !
come get more details @ Manjaro Linux - Desktop Environment for KVIM1

1 Like

@balbes150 can you advice me on this?
I tried to compile the chewitā€™ss https://github.com/chewitt/linux/tree/narmstrong-5.3-integ-rebase-chewitt and superna9999ā€™s GitHub - superna9999/linux at amlogic/v5.3/vim3
branch with your PKGBUILD but I am getting these above errors.

Please help when you are free.

I didnā€™t understand the question. Write in detail what you want to get.

I tried to compile kernel 5.3-rc4 from chewitts branch using your PKGBUILD Which I have been using for VIM1 with 5.0 and 5.2 kernel.

Getting the following errors

DEPMOD 5.3.0-rc1-1
/usr/sbin/ln: failed to create symbolic link ā€˜/build/pkg/linux5-3-vim1/lib/modules/5.3.0-1/extramodulesā€™: No such file or directory
==> ERROR: A failure occurred in package_linux5-3-vim1().
Abortingā€¦
==> !!! Package failed to build !!!
ā†’ Cleaning build files from rootfs

Then I tired to comment the symbolic link command and tried still I get something similar.
This.

DEPMOD 5.3.0-rc1-1
depmod: ERROR: could not open directory /build/pkg/linux5-3-vim1/lib/modules/5.3.0-1: No such file or directory
depmod: FATAL: could not search modules: No such file or directory
==> ERROR: A failure occurred in package_linux5-3-vim1().
Abortingā€¦
==> !!! Package failed to build !!!
ā†’ Cleaning build files from rootfs

I have checked the kernel name,version, release still this error.