VBoxSysInfo.sh revision 7e443c8da6e409ead5037f14fde35b0d43440155
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Installer (Unix-like)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Information about the host system/Linux distribution
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Copyright (C) 2006-2007 innotek GmbH
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# This file is part of VirtualBox Open Source Edition (OSE), as
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# available from http://www.virtualbox.org. This file is free software;
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# you can redistribute it and/or modify it under the terms of the GNU
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# General Public License as published by the Free Software Foundation,
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# distribution. VirtualBox OSE is distributed in the hope that it will
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# be useful, but WITHOUT ANY WARRANTY of any kind.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Print information about a Linux system
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# @param distribution name of the distribution
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# @param version version of the distribution
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync # The following regex is not quite correct for an e-mail address, as
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync # the local part may not start or end with a dot. Please correct if
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync kern_ver=`cat /proc/version | sed -e 's/ ([a-zA-Z0-9.!#$%*/?^{}\`+=_-]*@[a-zA-Z0-9.-]*)//'`
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync echo "Distribution: $1 | Version: $2 | Kernel: $kern_ver"
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Determine the distribution name and release for a Linux system and print
# For practical reasons (i.e. lack of time), this function only gives
if [ -r /etc/lsb-release ] && grep Ubuntu /etc/lsb-release >/dev/null 2>&1
. /etc/lsb-release
elif [ -r /etc/debian_version ]
elif [ -r /etc/mandriva-release ]
elif [ -r /etc/fedora-release ]
elif [ -r /etc/SuSE-release ]
if grep openSUSE /etc/SuSE-release
elif [ -r /etc/gentoo-release ]
elif [ -r /etc/slackware-version ]
elif [ -r /etc/arch-release ]
elif [ -r /etc/redhat-release ]