Browse Source

xap/virtualbox-ose: Removed.

slackware-14.2
Damien Goutte-Gattat 9 years ago
parent
commit
d68909315b
  1. 2
      xap/virtualbox-ose/.gitignore
  2. 15
      xap/virtualbox-ose/LocalConfig.kmk
  3. 3
      xap/virtualbox-ose/checksums
  4. 26
      xap/virtualbox-ose/doinst.sh
  5. 12
      xap/virtualbox-ose/slack-desc
  6. 188
      xap/virtualbox-ose/virtualbox-ose.SlackBuild

2
xap/virtualbox-ose/.gitignore vendored

@ -1,2 +0,0 @@
UserManual.pdf
VBoxGuestAdditions_3.1.0.iso

15
xap/virtualbox-ose/LocalConfig.kmk

@ -1,15 +0,0 @@
DEFS += RTPATH_APP_PRIVATE=\"/usr/share/virtualbox\"
VBOX_WITH_TESTCASES :=
VBOX_WITH_TESTSUITE :=
VBOX_WITHOUT_ADDITIONS := 1
KBUILD_MSG_STYLE := brief
VBOX_WITH_ORIGIN :=
VBOX_PATH_APP_PRIVATE_ARCH := /usr/lib/virtualbox
VBOX_PATH_SHARED_LIBS := $(VBOX_PATH_APP_PRIVATE_ARCH)
VBOX_WITH_RUNPATH := $(VBOX_PATH_APP_PRIVATE_ARCH)
VBOX_PATH_APP_PRIVATE := /usr/share/virtualbox
VBOX_PATH_APP_DOCS = $(VBOX_PATH_PACKAGE_DOCS)

3
xap/virtualbox-ose/checksums

@ -1,3 +0,0 @@
fb7c97d692fc8e9973578ef44a848a5988694606 VirtualBox-3.1.0-OSE.tar.bz2
54338892178e55d9d159c132295471429369373d VBoxGuestAdditions_3.1.0.iso
2aabcc8b4616291ed5d0fda60d8f885ea2b7d583 UserManual.pdf

26
xap/virtualbox-ose/doinst.sh

@ -1,26 +0,0 @@
#!/bin/sh
config()
{
NEW="$1"
OLD="`dirname $NEW`/`basename $NEW .new`"
if [ ! -r $OLD ]; then
mv $NEW $OLD
elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then
rm $NEW
fi
}
config /etc/vbox/vbox.cfg.new
if ! grep ^vbox: /etc/group 2>&1 > /dev/null; then
/usr/sbin/groupadd -g 215 vbox
fi
chown root:vbox /usr/bin/VBoxTunctl /usr/share/virtualbox/VBoxSysInfo.sh
chown -R root:vbox /usr/lib/virtualbox/
for i in VirtualBox VBoxSDL VBoxHeadless; do
if [ -f /usr/lib/virtualbox/$i ]; then
chmod 4750 /usr/lib/virtualbox/$i
fi
done

12
xap/virtualbox-ose/slack-desc

@ -1,12 +0,0 @@
|-----handy-ruler----------------------------------------------|
virtualbox-ose: virtualbox-ose (x86 virtualizer)
virtualbox-ose:
virtualbox-ose: Sun VirtualBox is a general-purpose full virtualizer for x86
virtualbox-ose: hardware.
virtualbox-ose:
virtualbox-ose: This is the Open Source Edition of VirtualBox, licensed under
virtualbox-ose: the terms of the GNU General Public License.
virtualbox-ose:
virtualbox-ose:
virtualbox-ose:
virtualbox-ose:

188
xap/virtualbox-ose/virtualbox-ose.SlackBuild

