TinkerBoard2/kernel

Kernel build error in rockchip_wlan, wireless, and net

SereneGuy opened this issue · 5 comments

Hi,

I built using:
make ARCH=arm64 tinker2_defconfig
make ARCH=arm64 rk3399-tinker_board_2.img -j8

and I got these errors:

make[4]: *** [scripts/Makefile.build:484: drivers/net/wireless/rockchip_wlan] Error 2
make[3]: *** [scripts/Makefile.build:484: drivers/net/wireless] Error 2
make[2]: *** [scripts/Makefile.build:484: drivers/net] Error 2
make[1]: *** [Makefile:1036: drivers] Error 2
make: *** [arch/arm64/Makefile:169: kernel.img] Error 2
make: *** Deleting file 'kernel.img'

Do they need patches?

Hi @SereneGuy

I'm facing the same problem. Did you find any solution?

Thanks

Hi @amiotk

I just got this response below from them, but I haven't tried it yet.

the kernel file has to be in the same directory with prebuilts. if your files are located in different directories then you may have problems because of the wrong gcc.

/TinkerBoard2$ ls
kernel prebuilts rkbin u-boot

those four are in the same directory

Update: I tried it, still doesn't work.

Thanks for the response. With these instructions I have been able to build the kernel by using the GCC from prebuild folder copied from Tinker Board 2 android build system:

sudo apt remove gcc-aarch64-linux-gnu
export PATH=$PATH:~/repos/tb2_linux/prebuilts/gcc/linux-x86/aarch64/gcc-linaro-6.3.1-2017.05-x86_64_aarch64-linux-gnu/bin
make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- clean tinker2_defconfig
make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- rk3399-tinker_board_2.img

Thanks @amiotk

I build it natively in the TinkerBoard2S. It seems that I need to cross compile it as you successfully did so.
I noticed that the cross compiler gcc version you used is the same as the one for u-boot.

Thanks a lot @amiotk
I successfully compiled it in Ubuntu. The only difference was that I didn't remove gcc-aarch64-linux-gnu.

Prior to this I tried to build it natively in the TinkerBoard 2S, thinking that it's built that way in the previous generation.