From b09654e62d01425ca97281fdfde02754d351de81 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sun, 12 Feb 2006 22:35:14 +0000 Subject: Fix building on 2.4 kernels #122565 by André Terpstra. (Portage version: 2.1_pre4-r1) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../svgalib/files/svgalib-1.9.24-linux2.6.patch | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) (limited to 'media-libs/svgalib/files') diff --git a/media-libs/svgalib/files/svgalib-1.9.24-linux2.6.patch b/media-libs/svgalib/files/svgalib-1.9.24-linux2.6.patch index a7e18d82580d..6e07283ab646 100644 --- a/media-libs/svgalib/files/svgalib-1.9.24-linux2.6.patch +++ b/media-libs/svgalib/files/svgalib-1.9.24-linux2.6.patch @@ -1,6 +1,19 @@ + - get rid of warning when linux/device.h doesnt exist - touch up the Makefile to let the ebuild handle the module details - fix support with io remap stuff in newer kernels + - dont include headers that dont exist in 2.4.x kernels +--- svgalib/kernel/svgalib_helper/Makefile ++++ svgalib/kernel/svgalib_helper/Makefile +@@ -28,7 +28,7 @@ + + endif + +-CLASS_SIMPLE := $(shell grep class_simple_create $(KDIR)/include/linux/device.h) ++CLASS_SIMPLE := $(shell grep class_simple_create $(KDIR)/include/linux/device.h 2>/dev/null) + + ifneq ($(CLASS_SIMPLE),) + CLASS_CFLAGS = -DCLASS_SIMPLE=1 --- svgalib/kernel/svgalib_helper/Makefile.alt +++ svgalib/kernel/svgalib_helper/Makefile.alt @@ -37,7 +37,7 @@ @@ -87,3 +100,24 @@ #if (defined MINOR) # define my_minor(x) MINOR(x) #else +--- svgalib/kernel/svgalib_helper/main.c ++++ svgalib/kernel/svgalib_helper/main.c +@@ -19,13 +19,18 @@ + #include + #include + #include ++#include ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0) + #include ++#endif + #include + #include + + #include + #include ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0) + #include ++#endif + + #define __KERNEL_SYSCALLS__ + #include -- cgit v1.2.3-65-gdbad