Date: Mon, 4 May 1998 20:31:55 +0200 From: Eivind Eklund <eivind@yes.no> To: current@FreeBSD.ORG Subject: Proposal: Kernel API version -> param.h Message-ID: <19980504203155.41473@follo.net>
next in thread | raw e-mail | index | archive | help
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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19980504203155.41473>
