Subject: Re: skill package changes for NetBSD >= 1.5
To: None <hubert.feyrer@informatik.fh-regensburg.de>
From: Simon Burge <simonb@netbsd.org>
List: tech-pkg
Date: 06/23/2000 12:47:19
Hubert Feyrer wrote:

> On Fri, 23 Jun 2000, Simon Burge wrote:
> > Techincally this change will also work on NetBSD >1.4Z.  A
> > different way of checking would be to check if "KVM_NO_FILES" is
> > in /usr/include/kvm.h.  Would this be better?  Something like:
> > 
> > 	KPROC2!=	grep -c KVM_NO_FILES /usr/include/kvm.h || true
> > 
> > 	.if ${KPROC2} > 0
> > 	MAKE_ENV+=	COPTS=-DKPROC2
> > 	.else
> > 	BINMODE=	02555
> > 	MAKE_ENV+=	BINGRP=kmem COPTS=-DUVM
> > 	.endif
> 
> Looks ok to me, but please add this also:
> MAKEFLAGS+=	KPROC2=${KPROC2}
> so that sub-makes don't have to re-run the (expensive) "!=".
> 
> If you want to get a OS release instead (whatever you prefer, that's
> really up to you from my POV), you can use the $OS_VERSION variable (which
> is set to output of 'uname -r' in bsd.prefs.mk, i.e. you need to .include
> "../../mk/bsd.prefs.mk").

The problem wasn't getting $OS_VERSION, but how to say

	if ${OS_VERSION} >= 1.5

or even

	if ${OS_VERSION} >= 1.4Z

in make language...