[Bug 285060] Adding osversion to kmod ports is a problem

From: <bugzilla-noreply_at_freebsd.org>
Date: Thu, 27 Feb 2025 20:43:32 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=285060

--- Comment #1 from Steve Kargl <kargl@FreeBSD.org> ---
Ugh, this is really messy.  From the mailing list trail,

On Thu, Feb 27, 2025 at 09:27:56PM +0900, Tomoaki AOKI wrote:
>
> Just a prediction, but possibly build cluster for main (15-Current) are
> running on 1500033, while your build environment is running on 1500031.
>

That is exactly the problem.  Someone tracking freebsd-current
may have slightly different kernel running than the one used
to build INDEX-15.  In my case, I have

% sysctl -a | grep osreldate
kern.osreldate: 1500031

and INDEX-15 was built on a system with 1500033.

> IIUC, the purpose of the kmod version string change is to provide
> kmod pkgs for multiple minor releases (i.e., provide kmod pkgs for 14.2
> even until 14.1 is EoL'ed).

IMHO, the solution is clearly wrong.  INDEX-15 is only
valid for short period of time.  Hmmm, it seems that
the Porter's Handbook

https://docs.freebsd.org/en/books/porters-handbook/book/#versions

shows that __FreeBSD_version was changed to 1500030 on 2025-01-02.
Newer numbers are not documented.  My kernel is at 1500031 with
a timestamp of

kern.version: FreeBSD 15.0-CURRENT #0 main-n275407-e736f6df1ec1:\
Wed Feb 12 15:22:12 PST 2025

and INDEX-15 is from a system with 1500033.   'git blame' shows

05dfaadde4ae0 (Jean-Sébastien Pédron 2024-12-22 19:10:23 +0100  76)\
#define __FreeBSD_version 1500033

So, the timestamps don't make sense.

Looking at the lists of version numbers in the Handbook and
the large comment in sys/sys/params.h, it's clear that the
last 3 digits should be trimmed.   1401 is a 14.1 system,
1402 is a 14.2 system, 1500 is freebsd-current, etc.

-- 
You are receiving this mail because:
You are the assignee for the bug.