lkml.org 
[lkml]   [1998]   [Mar]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRe: Linux version code
Date
In message <199803041700.SAA02494@manjak.knm.org.pl> you write:
> Sorry for the silly question, but how can I calculate LINUX_VERSION_CODE ?

Linus, please apply (2.1.x):

diff -u --recursive --new-file linux-2.1.88-raw/Makefile linux-2.1.88/Makefile
--- linux-2.1.88-raw/Makefile Sun Mar 8 13:55:03 1998
+++ linux-2.1.88/Makefile Fri Feb 27 10:56:50 1998
@@ -262,6 +262,7 @@
include/linux/version.h: ./Makefile
@echo \#define UTS_RELEASE \"$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)\" > .ver
@echo \#define LINUX_VERSION_CODE `expr $(VERSION) \\* 65536 + $(PATCHLEVEL) \\* 256 + $(SUBLEVEL)` >> .ver
+ @echo '#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))' >>.ver
@mv -f .ver $@

init/version.o: init/version.c include/linux/compile.h
There is already code like this lying around in a couple of places; if
this patch gets accepted I'll send another to clean them up.

Rusty.
--
.sig lost in the mail.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

\
 
 \ /
  Last update: 2005-03-22 13:41    [W:0.039 / U:2.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site