POCKET BEAGLE - HOWTO CONFIGURE & COMPILE KERNEL?

Hello all! I’ve got a Pocket Beagle running “Linux beagle bone 4.9.83-ti-r104 #1 SMP PREEMP”, I would like to change the kernel configuration to include support for the Realtek RTL8821AE WiFi driver. I see the option to load the driver in the Network Device Support section of the kernel config menu, but I am not able to compile the kernel using the normal Debian steps. I have installed “linux-headers-4.9.83.ti-r104” in “/usr/src”, and am able to get the config menu by running “make menuconfig” from in that directory. However, when I try to compile the kernel with “make all”, I get the following error:

debian@beaglebone:/usr/src/linux-headers-4.9.83-ti-r104$ sudo make all
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
make[1]: *** No rule to make target ‘arch/arm/tools/gen-mach-types’, needed by ‘include/generated/mach-types.h’. Stop.
arch/arm/Makefile:320: recipe for target ‘archprepare’ failed
make: *** [archprepare] Error 2
debian@beaglebone:/usr/src/linux-headers-4.9.83-ti-r104$ sudo make menuconfig
scripts/kconfig/mconf Kconfig

*** End of the configuration.
*** Execute ‘make’ to start the build or try ‘make help’.

I am not able to get “make clean” to work, so I suspect I’m not doing it right. This is what I see:

make clean
[sudo] password for debian:
scripts/Makefile.clean:14: drivers/gpu/drm/nouveau/Makefile: No such file or directory
make[4]: *** No rule to make target ‘drivers/gpu/drm/nouveau/Makefile’. Stop.
scripts/Makefile.clean:88: recipe for target ‘drivers/gpu/drm/nouveau’ failed
make[3]: *** [drivers/gpu/drm/nouveau] Error 2
scripts/Makefile.clean:88: recipe for target ‘drivers/gpu/drm’ failed
make[2]: *** [drivers/gpu/drm] Error 2
scripts/Makefile.clean:88: recipe for target ‘drivers/gpu’ failed
make[1]: *** [drivers/gpu] Error 2
Makefile:1294: recipe for target ‘_clean_drivers’ failed
make: *** [_clean_drivers] Error 2

Is there a tutorial somewhere on how to compile the kernel from the headers after changing the kernel configuration? Does anyone have any thoughts?

Thanks,

Joe

Ah those are the "headers" not the drivers..

Grab yakbuild:

https://github.com/RobertCNelson/yakbuild

Follow the readme.md and use the "recipe.sh.v4.9.x.sample" example..

Regards,