Package: tp-smapi-source
Version: 0.37-2
Severity: wishlist
Tags: patch
Hi,
tp-smapi-source wouldn't build for me for 2.6.27 kernels:
/usr/bin/make -C /lib/modules/2.6.27-rc5-686/build M=/usr/src/modules/tp-smapi
O=/lib/modules/2.6.27-rc5-686/build modules
make[3]: entrant dans le répertoire « /usr/src/linux-headers-2.6.27-rc5-686 »
CC [M] /usr/src/modules/tp-smapi/thinkpad_ec.o
/usr/src/modules/tp-smapi/thinkpad_ec.c:39:27: error: asm/semaphore.h: Aucun
fichier ou répertoire de ce type
/usr/src/modules/tp-smapi/thinkpad_ec.c:86: warning: type defaults to ‘int’ in
declaration of ‘DECLARE_MUTEX’
/usr/src/modules/tp-smapi/thinkpad_ec.c:86: warning: parameter names (without
types) in function declaration
using linux/semaphore.h instead of asm/semaphore.h seems ok with at
least 2.6.26 and 2.6.27 kernels, please find debdiff of addition of a
dpatch attached.
Cheers,
-- System Information:
Debian Release: lenny/sid
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.6.27-rc5-686 (SMP w/2 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages tp-smapi-source depends on:
ii debhelper 7.0.17 helper programs for debian/rules
ii module-assistant 0.10.11.0 tool to make module package creati
tp-smapi-source recommends no packages.
Versions of packages tp-smapi-source suggests:
ii sysfsutils 2.1.0-4 sysfs query tool and boot-time set
-- no debconf information
--
Loïc Minier
diff -u tp-smapi-0.37/debian/changelog tp-smapi-0.37/debian/changelog
--- tp-smapi-0.37/debian/changelog
+++ tp-smapi-0.37/debian/changelog
@@ -1,3 +1,11 @@
+tp-smapi (0.37-2dooz1) unstable; urgency=low
+
+ * Non-maintainer upload.
+ * New dpatch, 10_semaphore-linux-include, fixes semaphore.h include with
+ newer kernels by using linux/ instead of asm/.
+
+ -- Loic Minier <[EMAIL PROTECTED]> Sat, 06 Sep 2008 01:01:29 +0200
+
tp-smapi (0.37-2) unstable; urgency=low
* Update 99_Makefile-for-Debian.dpatch to not set CFLAGS (Closes: #476360)
diff -u tp-smapi-0.37/debian/patches/00list tp-smapi-0.37/debian/patches/00list
--- tp-smapi-0.37/debian/patches/00list
+++ tp-smapi-0.37/debian/patches/00list
@@ -1,2 +1,3 @@
01_include-thinkpad_ec.h-directly.dpatch
+10_semaphore-linux-include.dpatch
99_Makefile-for-Debian.dpatch
only in patch2:
unchanged:
--- tp-smapi-0.37.orig/debian/patches/10_semaphore-linux-include.dpatch
+++ tp-smapi-0.37/debian/patches/10_semaphore-linux-include.dpatch
@@ -0,0 +1,19 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 10_semaphore-linux-include.dpatch by Loic Minier <[EMAIL PROTECTED]>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix semaphore.h include with newer kernels
+
[EMAIL PROTECTED]@
+diff -urNad tp-smapi-0.37~/thinkpad_ec.c tp-smapi-0.37/thinkpad_ec.c
+--- tp-smapi-0.37~/thinkpad_ec.c 2008-09-06 01:00:46.000000000 +0200
++++ tp-smapi-0.37/thinkpad_ec.c 2008-09-06 01:00:55.000000000 +0200
+@@ -36,7 +36,7 @@
+ #include <linux/delay.h>
+ #include "thinkpad_ec.h"
+ #include <linux/jiffies.h>
+-#include <asm/semaphore.h>
++#include <linux/semaphore.h>
+ #include <asm/io.h>
+
+ #define TP_VERSION "0.37"