slackbuilds/libraries/miniupnpc/slackware-version.patch

29 lines
939 B
Diff

diff -Naur miniupnpc-1.6.orig/updateminiupnpcstrings.sh miniupnpc-1.6/updateminiupnpcstrings.sh
--- miniupnpc-1.6.orig/updateminiupnpcstrings.sh 2011-01-27 17:50:40.000000000 +0000
+++ miniupnpc-1.6/updateminiupnpcstrings.sh 2011-12-04 20:55:22.313144966 +0000
@@ -14,19 +14,11 @@
OS_NAME=Debian
OS_VERSION=`cat /etc/debian_version`
fi
-# use lsb_release (Linux Standard Base) when available
-LSB_RELEASE=`which lsb_release`
-if [ 0 -eq $? -a -x "${LSB_RELEASE}" ]; then
- OS_NAME=`${LSB_RELEASE} -i -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
+
+# Slackware specific stuff.
+if [ -f /etc/slackware-version ]; then
+ OS_NAME=`cat /etc/slackware-version | cut -d' ' -f1`
+ OS_VERSION=`cat /etc/slackware-version | cut -d' ' -f2`
fi
# on AmigaOS 3, uname -r returns "unknown", so we use uname -v