linux-kernel - Linux 内核版本号中的 + 意味着什么?

标签 linux-kernel

我的 NAS 上的 Linux 内核将自身报告为版本 4.19.165+

/boot/bzImage: Linux kernel x86 boot executable bzImage, version 4.19.165+ (root@developer) #56 SMP Fri Apr 2 17:16:25 CST 2021, RO-rootFS, swap_dev 0x28, Normal VGA

Linux内核版本号中的+是什么意思?

最佳答案

这个在构建时负责生成本地版本字符串的shell脚本中有描述,即scripts/setlocalversion :

# scm version string if not at a tagged commit
if test "$CONFIG_LOCALVERSION_AUTO" = "y"; then
    # full scm version string
    res="$res$(scm_version)"
else
    # append a plus sign if the repository is not in a clean
    # annotated or signed tagged state (as git describe only
    # looks at signed or annotated tags - git tag -a/-s) and
    # LOCALVERSION= is not specified
    if test "${LOCALVERSION+set}" != "set"; then
        scm=$(scm_version --short)
        res="$res${scm:++}"
    fi
fi

因此,这很可能意味着在构建 Git 存储库时,脚本将其视为“脏”,即:未在签名或带注释的标签上 checkout (请参阅 git-tag documentation 了解其含义) .

关于linux-kernel - Linux 内核版本号中的 + 意味着什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/68514583/

相关文章:

linux - 中断发生时,或者进程调度时,是否需要保存标志寄存器?

c - 如何在不导致 Linux 内核崩溃的情况下访问 mmaped/dev/mem?

linux - 在 Linux 中立即检测新进程的创建

linux - Linux 中内核定时器实现示例(内核 2.6.32)

c - wait_event_timeout 的解释

linux - 可以在 USB 中的同一个 URB 中发送和接收数据吗? Linux操作系统

c - 为什么有些函数不涉及内核?

c++ - 为什么 copy_to_user 会花费数百毫秒?

c - local_fiq_enable() 的功能

c - 初始化元素不是常量 - 如何解决错误?