(trunk third-party) #3707 "remove dependency to which" -- committed. fix by geirha.

This commit is contained in:
Charles Kerr 2010-11-02 13:37:34 +00:00
parent 8e6c7f3249
commit 2060f72f22
1 changed files with 3 additions and 12 deletions

View File

@ -12,18 +12,9 @@ if [ -f /etc/debian_version ]; then
OS_VERSION=`cat /etc/debian_version` OS_VERSION=`cat /etc/debian_version`
fi fi
# use lsb_release (Linux Standard Base) when available # use lsb_release (Linux Standard Base) when available
LSB_RELEASE=`which lsb_release` if os_name=`lsb_release -i -s 2>/dev/null`; then
if [ 0 -eq $? -a -x "${LSB_RELEASE}" ]; then OS_NAME=$os_name
OS_NAME=`${LSB_RELEASE} -i -s` OS_VERSION=`lsb_release -r -s`
OS_VERSION=`${LSB_RELEASE} -r -s`
case $OS_NAME in
Debian)
#OS_VERSION=`${LSB_RELEASE} -c -s`
;;
Ubuntu)
#OS_VERSION=`${LSB_RELEASE} -c -s`
;;
esac
fi fi
echo "Detected OS [$OS_NAME] version [$OS_VERSION]" echo "Detected OS [$OS_NAME] version [$OS_VERSION]"