summaryrefslogtreecommitdiff
path: root/libre/lirc-parabola/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'libre/lirc-parabola/PKGBUILD')
-rw-r--r--libre/lirc-parabola/PKGBUILD65
1 files changed, 23 insertions, 42 deletions
diff --git a/libre/lirc-parabola/PKGBUILD b/libre/lirc-parabola/PKGBUILD
index 68ba148d6..5208acab7 100644
--- a/libre/lirc-parabola/PKGBUILD
+++ b/libre/lirc-parabola/PKGBUILD
@@ -4,25 +4,28 @@
# Contributor: Luke Shumaker <lukeshu@sbcglobal.net>
# Contributor: Márcio Silva <coadde@parabola.nu>
-# Kernel info
-_basekernel=3.16
-_kernelname=
-
-# Source info
_pkgname=lirc-parabola${_kernelname}
-# Only build lirc-utils once; for the stock kernel
-if [[ -n "${_kernelname}" ]]; then
- pkgname=$_pkgname
-else
- pkgbase=$_pkgname
- pkgname=("$_pkgname" lirc-utils-parabola)
-fi
-
+pkgbase=$_pkgname
+pkgname=("$_pkgname" lirc-utils-parabola)
_pkgver=0.9.1a
[[ $_pkgver =~ [a-z]$ ]] && pkgver="${_pkgver:0:-1}.${_pkgver: -1}" || pkgver="$_pkgver"
-
+pkgrel=3.2
+epoch=1
+_basekernel=3.16
+_kernelname=
+_extramodules=extramodules-${_basekernel}${_kernelname}
+arch=('i686' 'x86_64' 'mips64el')
url="http://www.lirc.org/"
license=('GPL')
+# NOTICE: Don't forget to bump version in depends in package_lirc()!
+makedepends=('help2man' 'alsa-lib' 'libx11' 'libftdi-compat' 'libirman' 'python2')
+
+# Generic (you shouldn't have to modify any of these variables)
+_toohigh=$(IFS=. read a b <<<$_basekernel; echo $a.$((b+1)))
+makedepends+=("linux-libre${_kernelname}>=${_basekernel}" "linux-libre${_kernelname}<${_toohigh}"
+ "linux-libre${_kernelname}-headers>=${_basekernel}" "linux-libre${_kernelname}-headers<${_toohigh}")
+
+options=('!makeflags' '!strip')
source=("http://prdownloads.sourceforge.net/lirc/lirc-${_pkgver}.tar.bz2"
"wpc8769l-build-fix.patch"
lirc-0.9.1a-fix-segfaults.patch
@@ -36,19 +39,6 @@ md5sums=('1f1fac162ed309dd50f307e96a292957'
'32df3b9bc859565d6acf5f0e5b747083'
'febf25c154a7d36f01159e84f26c2d9a')
-# Package info
-pkgrel=3.2
-epoch=1
-arch=('i686' 'x86_64' 'mips64el')
-options=('!makeflags' '!strip')
-makedepends=('help2man' 'alsa-lib' 'libx11' 'libftdi-compat' 'libirman' 'python2')
-
-# Generic (you shouldn't have to modify any of these variables)
-_toohigh=$(IFS=. read a b <<<$_basekernel; echo $a.$((b+1)))
-_extramodules=extramodules-${_basekernel}${_kernelname}
-makedepends+=("linux-libre${_kernelname}>=${_basekernel}" "linux-libre${_kernelname}<${_toohigh}"
- "linux-libre${_kernelname}-headers>=${_basekernel}" "linux-libre${_kernelname}-headers<${_toohigh}")
-
prepare() {
cd "${srcdir}/lirc-${_pkgver}"
@@ -83,32 +73,24 @@ build() {
make
}
-_package_lirc() {
+_package_lirc-parabola() {
pkgdesc="Linux Infrared Remote Control kernel modules (built for the linux-libre${_kernelname} kernel package)"
depends=('lirc-utils' "linux-libre${_kernelname}>=${_basekernel}" "linux-libre${_kernelname}<${_toohigh}")
replaces=('lirc+pctv')
- [[ -z "$_kernelname" ]] || provides=("lirc-parabola=${pkgver}")
install=kmod.install
-
replaces+=("lirc${_kernelname}" "lirc-libre${_kernelname}")
conflicts+=("lirc${_kernelname}" "lirc-libre${_kernelname}")
provides+=("lirc${_kernelname}=${pkgver}")
cd "${srcdir}/lirc-${_pkgver}/drivers"
- # Set the correct extramodules directory for install
- cp -f "${startdir}/${install}" "${startdir}/${install}.pkg"
- true && install=${install}.pkg
- sed -i "s/_extramodules=.*/_extramodules=${_extramodules}/" "${startdir}/${install}"
-
make DESTDIR="${pkgdir}" moduledir="/usr/lib/modules/${_extramodules}" install
gzip -9 "${pkgdir}/usr/lib/modules/${_extramodules}"/*.ko
+
+ # set the kernel we've built for inside the install script
+ sed -i "s/^_EXTRAMODULES=$/_EXTRAMODULES="${_extramodules}"/" "${startdir}/kmod.install"
}
-if [[ -n "$_kernelname" ]]; then
- eval "package() { _package_lirc; }"
-else
- eval "package_${_pkgname}() { _package_lirc; }"
-fi
+eval "package_${_pkgname}() { _package_lirc-parabola; }"
package_lirc-utils-parabola() {
pkgdesc="Linux Infrared Remote Control utilities"
@@ -116,11 +98,10 @@ package_lirc-utils-parabola() {
optdepends=('python2: pronto2lirc utility')
options=('strip')
backup=('etc/lirc/lirc_options.conf' 'etc/lirc/lircd.conf' 'etc/lirc/lircmd.conf')
-
replaces=('lirc-utils' 'lirc-libre-utils')
conflicts=('lirc-utils' 'lirc-libre-utils')
provides=("lirc-utils=$pkgver")
- install=kmod.install
+ install=lirc-utils.install
cd "${srcdir}/lirc-${_pkgver}"