Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/sys/sys



On Sat, Nov 15, 2025 at 09:43:59PM +0000, Joseph Koshy wrote:
> I am not sure that the approach of defining 'one feature flag
> per significant API/behavior change' scales well over time.

That was not what was suggested (IIUC).

This change was a bit unusual as it changed semantics of an old define.

Usually new behaviour or API changes come with bigger surrounding changes
and often provide testable preprocessor defines quite naturally (or
probing for existence of new functions in some lib for pkgsrc).

> So just incrementing __NetBSD_Version__ (by small values)
> could suffice perhaps?

This is what we do whenever the kernel *ABI* changes.

The change in question was a pure *API* change in a header rarely used
in userland. So formally it did not quailfy for bumping the ABI version
(encoded as __NetBSD_Version__). But as Jörg pointed out we have abused
it for that several times in the past.

I personally like Robert's suggestion to deal with it local in the
header that changed a lot, but now the bump of __NetBSD_Version__ has
happened and we don't officially support building software with headers
from incomplete updates (i.e.: with older __NetBSD_Version__ in
sys/params.h and newer elf headers.

So in general a solution along Robert's suggestion would have been good,
but the big hammer (__NetBSD_Version__ abused) works too (and now can't
be undone).

Martin


Home | Main Index | Thread Index | Old Index