156 OS=`uname -s` |
156 OS=`uname -s` |
157 OS_VERSION=`uname -r` |
157 OS_VERSION=`uname -r` |
158 printf "detect platform... " |
158 printf "detect platform... " |
159 if [ "$OS" = "SunOS" ]; then |
159 if [ "$OS" = "SunOS" ]; then |
160 PLATFORM="solaris sunos unix svr4" |
160 PLATFORM="solaris sunos unix svr4" |
161 fi |
161 elif [ "$OS" = "Linux" ]; then |
162 if [ "$OS" = "Linux" ]; then |
|
163 PLATFORM="linux unix" |
162 PLATFORM="linux unix" |
164 fi |
163 elif [ "$OS" = "FreeBSD" ]; then |
165 if [ "$OS" = "FreeBSD" ]; then |
|
166 PLATFORM="freebsd bsd unix" |
164 PLATFORM="freebsd bsd unix" |
167 fi |
165 elif [ "$OS" = "OpenBSD" ]; then |
168 if [ "$OS" = "OpenBSD" ]; then |
|
169 PLATFORM="openbsd bsd unix" |
166 PLATFORM="openbsd bsd unix" |
170 fi |
167 elif [ "$OS" = "NetBSD" ]; then |
171 if [ "$OS" = "Darwin" ]; then |
168 PLATFORM="netbsd bsd unix" |
|
169 elif [ "$OS" = "Darwin" ]; then |
172 PLATFORM="macos osx bsd unix" |
170 PLATFORM="macos osx bsd unix" |
173 fi |
171 elif echo "$OS" | grep -i "MINGW" > /dev/null; then |
174 if echo "$OS" | grep -i "MINGW" > /dev/null; then |
|
175 PLATFORM="windows mingw" |
172 PLATFORM="windows mingw" |
176 fi |
173 fi |
177 : ${PLATFORM:="unix"} |
174 : ${PLATFORM:="unix"} |
178 |
175 |
179 PLATFORM_NAME=`echo "$PLATFORM" | cut -f1 -d' ' -` |
176 PLATFORM_NAME=`echo "$PLATFORM" | cut -f1 -d' ' -` |