wok-next annotate virtualbox-ose/receipt @ rev 10347
Add pkcs and truecrypt.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Sun May 22 14:35:15 2011 +0000 (2011-05-22) |
parents | d9ece80135d3 |
children | 3bc4a50f1694 |
rev | line source |
---|---|
slaxemulator@7064 | 1 # SliTaz package receipt. |
slaxemulator@7064 | 2 |
slaxemulator@7064 | 3 PACKAGE="virtualbox-ose" |
slaxemulator@10102 | 4 VERSION="4.0.8" |
slaxemulator@7064 | 5 CATEGORY="misc" |
slaxemulator@7064 | 6 SHORT_DESC="Powerful x86 virtualization for enterprise as well as home use (Open Source Edition)" |
slaxemulator@7064 | 7 MAINTAINER="slaxemulator@gmail.com" |
slaxemulator@7064 | 8 SOURCE="VirtualBox" |
slaxemulator@7814 | 9 TARBALL="$SOURCE-$VERSION.tar.bz2" |
slaxemulator@7064 | 10 WEB_SITE="http://virtualbox.org/" |
slaxemulator@7064 | 11 WGET_URL="http://download.virtualbox.org/virtualbox/$VERSION/$TARBALL" |
pascal@8969 | 12 PROVIDE="virtualbox" |
slaxemulator@7064 | 13 |
slaxemulator@9841 | 14 DEPENDS="libxml2 xorg-libXcursor libIDL xorg-libXinerama libsdl \ |
slaxemulator@9841 | 15 xorg-libXmu curl libvncserver libpng jpeg mesa libglu-mesa qt4 vde2" |
slaxemulator@9841 | 16 BUILD_DEPENDS="bin86 dev86 iasl libxslt-dev Qt4-dev libsdl-ttf-dev \ |
slaxemulator@9841 | 17 alsa-lib-dev hal-dev xorg-libXtst-dev xorg-libXrandr-dev python \ |
slaxemulator@9841 | 18 python-dev xalan-c curl-dev xalan-c-dev xerces-c-dev openssl-dev zlib-dev \ |
slaxemulator@9841 | 19 libcap-dev glib-dev pam pam-dev bzip2 linux-module-headers \ |
slaxemulator@9841 | 20 pkg-config tar wget" |
slaxemulator@9841 | 21 |
slaxemulator@7064 | 22 # Rules to configure and make the package. |
slaxemulator@7064 | 23 compile_rules() |
slaxemulator@7064 | 24 { |
slaxemulator@7064 | 25 cd $src |
slaxemulator@8484 | 26 patch -Np1 -i "$stuff/virtualbox-4-makeself-check.patch" |
slaxemulator@8715 | 27 patch -Np1 -i "$stuff/virtualbox-4-mkisofs-check.patch" |
slaxemulator@8715 | 28 cp $stuff/LocalConfig.kmk . |
slaxemulator@7064 | 29 ./configure \ |
slaxemulator@7064 | 30 --disable-pulse \ |
slaxemulator@7814 | 31 --disable-java \ |
slaxemulator@7814 | 32 --disable-docs \ |
slaxemulator@8484 | 33 --enable-webservice \ |
slaxemulator@8715 | 34 --enable-vde \ |
slaxemulator@7064 | 35 --with-linux=/usr/src/linux |
slaxemulator@7064 | 36 source ./env.sh |
slaxemulator@7064 | 37 kmk all |
slaxemulator@7064 | 38 |
slaxemulator@7064 | 39 # build modules |
slaxemulator@7814 | 40 cd |
slaxemulator@7814 | 41 KERN_DIR=/usr/src/linux make -C "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/src" |
slaxemulator@7064 | 42 # build guest additions modules |
slaxemulator@7814 | 43 KERN_DIR=/usr/src/linux make -C "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/additions/src" |
slaxemulator@7814 | 44 KERN_DIR=/usr/src/linux make -C "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/additions/src/vboxvideo" |
slaxemulator@7064 | 45 } |
slaxemulator@7064 | 46 |
slaxemulator@7064 | 47 # Rules to gen a SliTaz package suitable for Tazpkg. |
slaxemulator@7064 | 48 genpkg_rules() |
slaxemulator@7064 | 49 { |
slaxemulator@7064 | 50 fs=$WOK/$PACKAGE/taz/$PACKAGE-$VERSION/fs |
slaxemulator@7064 | 51 |
slaxemulator@7064 | 52 source $src/env.sh |
slaxemulator@7064 | 53 cd $src/out/linux.$BUILD_PLATFORM_ARCH/release/bin |
slaxemulator@8005 | 54 mkdir -p $fs/usr/bin $fs/usr/lib/virtualbox/components \ |
slaxemulator@8715 | 55 $fs/usr/share/virtualbox/nls \ |
slaxemulator@8715 | 56 $fs/usr/lib/virtualbox/ExtensionPacks |
slaxemulator@8715 | 57 install -m 0755 VBox.sh $fs/usr/bin/VBox |
slaxemulator@7064 | 58 sed -i 's/ps -U/ps | grep/' $fs/usr/bin/VBox |
slaxemulator@7064 | 59 ln -sf VBox $fs/usr/bin/VBoxHeadless |
slaxemulator@8715 | 60 ln -sf VBox $fs/usr/bin/vboxheadless |
slaxemulator@7064 | 61 ln -sf VBox $fs/usr/bin/VBoxManage |
slaxemulator@8715 | 62 ln -sf VBox $fs/usr/bin/vboxmanage |
slaxemulator@7064 | 63 ln -sf VBox $fs/usr/bin/VBoxSDL |
slaxemulator@8715 | 64 ln -sf VBox $fs/usr/bin/vboxsdl |
slaxemulator@7064 | 65 ln -sf VBox $fs/usr/bin/VirtualBox |
slaxemulator@8715 | 66 ln -sf VBox $fs/usr/bin/virtualbox |
slaxemulator@8715 | 67 ln -sf VBox $fs/usr/bin/vboxwebsrv |
slaxemulator@7064 | 68 |
slaxemulator@7064 | 69 install -m 0755 VBoxTunctl "$fs/usr/bin" |
slaxemulator@7064 | 70 |
slaxemulator@7064 | 71 # components |
slaxemulator@8715 | 72 install -D -m 0755 components/* $fs/usr/lib/virtualbox/components |
slaxemulator@7064 | 73 |
slaxemulator@7064 | 74 # lib |
slaxemulator@7064 | 75 install -m 0755 *.so "$fs/usr/lib/virtualbox" |
slaxemulator@7064 | 76 install -m 0644 *.gc *.r0 VBoxEFI*.fd "$fs/usr/lib/virtualbox" |
slaxemulator@7064 | 77 |
slaxemulator@7064 | 78 #setuid root binaries |
slaxemulator@8715 | 79 install -m 4755 VBoxSDL VirtualBox VBoxHeadless VBoxNetDHCP VBoxNetAdpCtl "$fs/usr/lib/virtualbox" |
slaxemulator@7064 | 80 |
slaxemulator@7064 | 81 #other binaries |
pascal@9071 | 82 #install -m 0755 VBoxManage VBoxSVC VBoxExtPackHelperApp VBoxXPCOMIPCD VBoxTestOGL vboxwebsrv webtest "$fs/usr/lib/virtualbox" |
pascal@9071 | 83 install -m 0755 VBoxManage VBoxSVC VBoxExtPackHelperApp VBoxXPCOMIPCD VBoxTestOGL "$fs/usr/lib/virtualbox" |
slaxemulator@7064 | 84 |
slaxemulator@7064 | 85 #language |
slaxemulator@7064 | 86 install -m 0755 nls/*.qm "$fs/usr/share/virtualbox/nls" |
slaxemulator@8715 | 87 |
slaxemulator@8715 | 88 #useless scripts |
slaxemulator@8715 | 89 install -m 0755 VBoxCreateUSBNode.sh VBoxSysInfo.sh "$fs/usr/share/virtualbox" |
slaxemulator@7064 | 90 |
slaxemulator@7064 | 91 #icon |
slaxemulator@7064 | 92 install -D -m 0644 VBox.png "$fs/usr/share/pixmaps/VBox.png" |
slaxemulator@7064 | 93 |
slaxemulator@7064 | 94 #desktop |
slaxemulator@7064 | 95 install -D -m 0644 virtualbox.desktop "$fs/usr/share/applications/virtualbox.desktop" |
slaxemulator@8715 | 96 install -D -m 0644 virtualbox.xml "$fs/usr/share/mime/packages/virtualbox.xml" |
slaxemulator@7064 | 97 |
slaxemulator@7064 | 98 #install configuration |
slaxemulator@7064 | 99 mkdir -p "$fs/etc/vbox" |
slaxemulator@7064 | 100 echo 'lsmod | grep -q vboxdrv || modprobe vboxdrv' > "$fs/etc/vbox/vbox.cfg" |
slaxemulator@7064 | 101 echo 'INSTALL_DIR=/usr/lib/virtualbox' >> "$fs/etc/vbox/vbox.cfg" |
slaxemulator@7064 | 102 |
slaxemulator@7064 | 103 #udev |
slaxemulator@7064 | 104 install -D -m 0644 "$stuff/60-virtualbox.rules" \ |
slaxemulator@7064 | 105 "$fs/etc/udev/rules.d/60-virtualbox.rules" |
slaxemulator@7064 | 106 |
slaxemulator@7064 | 107 mkdir -p $fs/usr/lib/virtualbox/sdk/bindings/xpcom/python/ |
slaxemulator@8005 | 108 cd sdk/installer |
slaxemulator@7064 | 109 VBOX_INSTALL_PATH="/usr/lib/virtualbox" python vboxapisetup.py install --root "$fs" |
slaxemulator@8010 | 110 cd $src/out/linux.$BUILD_PLATFORM_ARCH/release/bin |
slaxemulator@8005 | 111 cd sdk/bindings/xpcom/python |
slaxemulator@7064 | 112 cp -r xpcom $fs/usr/lib/virtualbox/sdk/bindings/xpcom/python/ |
slaxemulator@7064 | 113 chmod 644 $fs/usr/lib/virtualbox/sdk/bindings/xpcom/python/xpcom/*.py |
slaxemulator@7064 | 114 chmod 644 $fs/usr/lib/virtualbox/sdk/bindings/xpcom/python/xpcom/server/*.py |
slaxemulator@7064 | 115 chmod 644 $fs/usr/lib/virtualbox/sdk/bindings/xpcom/python/xpcom/client/*.py |
slaxemulator@8010 | 116 cd $src/out/linux.$BUILD_PLATFORM_ARCH/release/bin |
slaxemulator@7064 | 117 |
slaxemulator@7064 | 118 # virtualbox-modules |
slaxemulator@7064 | 119 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'` |
slaxemulator@7064 | 120 |
slaxemulator@7064 | 121 cd "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/src" |
slaxemulator@7064 | 122 install -D -m644 vboxdrv.ko "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxdrv.ko" |
slaxemulator@7064 | 123 install -D -m644 vboxnetflt.ko "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxnetflt.ko" |
slaxemulator@7064 | 124 install -D -m644 vboxnetadp.ko "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxnetadp.ko" |
slaxemulator@7064 | 125 |
slaxemulator@7064 | 126 # virtualbox-ose-additions |
slaxemulator@7064 | 127 |
slaxemulator@7064 | 128 cd "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/additions" |
slaxemulator@7064 | 129 mkdir -p $fs/usr/bin |
slaxemulator@7064 | 130 mkdir -p $fs/sbin |
slaxemulator@7064 | 131 mkdir -p $fs/etc/X11/xorg.conf.d |
slaxemulator@7064 | 132 |
slaxemulator@7064 | 133 install -m755 VBoxClient VBoxControl VBoxService "$fs/usr/bin" |
slaxemulator@7064 | 134 install -m755 mount.vboxsf "$fs/sbin" |
slaxemulator@7064 | 135 |
slaxemulator@7064 | 136 install -m644 $src/src/VBox/Additions/x11/Installer/50-vboxmouse.conf \ |
slaxemulator@7064 | 137 $fs/etc/X11/xorg.conf.d/50-vboxmouse.conf |
slaxemulator@7064 | 138 |
slaxemulator@7064 | 139 install -m755 -D $src/src/VBox/Additions/x11/Installer/98vboxadd-xclient \ |
slaxemulator@7064 | 140 $fs/usr/bin/VBoxClient-all |
slaxemulator@7064 | 141 install -m755 -D $src/src/VBox/Additions/x11/Installer/vboxclient.desktop \ |
slaxemulator@7064 | 142 $fs/etc/xdg/autostart/vboxclient.desktop |
slaxemulator@7064 | 143 |
slaxemulator@7064 | 144 install -D vboxmouse_drv_19.so \ |
slaxemulator@7391 | 145 "$fs/usr/lib/X11/modules/input/vboxmouse.so" |
slaxemulator@7064 | 146 install -D vboxvideo_drv_19.so \ |
slaxemulator@7391 | 147 "$fs/usr/lib/X11/modules/drivers/vboxvideo.so" |
slaxemulator@7064 | 148 install -d "$fs/usr/lib/dri" |
slaxemulator@7064 | 149 install -m755 VBoxOGL*.so "$fs/usr/lib" |
slaxemulator@7064 | 150 ln -s /usr/lib/VBoxOGL.so "$fs/usr/lib/dri/vboxvideo_dri.so" |
slaxemulator@7064 | 151 install -m755 -D pam_vbox.so "$fs/lib/security/pam_vbox.so" |
slaxemulator@7064 | 152 |
slaxemulator@7064 | 153 # virtualbox-ose-additions-modules |
slaxemulator@7064 | 154 cd "$src/out/linux.$BUILD_PLATFORM_ARCH/release/bin/additions/src" |
slaxemulator@7064 | 155 |
slaxemulator@7064 | 156 cd vboxguest |
slaxemulator@7064 | 157 install -D -m644 vboxguest.ko \ |
slaxemulator@7064 | 158 "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxguest.ko" |
slaxemulator@7064 | 159 |
slaxemulator@7064 | 160 cd ../vboxsf |
slaxemulator@7064 | 161 install -D -m644 vboxsf.ko \ |
slaxemulator@7064 | 162 "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxsf.ko" |
slaxemulator@7064 | 163 |
slaxemulator@7064 | 164 cd ../vboxvideo |
slaxemulator@7064 | 165 install -D -m644 vboxvideo.ko \ |
slaxemulator@7064 | 166 "$fs/lib/modules/$KERNEL_VERSION-slitaz/misc/vboxvideo.ko" |
slaxemulator@7064 | 167 |
slaxemulator@7064 | 168 install -D -m 0644 "$stuff/60-vboxguest.rules" \ |
slaxemulator@7064 | 169 "$fs/etc/udev/rules.d/60-vboxguest.rules" |
slaxemulator@7064 | 170 } |
slaxemulator@7064 | 171 |
slaxemulator@7154 | 172 pre_remove() |
slaxemulator@7154 | 173 { |
slaxemulator@7652 | 174 sed -i "s/vboxdrv vboxnetadp vboxnetflt //" $1/etc/rcS.conf |
slaxemulator@7154 | 175 } |
slaxemulator@7154 | 176 |
slaxemulator@7154 | 177 post_install() |
slaxemulator@7154 | 178 { |
slaxemulator@7154 | 179 KERNEL_VERSION=`grep ^VERSION= $1/var/lib/tazpkg/installed/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'` |
slaxemulator@7154 | 180 |
slaxemulator@7159 | 181 chroot "$1/" depmod -a $KERNEL_VERSION-slitaz |
slaxemulator@7154 | 182 grep -qs vboxdrv $1/etc/rcS.conf || |
slaxemulator@7662 | 183 sed -i 's/LOAD_MODULES="/&vboxdrv vboxnetadp vboxnetflt /' $1/etc/rcS.conf |
slaxemulator@7154 | 184 } |