summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO9
-rw-r--r--PKGBUILD16
-rw-r--r--dkms.conf9
-rw-r--r--tp_smapi-dkms.install18
4 files changed, 18 insertions, 34 deletions
diff --git a/.SRCINFO b/.SRCINFO
index cc3410c3181..dadbae90eae 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,22 +1,21 @@
# Generated by mksrcinfo v8
-# Fri May 6 18:47:46 UTC 2016
+# Fri Sep 29 15:01:57 UTC 2017
pkgbase = tp_smapi-dkms
pkgdesc = DKMS controlled modules for ThinkPad's SMAPI functionality
pkgver = 0.42
- pkgrel = 1
+ pkgrel = 2
url = http://www.thinkwiki.org/wiki/Tp_smapi
- install = tp_smapi-dkms.install
arch = any
license = GPL
depends = dkms
- provides = tp_smapi=0
+ provides = tp_smapi=0.42
conflicts = tp_smapi
options = !strip
source = https://github.com/evgeni/tp_smapi/releases/download/tp-smapi%2F0.42/tp_smapi-0.42.tgz
source = dkms.conf
source = kbase.patch
sha256sums = 7b8d9f488c3859805f1f292bf4d518cc5b32ebb69b0ebe96367d0852dd792d27
- sha256sums = e2d3db8b9bd5c53cba1d702e36814ec56ef52dd37dfe8a03f58deb83c11c8bed
+ sha256sums = ad75d30622f7d40ad00daa784776bb595c2ac4736fa58f492d7f0d6948e0a832
sha256sums = 4bcce516a9f3c486a934cfe6e3d3c92443833f4094ec008ce25264d1a5b66097
pkgname = tp_smapi-dkms
diff --git a/PKGBUILD b/PKGBUILD
index 819bfcf5a78..e4580e30a59 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,19 +1,19 @@
pkgname=tp_smapi-dkms
pkgver=0.42
-pkgrel=1
+pkgrel=2
pkgdesc="DKMS controlled modules for ThinkPad's SMAPI functionality"
arch=(any)
url="http://www.thinkwiki.org/wiki/Tp_smapi"
license=('GPL')
depends=('dkms')
conflicts=('tp_smapi')
-provides=("tp_smapi=${pkgver%.*}")
+provides=("tp_smapi=${pkgver}")
options=(!strip)
-install='tp_smapi-dkms.install'
source=("https://github.com/evgeni/tp_smapi/releases/download/tp-smapi%2F${pkgver}/tp_smapi-${pkgver}.tgz" 'dkms.conf' 'kbase.patch')
sha256sums=('7b8d9f488c3859805f1f292bf4d518cc5b32ebb69b0ebe96367d0852dd792d27'
- 'e2d3db8b9bd5c53cba1d702e36814ec56ef52dd37dfe8a03f58deb83c11c8bed'
+ 'ad75d30622f7d40ad00daa784776bb595c2ac4736fa58f492d7f0d6948e0a832'
'4bcce516a9f3c486a934cfe6e3d3c92443833f4094ec008ce25264d1a5b66097')
+
prepare() {
cd tp_smapi-${pkgver}
# patch Makefile for recent kernel module directory change
@@ -22,10 +22,14 @@ prepare() {
sed -ri 's/^(PACKAGE_VERSION=).*/\1'${pkgver}'/g' "${srcdir}"/dkms.conf
}
-package()
-{
+package() {
mkdir -p "${pkgdir}"/usr/src/${pkgname}-${pkgver}
cp -a tp_smapi-${pkgver}/{*.{h,c},Makefile} "${pkgdir}"/usr/src/${pkgname}-${pkgver}
cp dkms.conf "${pkgdir}"/usr/src/${pkgname}-${pkgver}
+
+ sed -e "s/@PKGNAME@/${pkgname}/" \
+ -e "s/@PKGVER@/${pkgver}/" \
+ -i "${pkgdir}"/usr/src/${pkgname}-${pkgver}/dkms.conf
+
sed -i 's/KVER/KERNELRELEASE/g' "${pkgdir}"/usr/src/${pkgname}-${pkgver}/Makefile
}
diff --git a/dkms.conf b/dkms.conf
index 771f1aae9ff..ae2ccd4dc57 100644
--- a/dkms.conf
+++ b/dkms.conf
@@ -1,9 +1,8 @@
-PACKAGE_VERSION=0.41
-PACKAGE_NAME="tp_smapi-dkms"
-AUTOINSTALL="yes"
-
+PACKAGE_NAME=@PKGNAME@
+PACKAGE_VERSION=@PKGVER@
MAKE="make KVER=${kernelver} HDAPS=1"
CLEAN="make clean"
+AUTOINSTALL="yes"
BUILT_MODULE_NAME[0]="hdaps"
DEST_MODULE_LOCATION[0]="/updates"
@@ -12,4 +11,4 @@ BUILT_MODULE_NAME[1]="thinkpad_ec"
DEST_MODULE_LOCATION[1]="/extra"
BUILT_MODULE_NAME[2]="tp_smapi"
-DEST_MODULE_LOCATION[2]="/extra"
+DEST_MODULE_LOCATION[2]="/extra" \ No newline at end of file
diff --git a/tp_smapi-dkms.install b/tp_smapi-dkms.install
deleted file mode 100644
index 2b115737c1a..00000000000
--- a/tp_smapi-dkms.install
+++ /dev/null
@@ -1,18 +0,0 @@
-# old version (without -$pkgrel): ${1%%-*}
-# new version (without -$pkgrel): ${2%%-*}
-
-post_install() {
- dkms install tp_smapi-dkms/${1%%-*}
-}
-
-pre_upgrade() {
- pre_remove ${2%%-*}
-}
-
-post_upgrade() {
- post_install ${1%%-*}
-}
-
-pre_remove() {
- dkms remove tp_smapi-dkms/${1%%-*} --all
-}