diff options
author | Nicolás Reynolds <fauno@kiwwwi.com.ar> | 2012-11-06 13:37:54 -0300 |
---|---|---|
committer | Nicolás Reynolds <fauno@kiwwwi.com.ar> | 2012-11-06 13:37:54 -0300 |
commit | a48d075b90120462b9f97ab95a224d47e072f7dd (patch) | |
tree | 8ba729381a11d91f09b298d888636425c549498b /libre/virtualbox-libre-modules-lts | |
parent | 4ce84837520f8c56ae998d5d2d98380faf3e3eb5 (diff) | |
parent | 8ab3c2d0517cb4db3ab2f7635d0b71b701e464ba (diff) | |
download | abslibre-a48d075b90120462b9f97ab95a224d47e072f7dd.tar.gz abslibre-a48d075b90120462b9f97ab95a224d47e072f7dd.tar.bz2 abslibre-a48d075b90120462b9f97ab95a224d47e072f7dd.zip |
Merge branch 'master' of ssh://gparabola/srv/git/abslibre
Diffstat (limited to 'libre/virtualbox-libre-modules-lts')
4 files changed, 123 insertions, 0 deletions
diff --git a/libre/virtualbox-libre-modules-lts/PKGBUILD b/libre/virtualbox-libre-modules-lts/PKGBUILD new file mode 100644 index 000000000..d836a3a37 --- /dev/null +++ b/libre/virtualbox-libre-modules-lts/PKGBUILD @@ -0,0 +1,71 @@ +# $Id$ +# Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl> +# Contributor: Ionut Biru <ibiru@archlinux.org> +# Contributor: Sébastien Luttringer <seblu@aur.archlinux.org> +# Maintainer (Parabola): Jorge López <jorginho@lavabit.com> +# Maintainer (Parabola): André Silva <emulatorman@lavabit.com> + +pkgbase=virtualbox-libre-modules-lts +pkgname=('virtualbox-libre-host-modules-lts' 'virtualbox-libre-guest-modules-lts') +pkgver=4.2.4 +pkgrel=1.1 +arch=('i686' 'x86_64') +url='http://virtualbox.org' +license=('GPL') +makedepends=('linux-libre-lts-headers' + "virtualbox-libre-host-source>=$pkgver" + "virtualbox-libre-guest-source>=$pkgver" + 'expac') + +build() { + # current kernel libre version + _kernver=$(expac -Q '%v' linux-libre-lts-headers)-LIBRE-LTS + # dkms need modification to be run as user + cp -r /var/lib/dkms . + echo "dkms_tree='$srcdir/dkms'" > dkms.conf + # build host modules + msg2 'Host modules' + dkms --dkmsframework dkms.conf build "vboxhost/$pkgver" -k "$_kernver" + # build guest modules + msg2 'Guest modules' + dkms --dkmsframework dkms.conf build "vboxguest/$pkgver" -k "$_kernver" +} + +package_virtualbox-libre-host-modules-lts(){ + pkgdesc='Host kernel libre modules for VirtualBox' + depends=('linux-libre-lts>=3.0' 'linux-libre-lts<3.1') + replaces=('virtualbox-host-modules-lts' 'virtualbox-modules-lts' 'virtualbox-libre-modules-lts') + conflicts=('virtualbox-host-modules-lts' 'virtualbox-modules-lts' 'virtualbox-libre-modules-lts') + provides=("virtualbox-host-modules-lts=$pkgver" "virtualbox-libre-host-modules=$pkgver") + install=virtualbox-libre-host-modules-lts.install + + _kernver=$(expac -Q '%v' linux-libre-lts-headers)-LIBRE-LTS + _extraver=extramodules-${_kernver%.*}-LIBRE-LTS + + install -dm755 "$pkgdir/usr/lib/modules/$_extraver" + cd "dkms/vboxhost/$pkgver/$_kernver/$CARCH/module" + install -m644 * "$pkgdir/usr/lib/modules/$_extraver" + find "$pkgdir" -name '*.ko' -exec gzip -9 {} + + sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extraver'/" "$startdir/virtualbox-libre-host-modules-lts.install" +} + +package_virtualbox-libre-guest-modules-lts(){ + pkgdesc='Guest kernel libre modules for VirtualBox' + license=('GPL') + depends=('linux-libre-lts>=3.0' 'linux-libre-lts<3.1') + replaces=('virtualbox-guest-modules-lts' 'virtualbox-archlinux-modules-lts' 'virtualbox-libre-parabola-modules-lts') + conflicts=('virtualbox-guest-modules-lts' 'virtualbox-archlinux-modules-lts' 'virtualbox-libre-parabola-modules-lts') + provides=("virtualbox-guest-modules-lts=$pkgver" "virtualbox-libre-host-modules=$pkgver") + install=virtualbox-libre-guest-modules-lts.install + + _kernver=$(expac -Q '%v' linux-libre-lts-headers)-LIBRE-LTS + _extraver=extramodules-${_kernver%.*}-LIBRE-LTS + + install -dm755 "$pkgdir/usr/lib/modules/$_extraver" + cd "dkms/vboxguest/$pkgver/$_kernver/$CARCH/module" + install -m644 * "$pkgdir/usr/lib/modules/$_extraver" + find "$pkgdir" -name '*.ko' -exec gzip -9 {} + + sed -ie "s/EXTRAMODULES='.*'/EXTRAMODULES='$_extraver'/" "$startdir/virtualbox-libre-guest-modules-lts.install" +} + +# vim:set ts=2 sw=2 et: diff --git a/libre/virtualbox-libre-modules-lts/build.sh b/libre/virtualbox-libre-modules-lts/build.sh new file mode 100755 index 000000000..4c3c29e30 --- /dev/null +++ b/libre/virtualbox-libre-modules-lts/build.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +if (( $# != 1 )); then + echo "usage: $0 extra" + echo " $0 testing" + exit 1 +fi + +linux32 makechrootpkg -cu -I ../../virtualbox/trunk/virtualbox-libre-host-source-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686 +linux32 makechrootpkg -I ../../virtualbox/trunk/virtualbox-libre-guest-source-*-i686.pkg.tar.xz -r /var/lib/archbuild/$1-i686 +linux32 makechrootpkg -r /var/lib/archbuild/$1-i686 + +makechrootpkg -cu -I ../../virtualbox/trunk/virtualbox-libre-host-source-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64 +makechrootpkg -I ../../virtualbox/trunk/virtualbox-libre-guest-source-*-x86_64.pkg.tar.xz -r /var/lib/archbuild/$1-x86_64 +makechrootpkg -r /var/lib/archbuild/$1-x86_64 + + +# vim:set ts=2 sw=2 ft=sh et: diff --git a/libre/virtualbox-libre-modules-lts/virtualbox-libre-guest-modules-lts.install b/libre/virtualbox-libre-modules-lts/virtualbox-libre-guest-modules-lts.install new file mode 100644 index 000000000..54a052390 --- /dev/null +++ b/libre/virtualbox-libre-modules-lts/virtualbox-libre-guest-modules-lts.install @@ -0,0 +1,16 @@ +EXTRAMODULES='extramodules-3.0-LIBRE-LTS' + +post_install() { +cat << EOF +===> You may want to load vboxguest, vboxsf and vboxvideo +EOF + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) +} + +post_upgrade() { + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) +} + +post_remove() { + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) +} diff --git a/libre/virtualbox-libre-modules-lts/virtualbox-libre-host-modules-lts.install b/libre/virtualbox-libre-modules-lts/virtualbox-libre-host-modules-lts.install new file mode 100644 index 000000000..4503996e8 --- /dev/null +++ b/libre/virtualbox-libre-modules-lts/virtualbox-libre-host-modules-lts.install @@ -0,0 +1,18 @@ +EXTRAMODULES='extramodules-3.0-LIBRE-LTS' + +post_install() { +cat << EOF +===> You must load vboxdrv module before starting VirtualBox: +===> # modprobe vboxdrv +EOF + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) +} + +post_upgrade() { + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) + echo 'In order to use the new version, reload all virtualbox modules manually.' +} + +post_remove() { + depmod $(cat /usr/lib/modules/$EXTRAMODULES/version) +} |