summaryrefslogtreecommitdiff
path: root/package/mksh
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2017-04-15 20:26:00 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2017-04-15 20:26:12 +0200
commit5cc97866f5b2b1aac415c644556539affd73fc77 (patch)
treeeb8355456d54f908f122eb2c302a591ef2985358 /package/mksh
parent067a5fbdfbe4de906e3a8d4244a4a141b7ef7fe9 (diff)
mksh: update to r55, remove old test.sh
Diffstat (limited to 'package/mksh')
-rw-r--r--package/mksh/Makefile9
-rwxr-xr-xpackage/mksh/files/test.sh85
2 files changed, 6 insertions, 88 deletions
diff --git a/package/mksh/Makefile b/package/mksh/Makefile
index c618ebd9e..d32669647 100644
--- a/package/mksh/Makefile
+++ b/package/mksh/Makefile
@@ -4,9 +4,9 @@
include $(ADK_TOPDIR)/rules.mk
PKG_NAME:= mksh
-PKG_VERSION:= 54
+PKG_VERSION:= 55
PKG_RELEASE:= 1
-PKG_HASH:= 8bce3837c386684aa7780f085f1a4dbd5e3e26fb5c528ee0d41ae29af7f39013
+PKG_HASH:= ced42cb4a181d97d52d98009eed753bd553f7c34e6991d404f9a8dcb45c35a57
PKG_DESCR:= mirbsd korn shell
PKG_SECTION:= base/shells
PKG_NEEDS:= mmu
@@ -59,7 +59,10 @@ mksh-test-install:
$(INSTALL_DIR) $(IDIR_MKSH_TEST)/opt/mksh
$(CP) $(WRKBUILD)/* $(IDIR_MKSH_TEST)/opt/mksh
find $(IDIR_MKSH_TEST)/opt/mksh -name \*.o -delete
- $(INSTALL_BIN) ./files/test.sh $(IDIR_MKSH_TEST)/opt/mksh
+ $(SED) \
+ 's!$(WRKBUILD)!/opt/mksh!g' \
+ -e "s!PATH='[^']*'!PATH='/usr/sbin:/bin:/sbin:/usr/bin'!" \
+ $(IDIR_MKSH_TEST)/opt/mksh/test.sh
include $(ADK_TOPDIR)/mk/host-bottom.mk
include $(ADK_TOPDIR)/mk/pkg-bottom.mk
diff --git a/package/mksh/files/test.sh b/package/mksh/files/test.sh
deleted file mode 100755
index 6b6a6c439..000000000
--- a/package/mksh/files/test.sh
+++ /dev/null
@@ -1,85 +0,0 @@
-#!/bin/mksh
-LC_ALL=C PATH='/usr/sbin:/bin:/sbin:/usr/bin'; export LC_ALL PATH
-test -n "$KSH_VERSION" || exit 1
-set -A check_categories -- shell:legacy-no int:32
-pflag='/opt/mksh/mksh'
-sflag='/opt/mksh/check.t'
-usee=0 Pflag=0 Sflag=0 uset=0 vflag=1 xflag=0
-while getopts "C:e:fPp:QSs:t:v" ch; do case $ch {
-(C) check_categories[${#check_categories[*]}]=$OPTARG ;;
-(e) usee=1; eflag=$OPTARG ;;
-(f) check_categories[${#check_categories[*]}]=fastbox ;;
-(P) Pflag=1 ;;
-(+P) Pflag=0 ;;
-(p) pflag=$OPTARG ;;
-(Q) vflag=0 ;;
-(+Q) vflag=1 ;;
-(S) Sflag=1 ;;
-(+S) Sflag=0 ;;
-(s) sflag=$OPTARG ;;
-(t) uset=1; tflag=$OPTARG ;;
-(v) vflag=1 ;;
-(+v) vflag=0 ;;
-(*) xflag=1 ;;
-}
-done
-shift $((OPTIND - 1))
-set -A args -- '/opt/mksh/check.pl' -p "$pflag"
-x=
-for y in "${check_categories[@]}"; do
-x=$x,$y
-done
-if [[ -n $x ]]; then
-args[${#args[*]}]=-C
-args[${#args[*]}]=${x#,}
-fi
-if (( usee )); then
-args[${#args[*]}]=-e
-args[${#args[*]}]=$eflag
-fi
-(( Pflag )) && args[${#args[*]}]=-P
-if (( uset )); then
-args[${#args[*]}]=-t
-args[${#args[*]}]=$tflag
-fi
-(( vflag )) && args[${#args[*]}]=-v
-(( xflag )) && args[${#args[*]}]=-x # force usage by synerr
-if [[ -n $TMPDIR && -d $TMPDIR/. ]]; then
-args[${#args[*]}]=-T
-args[${#args[*]}]=$TMPDIR
-fi
-print Testing mksh for conformance:
-fgrep -e MirOS: -e MIRBSD "$sflag"
-print "This shell is actually:\n\t$KSH_VERSION"
-print 'test.sh built for mksh R51 2015/07/10'
-cstr='$os = defined $^O ? $^O : "unknown";'
-cstr="$cstr"'print $os . ", Perl version " . $];'
-for perli in perl no; do
-if [[ $perli = no ]]; then
-print Cannot find a working Perl interpreter, aborting.
-exit 1
-fi
-print "Trying Perl interpreter '$perli'..."
-perlos=$($perli -e "$cstr")
-rv=$?
-print "Errorlevel $rv, running on '$perlos'"
-if (( rv )); then
-print "=> not using"
-continue
-fi
-if [[ -n $perlos ]]; then
-print "=> using it"
-break
-fi
-done
-(( Sflag )) || echo + $perli "${args[@]}" -s "$sflag" "$@"
-(( Sflag )) || exec $perli "${args[@]}" -s "$sflag" "$@"
-# use of the -S option for check.t split into multiple chunks
-rv=0
-for s in "$sflag".*; do
-echo + $perli "${args[@]}" -s "$s" "$@"
-$perli "${args[@]}" -s "$s" "$@"
-rc=$?
-(( rv = rv ? rv : rc ))
-done
-exit $rv