@ -1,188 +0,0 @@
#!/bin/bash
# Build script for Slackware
# Copyright (C) 2009 Damien Goutte-Gattat
#
# Redistribution and use of this script, with or without modifications,
# is permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#
# Contact: Damien Goutte-Gattat <dgouttegattat@incenp.org>
#
# Latest virtualbox-ose sourcecode is available at:
# <http://www.virtualbox.org/>.
#
# Depends: d/iasl
#
# Notes: To build VirtualBox, you need a compiler able to generate
# 32-bit binaries and the corresponding 32-bit libraries; these
# are provided by Eric Hameleers' "multilib" packages, found at
# <http://connie.slackware.com/~alien/multilib/>.
#
# This SlackBuild does not build the kernel modules needed to run
# VirtualBox; instead, their sources are installed in
# /usr/src/virtualbox-kmods-$VERSION. It is up to the
# administrator to compile these modules against the desired
# Linux kernel and install them.
# Source package infos
NAMESRC=${NAMESRC:-VirtualBox}
VERSION=${VERSION:-3.1.0}
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION-OSE.tar.bz2}
GUESTISO=${GUESTISO:-VBoxGuestAdditions_$VERSION.iso}
BASEURL=${BASEURL:-http://download.virtualbox.org/virtualbox/$VERSION}
# Build infos
NAMEPKG=${NAMEPKG:-virtualbox-ose}
BUILD=${BUILD:-1GGD}
ARCH=${ARCH:-i486}
JOBS=${JOBS:-1}
EXT=${EXT:-txz}
# Directories
TMP=${TMP:-/tmp}
OUT=${OUT:-$TMP/build}
PKG=${PKG:-$OUT/$NAMEPKG}
CWD=$(pwd)
set -e # Quit if a command returns non-zero
# Sanity checks
if [ $UID -eq 0 ]; then
echo "You should NOT run this script as ROOT!"
exit 1
fi
if [ ! -d $TMP ]; then
echo "$TMP does not exist or is not a directory!"
exit 1
fi
# Compilation flags
LIBDIR=/usr/lib/virtualbox
case "$ARCH" in
i?86)
CPUOPT="-O2 -march=$ARCH -mtune=i686"
ARCHNAME="x86"
;;
x86_64)
CPUOPT="-O2 -fPIC"
LIBDIR=/usr/lib64/virtualbox
ARCHNAME="amd64"
;;
*)
CPUOPT="-O2"
ARCHNAME=$ARCH
;;
esac
# Get and verify the files
if [ ! -r $ARCHIVE ]; then
wget -c -O $ARCHIVE.part "$BASEURL/$ARCHIVE"
mv $ARCHIVE.part $ARCHIVE
fi
if [ ! -r $GUESTISO ]; then
wget -c -O $GUESTISO.part "$BASEURL/$GUESTISO"
mv $GUESTISO.part $GUESTISO
fi
if [ ! -r UserManual.pdf ]; then
wget -c -O UserManual.pdf.part "$BASEURL/UserManual.pdf"
mv UserManual.pdf.part UserManual.pdf
fi
sha1sum -c checksums
NAME=$(tar ft $ARCHIVE | head -n 1 | cut -d / -f 1)
# Compile
cd $TMP
echo "Building $ARCHIVE..."
tar xf $CWD/$ARCHIVE
cd $NAME
CFLAGS=$CPUOPT \
CXXFLAGS=$CPUOPT \
./configure \
--disable-kmods \
--disable-pulse
. env.sh
sed -e "s,/usr/lib/virtualbox,$LIBDIR," $CWD/LocalConfig.kmk > LocalConfig.kmk
kmk -j ${JOBS} LOCALCFG=LocalConfig.kmk
# Create directories
mkdir -p $PKG/etc/vbox \
$PKG/lib/udev/rules.d \
$PKG/usr/bin \
$PKG$LIBDIR \
$PKG/usr/share/virtualbox \
$PKG/usr/doc/$NAMEPKG-$VERSION \
$PKG/usr/src \
$PKG/usr/share/applications \
$PKG/usr/share/pixmaps \
$PKG/install
# Install config file and udev rule
echo "INSTALL_DIR='$LIBDIR'" > $PKG/etc/vbox/vbox.cfg.new
echo 'KERNEL=="vboxdrv", NAME"vboxdrv", OWNER="root", GROUP="vbox", ' \
'MODE="0660"' > $PKG/lib/udev/rules.d/60-vboxdrv.rules
# Install built files
(
cd out/linux.$ARCHNAME/release/bin
mv VBox.png $PKG/usr/share/pixmaps/
mv nls *.tar.gz $PKG/usr/share/virtualbox/
sed 's,^Doc.*$,DocPath=file:///usr/share/virtualbox/UserManual.pdf,' \
virtualbox.desktop > $PKG/usr/share/applications/virtualbox.desktop
rm virtualbox.desktop
mv src $PKG/usr/src/virtualbox-kmods-$VERSION
mv sdk $PKG/usr/share/virtualbox/
install -m 750 VBoxSysInfo.sh $PKG/usr/share/virtualbox/
install -m 750 VBoxTunctl $PKG/usr/bin
rm VBoxSysInfo.sh VBoxTunctl
mv * $PKG$LIBDIR/
chmod -R 750 $PKG$LIBDIR/
mv $PKG$LIBDIR/VBox.sh $PKG$LIBDIR/VBox
)
# Create symlinks
for i in VirtualBox VBoxManage VBoxSDL VBoxHeadless VBoxVRDP ; do
ln -s $LIBDIR/VBox $PKG/usr/bin/$i
done
# Copy auxiliary files
cp $CWD/$GUESTISO $PKG/usr/share/virtualbox/
cp $CWD/UserManual.pdf $PKG/usr/share/virtualbox/
# Install the documentation
mkdir -p $PKG/usr/doc/$NAMEPKG-$VERSION
install -m 644 COPYING COPYING.CDDL $PKG/usr/doc/$NAMEPKG-$VERSION
# Copy slack-desc and doinst.sh files
mkdir -p $PKG/install
install -m 644 $CWD/slack-desc $PKG/install/slack-desc
sed -e "s,/usr/lib/virtualbox,$LIBDIR," $CWD/doinst.sh > $PKG/install/doinst.sh
chmod 755 $PKG/install/doinst.sh
# Package the tree
cd $PKG
mkdir -p $OUT
PACKAGING="
chown root:root . -R
/sbin/makepkg -l y -c n $OUT/$NAMEPKG-$VERSION-$ARCH-$BUILD.$EXT
rm -rf $PKG
rm -rf $TMP/$NAME
"
if type -p fakeroot ; then
echo "$PACKAGING" | fakeroot
else
su -c "$PACKAGING"
fi
Loading…
Cancel
Save