Welcome to little lamb

Code » comain » commit 67e7afe

Some posix SH compatibility fixes

author Olivier Brunel
2024-01-06 12:31:26 UTC
committer Olivier Brunel
2024-01-09 18:17:27 UTC
parent cb87624c64f8c4732373dc9e01a57fb566c0a403

Some posix SH compatibility fixes

configure +2 -2
mkrelease +2 -2

diff --git a/configure b/configure
index 952bfc4..3219572 100755
--- a/configure
+++ b/configure
@@ -206,7 +206,7 @@ procdep_real()
                 echo $s
                 return
             fi
-            i=$(( ++i ))
+            i=$(( i + 1 ))
         done
         echo "$isint NOTFOUND"
     fi
@@ -269,7 +269,7 @@ procdep_search()
                     r=1
                     break
                 fi
-                i=$(( ++i ))
+                i=$(( i + 1 ))
             done
             if test $r -eq 0; then
                 echo $isint INCNOTFOUND
diff --git a/mkrelease b/mkrelease
index a8d99e9..1457617 100755
--- a/mkrelease
+++ b/mkrelease
@@ -34,7 +34,7 @@ case "$1" in
     rev) rev=$(($rev + 1)) ; rc=0 ;;
     rc)
         if test $rc -gt 0; then
-            (( ++rc ))
+            rc=$(( rc + 1 ))
         else
             error 2 "current version not an rc; try major|minor|rev rc"
         fi
@@ -46,7 +46,7 @@ shift
 if test $# -eq 1; then
     if test "$1" = "rc"; then
         test $rc -gt 0 && error 2 "cannot use rc on rc"
-        (( ++rc ))
+        rc=$(( rc + 1 ))
     else
         error 1 "invalid argument: $1"
     fi