2010-05-11 22:55:35 +02:00
|
|
|
#!/bin/sh
|
|
|
|
# This script helps you to make the source package
|
|
|
|
# of the virtualbox guest additions kernel modules.
|
|
|
|
# IMPORTANT: The virtualbox-ose-addons version you want to use
|
|
|
|
# must already be installed!
|
|
|
|
|
|
|
|
# Based on the ffmpeg-mksrctarball.sh from the SlackBuilds.org repository
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
PRGNAM=virtualbox-kernel-addons
|
2010-07-20 16:25:51 +02:00
|
|
|
VERSION=$(VBoxControl --help 2>/dev/null | grep OSE | rev | cut -d " " -f 1 | rev | cut -d "_" -f 1)
|
2010-05-11 22:55:35 +02:00
|
|
|
|
|
|
|
mkdir $PRGNAM
|
|
|
|
|
|
|
|
echo "--> Copying sourcecode from /usr/src"
|
2010-05-13 00:42:16 +02:00
|
|
|
cp -rf /usr/src/vboxguest-$VERSION $PRGNAM/vboxguest
|
2010-07-20 16:25:51 +02:00
|
|
|
cp -rf /usr/src/vboxsf-$VERSION $PRGNAM/vboxsf
|
2010-05-13 00:42:16 +02:00
|
|
|
cp -rf /usr/src/vboxvideo-$VERSION $PRGNAM/vboxvideo
|
2010-05-11 22:55:35 +02:00
|
|
|
|
2010-05-13 00:42:16 +02:00
|
|
|
echo "--> Making the sourcecode tarball: $PRGNAM-src-$VERSION.tar.xz"
|
|
|
|
tar -cJf $PRGNAM-$VERSION.tar.xz $PRGNAM
|
2010-05-11 22:55:35 +02:00
|
|
|
|
|
|
|
echo "--> Erasing the sourcecode directory: $PRGNAM/"
|
|
|
|
rm -rf $PRGNAM/
|
|
|
|
|
2010-05-13 00:42:16 +02:00
|
|
|
echo "--> Sourcecode tarball for $PRGNAM: $PRGNAM-$VERSION.tar.xz"
|