记录一下树莓派打内核补丁cjktty的天坑

本文详细指导如何为RaspberryPi选择合适的Linux内核版本(如2709),下载补丁,设置菜单配置,以及编译和安装过程中涉及的驱动和字体选项。作者分享了在树莓派Zero2上编译的挑战和过程。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

首先cjktty的下载地址在此,大家根据自己的linux内核去选择:
https://github.com/zhmars/cjktty-patches
下载好了补丁文件之后 需要下载完整的linux内核,是的完整的
https://github.com/raspberrypi/linux
光这两步 我就搞了好久才明白,linux纯小白 没办法呀
然后就是打补丁了,注意必须在linux内核源码的目录下打:
patch -Np1 -i < xxx.patch
然后就是设置menuconfig

为啥选2709,因为我是zero2w,且用32位系统, 跟3一样 官方有说明
https://www.raspberrypi.com/documentation/computers/linux_kernel.html
For Raspberry Pi 1, Zero and Zero W, and Raspberry Pi Compute Module 1 default (32-bit only) build configuration

cd linux
KERNEL=kernel
make bcmrpi_defconfig
For Raspberry Pi 2, 3, 3+ and Zero 2 W, and Raspberry Pi Compute Modules 3 and 3+ default 32-bit build configuration

cd linux
KERNEL=kernel7
make bcm2709_defconfig
For Raspberry Pi 4 and 400, and Raspberry Pi Compute Module 4 default 32-bit build configuration

cd linux
KERNEL=kernel7l
make bcm2711_defconfig
For Raspberry Pi 3, 3+, 4, 400 and Zero 2 W, and Raspberry Pi Compute Modules 3, 3+ and 4 default 64-bit build configuration

cd linux

KERNEL=kernel7
make bcm2709_defconfig
make menuconfig
以下模块编链到内核:

Device drivers —>
Graphics support —>
Framebuffer device support —>
[]Vesa VGA graphics support
Library routines —>
[
]Select compiled-in fonts
[]Vga 8x16 font #非必需
-
- console 16x16 CJK font (cover BMP)

并不理解,为啥塞个字体文件,需要费这么大劲儿,选中那两个cjk字体,保存配置文件到默认位置

然后就作死编译把
sudo make -j2

由于是直接在树莓派zero2上编译的,速度慢到没朋友,而且也并不知道最后能不能用。。。
经过几个世界和八百个能在网上一搜就解决的坑:

sudo make modules_install -j2
sudo make install -j2

反正是没有报错 编译完了咋用呢 我再研究研究

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值