树莓派系统apt install的应用是哪里来的

树莓派官方为树莓派4b提供的系统基于debian,安装好系统后,可以用apt install命令来安装应用。

这些应用是树莓派官方提供的?还是debian官方提供的?
如果是debian提供,那么是不是arm架构的硬件,都能安装这些应用?

Raspberry Pi OS 的软件源分为两部分,一部分是 Raspbian(针对 Raspberry Pi 硬件重建 Debian 软件包),另一部分是 Raspberrypi(Raspberry Pi 基金会专为 Raspberry Pi 编写的软件)。

专门为RaspberryPI编写的软件能够理解。

针对RaspberryPI硬件重建的Debian软件包,这个数量好像很大,我用树莓派,好像没觉得有缺少什么软件。所以,这个工作量应该比较大,时间也比较长?其它类似的硬件产品,缺少的应该也是类似的应用软件数量?

所谓的硬件主要指的不就是ARM平台?

其它的硬件也就差不多是些驱动吧。

如果只是驱动的话,那应该简单很多。

我看orange pi 5官方有提供debian镜像,那么这个orange pi 5运行debian后,apt install安装的应用软件,和树莓派基本没区别?我的意思是,orange pi是否需要重建debian包。

一般而言,试图在新硬件平台运行 Linux 时采取的做法是启动某种衍生分发,以便不用一切都重新开始,例如:

对于 Debian,创建新 Port 的文档在

https://wiki.debian.org/PortsDocs/New

这是为 Debian 增加一个正式移植所需的步骤,如果目标不是进入 Debian,则无需执行所有步骤。

From Debian -- Ports

Linux 内核现已移植到庞大数量的架构中,这个列表还在不断增长。我们紧随其后,将 Debian 发行版移植到了这些架构上。一般来说,开始过程比较困难(要让 libc 和动态链接器正常工作),然后是比较常规的,可能会有点冗长的工作,尝试在新架构下重新编译所有的软件包。

因此,重建软件包只有在 Debian 不支持你的架构时才需要进行(否则,这项工作已经在 Debian 中完成)。

Raspbian 开始的主要原因是, Debian 的 armhf 架构至少需要支持 Thumb-2 和 VFPv3-D16 浮点的 ARMv7 CPU,而在此项工作开始时 Raspberry Pi 的硬件不在此范围内,因此移植是必须的。对于较新的 Raspberry Pi 硬件,这不再是一个问题;原则上,你可以在其上直接运行 Debian

另参见 Frequently Asked Questions (FAQs) and errata (raspi.debian.net) 的第6:

Are the images 32 or 64 bits?

The architecture chosen for each of the builds is the best suited for its hardware. This is one of the main differences with Raspberry Pi OS: They redefined some technical bits for the 32-bit armhf architecture, allowing it to run on their least powerful systems (families 0 and 1), where we must run with the much slower (and also, 32-bit) armel architecture (with emulated floating point). And they ship 32 bit for the higher-end machines (3, 4) for greater consistency. Thus,

Family Debian Raspberry Pi OS
0 / 1 armel, 32 bit armhf, 32 bit
2 armhf, 32 bit armhf, 32 bit
3 arm64, 64 bit armhf, 32 bit
4 arm64, 64 bit armhf, 32 bit

实际上, Raspberry Pi OS 具有实验性的64位支持,其做法是从 Debian 直接获取用户空间程序,因为在这种情况下,没有必要重建 Debian 软件包(因为 Debian 已经支持 arm64 架构)。

大概明白了,多谢 :+1: