export_modules revision e0539912a07dde0a5edee92f30f98615ebd32c1a
#
# Create a tar archive containing the sources of the vboxdrv kernel module
#
# Copyright (C) 2007 Sun Microsystems, Inc.
#
# This file is part of VirtualBox Open Source Edition (OSE), as
# available from http://www.virtualbox.org. This file is free software;
# General Public License (GPL) as published by the Free Software
# Foundation, in version 2 as it comes in the "COPYING" file of the
# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
#
# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
# Clara, CA 95054 USA or visit http://www.sun.com if you need
# additional information or have any questions.
#
if [ -z "$1" ]; then
echo "Usage: $0 <filename.tar.gz> [--without-hardening]"
echo " Export VirtualBox kernel modules to <filename.tar.gz>"
exit 1
fi
if [ "$2" = "--without-hardening" ]; then
fi
VBOX_VERSION_MAJOR=`sed -e "s/^ *VBOX_VERSION_MAJOR *= \+\([0-9]\+\)/\1/;t;d" $PATH_ROOT/Config.kmk`
VBOX_VERSION_MINOR=`sed -e "s/^ *VBOX_VERSION_MINOR *= \+\([0-9]\+\)/\1/;t;d" $PATH_ROOT/Config.kmk`
VBOX_VERSION_BUILD=`sed -e "s/^ *VBOX_VERSION_BUILD *= \+\([0-9]\+\)/\1/;t;d" $PATH_ROOT/Config.kmk`
# Temporary path for creating the modules, will be removed later
# Create auto-generated version file, needed by all modules
# vboxdrv (VirtualBox host kernel module)
for f in $FILES_VBOXDRV_NOBIN; do
done
for f in $FILES_VBOXDRV_BIN; do
done
sed -e "s;_VERSION_;$VBOX_VERSION_STRING;g" < $PATH_LINUX/build_in_tmp > $PATH_TMP/vboxdrv/build_in_tmp
sed -e "s;_VERSION_;$VBOX_VERSION_STRING;g" < $PATH_VBOXDRV/linux/dkms.conf > $PATH_TMP/vboxdrv/dkms.conf
if [ -n "$VBOX_WITH_HARDENING" ]; then
else
fi
# vboxnetflt (VirtualBox netfilter kernel module)
for f in $VBOX_VBOXNETFLT_SOURCES; do
done
sed -e "s;_VERSION_;$VBOX_VERSION_STRING;g" < $PATH_LINUX/build_in_tmp > $PATH_TMP/vboxnetflt/build_in_tmp
sed -e "s;_VERSION_;$VBOX_VERSION_STRING;g" < $PATH_VBOXNET/linux/dkms.conf > $PATH_TMP/vboxnetflt/dkms.conf
if [ -n "$VBOX_WITH_HARDENING" ]; then
else
fi
# Only temporary, omit from archive
# Create the archive
# Remove the temporary directory