]> git.stg.codes - stg.git/blobdiff - projects/rscriptd/build
Corrected upload/download mess.
[stg.git] / projects / rscriptd / build
index 68a64f874abf089b58f47f06bdd9d351d9b3ad45..5af638ebb34c42f6140e0a1c049e8d9042987cc2 100755 (executable)
@@ -7,7 +7,8 @@
 
 OS=unknown
 sys=`uname -s`
-release=`uname -r | cut -b1`
+release=`uname -r`
+major=`printf "%s" "$release" | cut -d. -f1`
 BUILD_DIR=`pwd`
 CONFFILE="../../Makefile.conf"
 PREFIX="/"
@@ -35,13 +36,12 @@ LDFLAGS="$LDFLAGS -L/usr/local/lib"
 if [ "$sys" = "Linux" ]
 then
     OS=linux
-    release=""
     MAKE="make"
 fi
 
 if [ "$sys" = "FreeBSD" ]
 then
-    case $release in
+    case $major in
         4) OS=bsd;;
         5) OS=bsd5;;
         6) OS=bsd5;;