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/PKGBUILD77
1 files changed, 32 insertions, 45 deletions
diff --git a/libre/lirc-parabola/PKGBUILD b/libre/lirc-parabola/PKGBUILD
index 6892f9a8a..d5f36b531 100644
--- a/libre/lirc-parabola/PKGBUILD
+++ b/libre/lirc-parabola/PKGBUILD
@@ -4,25 +4,30 @@
# 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
+_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 +41,6 @@ md5sums=('1f1fac162ed309dd50f307e96a292957'
'32df3b9bc859565d6acf5f0e5b747083'
'febf25c154a7d36f01159e84f26c2d9a')
-# Package info
-pkgrel=3.${_basekernel/./}
-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 +75,26 @@ build() {
make
}
-_package_lirc() {
+_package_lirc-parabola() {
pkgdesc="Linux Infrared Remote Control kernel modules (built for the linux-libre${_kernelname} kernel package)"
- depends=('lirc-libre-utils' "linux-libre${_kernelname}>=${_basekernel}" "linux-libre${_kernelname}<${_toohigh}")
+ 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}" "lirc-libre${_kernelname}=${pkgver}")
+ replaces+=("lirc${_kernelname}" "lirc-libre${_kernelname}")
+ conflicts+=("lirc${_kernelname}" "lirc-libre${_kernelname}")
+ provides+=("lirc${_kernelname}=${pkgver}")
cd "${srcdir}/lirc-${_pkgver}/drivers"
+ make DESTDIR="${pkgdir}" moduledir="/usr/lib/modules/${_extramodules}" install
+ gzip -9 "${pkgdir}/usr/lib/modules/${_extramodules}"/*.ko
+
# Set the correct extramodules directory for install
cp -f "${startdir}/${install}" "${startdir}/${install}.pkg"
true && install=${install}.pkg
- sed -r "s/(_extramodules=).*/\1${_extramodules}/" -i "${startdir}/${install}"
-
- make DESTDIR="${pkgdir}" moduledir="/usr/lib/modules/${_extramodules}" install
- gzip -9 "${pkgdir}/usr/lib/modules/${_extramodules}"/*.ko
+ sed -i "s/^_EXTRAMODULES=$/_EXTRAMODULES="${_extramodules}"/" "${startdir}/${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 +102,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-utils-libre')
- conflicts=('lirc-utils' 'lirc-utils-libre')
- provides=( "lirc-utils=$pkgver" "lirc-utils-libre=$pkgver")
- install=kmod.install
+ replaces=('lirc-utils' 'lirc-libre-utils')
+ conflicts=('lirc-utils' 'lirc-libre-utils')
+ provides=("lirc-utils=$pkgver")
+ install=lirc-utils.install
cd "${srcdir}/lirc-${_pkgver}"
@@ -138,3 +123,5 @@ package_lirc-utils-parabola() {
# remove built modules
rm -r "${pkgdir}/usr/lib/modules"
}
+
+# vim: ts=2 sw=2 et: