[PATCH] 2.2.x Detect bad genksyms version

Steve Dodd (dirk@loth.demon.co.uk)
Sun, 3 Jan 1999 23:54:30 +0000


--WIyZ46R2i8wDzkSu
Content-Type: text/plain; charset=us-ascii

Hi everyone,

I just upgraded from 2.0.x and got bitten by forgetting to install the new
modutils (I'd built them, I just forgot to install them :). I noticed when
doing 'make dep' in the kernel tree that genksyms fails but that make doesn't
abort. I looked at the relevant bits of Rules.Make and it didn't seem very
easy to do there, so I patched $(TOPDIR)/Makefile to check before
everything starts.

It might be worth while adding to 2.2.0 just to elimate a few bogus bug
reports :)

The only thing I haven't been able to do is test it when /bin/sh != /bin/bash.

Cheers,
Steve

--WIyZ46R2i8wDzkSu
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="2.2.0-pre4-genksyms.patch"

--- linux-2.2.0-pre4-vanilla/Makefile Sun Jan 3 17:23:00 1999
+++ linux-2.2.0-pre4/Makefile Sun Jan 3 23:50:07 1999
@@ -397,7 +397,7 @@
sums:
find . -type f -print | sort | xargs sum > .SUMS

-dep-files: scripts/mkdep archdep include/linux/version.h
+dep-files: scripts/mkdep archdep include/linux/version.h new-genksyms
scripts/mkdep init/*.c > .depend
scripts/mkdep `find $(FINDHPATH) -follow -name \*.h ! -name modversions.h -print` > .hdepend
# set -e; for i in $(SUBDIRS); do $(MAKE) -C $$i fastdep ;done
@@ -407,7 +407,18 @@
MODVERFILE :=

ifdef CONFIG_MODVERSIONS
+
MODVERFILE := $(TOPDIR)/include/linux/modversions.h
+
+new-genksyms:
+ @$(GENKSYMS) -k $(VERSION).$(PATCHLEVEL).$(SUBLEVEL) </dev/null \
+ 2>/dev/null || ( echo -e "\nYou need a new version of genksyms. \
+ Please read Documentation/Changes.\n"; exit 1 )
+
+else
+
+new-genksyms:
+
endif

depend dep: dep-files $(MODVERFILE)

--WIyZ46R2i8wDzkSu--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/