Subject: Re: Checking for NetBSD version
To: Greywolf <greywolf@starwolf.com>
From: Frederick Bruckman <fredb@immanent.net>
List: current-users
Date: 11/17/2003 13:18:37
On Mon, 17 Nov 2003, Greywolf wrote:

> Thus spake Alan Barrett ("AB> ") sometime Today...
>
> AB> On Mon, 17 Nov 2003, martti.kuparinen@piuha.net wrote:
> AB> > What is "the correct way" of checking NetBSD version (1.x vs -current) in
> AB> > source code (with preprocessor)? In other words, how should I rewrite
> AB> > the "if 1" line in the following code fragment?
> AB>
> AB> #include <sys/param.h>
> AB> #if defined(__NetBSD_Version__) && (__NetBSD_Version__ < 106110000)
> AB> 	/* NetBSD < 1.6K does not have separate read/write statistics. */
> AB>
>
> Just a thought:  Should sys/param.h have a __NetBSD_Date__ setting, or
> would this just be too much of a dependency nightmare...?  Since we don't
> always bump the __NetBSD_Version__ for stuff which is visible, the
> __NetBSD_Date__ setting might prove more reliable...

Uh... how would that work? Autobump every day?

Frederick