软件源码
在树莓派,我们致力于尽可能开源代码,以便您轻松使用并根据自身需求进行适配。树莓派专门为我们的产品开发和支持软件,并将精力集中在提供最佳用户体验的软件上。例如,优化多媒体加速的驱动程序,包括3D加速、HEVC解码、摄像头成像管道、AI加速、双HDMI及 音频功能。
在树莓派操作系统中查找软件源
当您寻找随树莓派操作系统分发的软件时,通常存在上游软件源,我们通过打补丁创建下游软件包(标记为+rpt
)。要查看这些软件包的源代码,通常通过apt获取更为便捷。为此,您需要先编辑apt源列表以包含源代码包。需编辑以下文件,将每行deb-src
开头的#
移除:
/etc/apt/sources.list
/etc/apt/sources.list.d/raspi.list
随后必须更新软件包列表:
sudo apt update
现在可获取软件包源,例如:
apt source labwc
随后需安装辅助软件包:
sudo apt install devscripts
最后,您可以使用标准的Debian构建流程来构建该软件包。
sudo apt build-dep labwc
cd labwc-0.8.4
debuild -uc -us
我们的 GitHub 组织
您还可以在 GitHub 仓库中以更标准的形式找到我们的软件。我们使用三个 GitHub 组织来存储源代码:
分类源代码列表
以下是精选的热门仓库列表:
核心源代码
https://github.com/raspberrypi/linux
该仓库包含支持所有树莓派版本(从Pi 1到Pi 5)的下行Linux内核源代码。
https://github.com/raspberrypi/firmware
此仓库包含闭源固件,但以下两个链接仍具参考价值:
https://github.com/raspberrypi/rpi-eeprom
适用于树莓派4和树莓派5引导加载程序EEPROM的安装脚本及二进制文件,包含版本发布和版本说明。
库与应用程序
https://github.com/raspberrypi/utils
包含实用工具集合,如 pinctrl、piolib 和 raspinfo,以及 gpiolib——一种支持树莓派直接访问 GPIO 引脚的方法。
https://github.com/raspberrypi/libcamera
用于控制树莓派 ISP 和摄像头的 libcamera 库实现。
https://github.com/raspberrypi/rpicam-apps
基于libcamera的C++库及应用套件,用于树莓派摄像头的图像/视频处理与编码。
https://github.com/raspberrypi/picamera2
用于操作和控制树莓派摄像头的Python库。
https://github.com/raspberrypi/drmu
用于直接控制和访问 多媒体接口的库。
桌面环境
https://github.com/raspberrypi-ui/wf-panel-pi
在基于Wayland的桌面环境运行时,显示于屏幕顶部的任务栏。
https://github.com/raspberrypi-ui/lxpanel-pi
运行传统X窗口系统桌面时显示在屏幕顶部的任务栏。
https://github.com/raspberrypi-ui/pplug-batt
https://github.com/raspberrypi-ui/pplug-bluetooth
https://github.com/raspberrypi-ui/pplug-clock
https://github.com/raspberrypi-ui/pplug-cpu
https://github.com/raspberrypi-ui/pplug-cputemp
https://github.com/raspberrypi-ui/pplug-ejecter
https://github.com/raspberrypi-ui/pplug-gpu
https://github.com/raspberrypi-ui/pplug-menu
https://github.com/raspberrypi-ui/pplug-netman
https://github.com/raspberrypi-ui/pplug-power
https://github.com/raspberrypi-ui/pplug-updater
https://github.com/raspberrypi-ui/pplug-volumepulse
任务栏上显示的插件。
https://github.com/raspberrypi-ui/pcmanfm
https://github.com/raspberrypi-ui/libfm
桌面使用的文件管理器,同时显示桌面背景。
https://github.com/raspberrypi-ui/appset
外观设置面板。
https://github.com/raspberrypi-ui/rc_gui
树莓派配置设置面板。
https://github.com/raspberrypi-ui/rasputin
鼠标和键盘设置面板。
https://github.com/raspberrypi-ui/raindrop
屏幕配置设置面板。
https://github.com/raspberrypi-ui/rpinters
打印机设置面板。