From owner-freebsd-current Mon May 4 11:32:10 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA25938 for freebsd-current-outgoing; Mon, 4 May 1998 11:32:10 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from ns1.yes.no (ns1.yes.no [195.119.24.10]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA25826 for ; Mon, 4 May 1998 11:32:04 -0700 (PDT) (envelope-from eivind@bitbox.follo.net) Received: from bitbox.follo.net (bitbox.follo.net [194.198.43.36]) by ns1.yes.no (8.8.7/8.8.7) with ESMTP id SAA23999 for ; Mon, 4 May 1998 18:32:01 GMT Received: (from eivind@localhost) by bitbox.follo.net (8.8.8/8.8.6) id UAA06866; Mon, 4 May 1998 20:31:56 +0200 (MET DST) Message-ID: <19980504203155.41473@follo.net> Date: Mon, 4 May 1998 20:31:55 +0200 From: Eivind Eklund To: current@FreeBSD.ORG Subject: Proposal: Kernel API version -> param.h Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.89.1i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG We have a severe version headache for anybody maintaining drivers outside the FreeBSD tree proper - there is no way for them to get the version of the kernel tree they are compiling. At present, this lead to a lot of driver authors testing __FreeBSD__ to find out what to compile - which mean that the 3.0 kernel can't compile correctly on a 2.2 system, and vice versa. I propose moving the API version from newvers.sh to param.h, a la the following patch (which also fix a missing dependency for vers.c). Comments, please! Eivind. Index: conf/newvers.sh =================================================================== RCS file: /home/ncvs/src/sys/conf/newvers.sh,v retrieving revision 1.34 diff -u -r1.34 newvers.sh --- newvers.sh 1997/09/24 04:36:19 1.34 +++ newvers.sh 1998/05/04 18:12:01 @@ -44,7 +44,8 @@ fi VERSION="${TYPE} ${RELEASE}" -RELDATE="300001" +RELDATE=$(awk '/__FreeBSD_version.*propagated to newvers/ {print $3}' \ + $(dirname $0)/../sys/param.h) b=share/examples/etc/bsd-style-copyright year=`date '+%Y'` Index: i386/conf/Makefile.i386 =================================================================== RCS file: /home/ncvs/src/sys/i386/conf/Makefile.i386,v retrieving revision 1.110 diff -u -r1.110 Makefile.i386 --- Makefile.i386 1998/04/29 18:21:28 1.110 +++ Makefile.i386 1998/05/04 18:23:52 @@ -226,7 +226,7 @@ param.o: param.c Makefile ${CC} -c ${CFLAGS} ${PARAM} param.c -vers.o: ${SYSTEM_DEP} ${SYSTEM_SWAP_DEP} +vers.o: $S/sys/param.h ${SYSTEM_DEP} ${SYSTEM_SWAP_DEP} sh $S/conf/newvers.sh ${KERN_IDENT} ${IDENT} ${CC} ${CFLAGS} -c vers.c Index: sys/param.h =================================================================== RCS file: /home/ncvs/src/sys/sys/param.h,v retrieving revision 1.28 diff -u -r1.28 param.h --- param.h 1998/03/28 10:33:22 1.28 +++ param.h 1998/05/04 18:11:26 @@ -45,6 +45,8 @@ #define BSD 199506 /* System version (year & month). */ #define BSD4_3 1 #define BSD4_4 1 +#undef __FreeBSD_version +#define __FreeBSD_version 300001 /* Master version, propagated to newvers */ #ifndef NULL #define NULL 0 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message