summaryrefslogtreecommitdiff
path: root/libre/virtualbox-libre-modules
diff options
context:
space:
mode:
Diffstat (limited to 'libre/virtualbox-libre-modules')
-rw-r--r--libre/virtualbox-libre-modules/PKGBUILD33
-rwxr-xr-xlibre/virtualbox-libre-modules/build.sh19
2 files changed, 28 insertions, 24 deletions
diff --git a/libre/virtualbox-libre-modules/PKGBUILD b/libre/virtualbox-libre-modules/PKGBUILD
index 067a95fdd..45bbfb86d 100644
--- a/libre/virtualbox-libre-modules/PKGBUILD
+++ b/libre/virtualbox-libre-modules/PKGBUILD
@@ -1,13 +1,14 @@
# $Id$
# Maintainer: Ionut Biru <ibiru@archlinux.org>
-# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
+# Maintainer: Sébastien Luttringer <seblu@archlinux.org>
# Maintainer (Parabola): Jorge López <jorginho@lavabit.com>
# Maintainer (Parabola): André Silva <emulatorman@lavabit.com>
pkgbase=virtualbox-libre-modules
pkgname=('virtualbox-libre-host-modules' 'virtualbox-libre-guest-modules')
-pkgver=4.2.6
-pkgrel=4
+pkgver=4.2.10
+_extramodules=extramodules-3.8-LIBRE
+pkgrel=3
arch=('i686' 'x86_64')
url='http://virtualbox.org'
license=('GPL')
@@ -18,7 +19,7 @@ makedepends=('linux-libre-headers'
'bc')
build() {
- _kernver=$(expac -Q '%v' linux-libre-headers)-LIBRE
+ _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
# dkms need modification to be run as user
cp -r /var/lib/dkms .
@@ -32,42 +33,38 @@ build() {
}
package_virtualbox-libre-host-modules(){
- _kernver=$(expac -Q '%v' linux-libre-headers)-LIBRE
- _extraver=extramodules-${_kernver%.*}-LIBRE
+ _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
pkgdesc='Host kernel modules for VirtualBox (built for the linux-libre kernel package)'
-# depends=("linux-libre>=${_kernver%.*}" "linux-libre<$(echo "${_kernver%.*}+0.1"|bc)")
- depends=('linux-libre>=3.7' 'linux-libre<3.8')
+ depends=('linux-libre>=3.8' 'linux-libre<3.9')
provides=("virtualbox-host-modules=${pkgver}")
replaces=('virtualbox-host-modules' 'virtualbox-modules' 'virtualbox-libre-modules')
conflicts=('virtualbox-host-modules' 'virtualbox-modules' 'virtualbox-libre-modules')
install=virtualbox-libre-host-modules.install
- install -dm755 "$pkgdir/usr/lib/modules/$_extraver"
+ install -dm755 "$pkgdir/usr/lib/modules/$_extramodules"
cd "dkms/vboxhost/$pkgver/$_kernver/$CARCH/module"
- install -m644 * "$pkgdir/usr/lib/modules/$_extraver"
+ install -m644 * "$pkgdir/usr/lib/modules/$_extramodules"
find "$pkgdir" -name '*.ko' -exec gzip -9 {} +
- sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extraver'/" "$startdir/virtualbox-libre-host-modules.install"
+ sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extramodules'/" "$startdir/virtualbox-libre-host-modules.install"
}
package_virtualbox-libre-guest-modules(){
- _kernver=$(expac -Q '%v' linux-libre-headers)-LIBRE
- _extraver=extramodules-${_kernver%.*}-LIBRE
+ _kernver="$(cat /usr/lib/modules/${_extramodules}/version)"
pkgdesc='Guest kernel modules for VirtualBox (built for the linux-libre kernel package)'
license=('GPL')
-# depends=("linux-libre>=${_kernver%.*}" "linux-libre<$(echo "${_kernver%.*}+0.1"|bc)")
- depends=('linux-libre>=3.7' 'linux-libre<3.8')
+ depends=('linux-libre>=3.8' 'linux-libre<3.9')
provides=("virtualbox-guest-modules=${pkgver}")
replaces=('virtualbox-guest-modules' 'virtualbox-archlinux-modules' 'virtualbox-parabola-modules')
conflicts=('virtualbox-guest-modules' 'virtualbox-archlinux-modules' 'virtualbox-parabola-modules')
install=virtualbox-libre-guest-modules.install
- install -dm755 "$pkgdir/usr/lib/modules/$_extraver"
+ install -dm755 "$pkgdir/usr/lib/modules/$_extramodules"
cd "dkms/vboxguest/$pkgver/$_kernver/$CARCH/module"
- install -m644 * "$pkgdir/usr/lib/modules/$_extraver"
+ install -m644 * "$pkgdir/usr/lib/modules/$_extramodules"
find "$pkgdir" -name '*.ko' -exec gzip -9 {} +
- sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extraver'/" "$startdir/virtualbox-libre-guest-modules.install"
+ sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extramodules'/" "$startdir/virtualbox-libre-guest-modules.install"
}
# vim:set ts=2 sw=2 et:
diff --git a/libre/virtualbox-libre-modules/build.sh b/libre/virtualbox-libre-modules/build.sh
index 6152ec21d..895bea0b1 100755
--- a/libre/virtualbox-libre-modules/build.sh
+++ b/libre/virtualbox-libre-modules/build.sh
@@ -1,18 +1,25 @@
#!/bin/bash
+set -e
+
if (( $# != 1 )); then
echo "usage: $0 extra"
echo " $0 testing"
exit 1
fi
-linux32 makechrootpkg -cuI ../../virtualbox/trunk/virtualbox-libre-host-dkms-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686
-linux32 makechrootpkg -I ../../virtualbox/trunk/virtualbox-libre-guest-dkms-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686
-linux32 makechrootpkg -r /var/lib/archbuild/$1-i686
+here=$PWD
+cd /var/empty
+linux32 makechrootpkg -cu -I "$here"/../../virtualbox/trunk/virtualbox-libre-host-dkms-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686
+linux32 makechrootpkg -I "$here"/../../virtualbox/trunk/virtualbox-libre-guest-dkms-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686
+cd "$here"
+linux32 makechrootpkg -n -r /var/lib/archbuild/$1-i686
-makechrootpkg -cuI ../../virtualbox/trunk/virtualbox-libre-host-dkms-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64
-makechrootpkg -I ../../virtualbox/trunk/virtualbox-libre-guest-dkms-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64
-makechrootpkg -r /var/lib/archbuild/$1-x86_64
+cd /var/empty
+makechrootpkg -cu -I "$here"/../../virtualbox/trunk/virtualbox-libre-host-dkms-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64
+makechrootpkg -I "$here"/../../virtualbox/trunk/virtualbox-libre-guest-dkms-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64
+cd "$here"
+makechrootpkg -n -r /var/lib/archbuild/$1-x86_64
# vim:set ts=2 sw=2 ft=sh et: