Subject: bin/23553: src/bin/test/TEST.csh uses csh; csh is evil
To: None <gnats-bugs@gnats.netbsd.org>
From: None <bjan@bjan.net>
List: netbsd-bugs
Date: 11/24/2003 00:15:15
>Number: 23553
>Category: bin
>Synopsis: src/bin/test/TEST.csh uses csh; csh is evil
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Mon Nov 24 07:18:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator: Bruce J.A. Nourish
>Release: NetBSD 1.6ZF
>Organization:
Unladen Swallows of Great Britain Ltd.
>Environment:
System: NetBSD telstar.bjan.net 1.6ZF NetBSD 1.6ZF (GENERIC) #2: Thu Nov 20 22:20:51 MST 2003 root@telstar.bjan.net:/usr/obj/sys/arch/i386/compile/GENERIC i386
Architecture: i386
Machine: i386
>Description:
src/bin/test has a testsuite written in csh. csh is deprecated in it's
role as a non-interactive programming language. This small patch
changes the script to use a bourne shell such as sh(1).
>How-To-Repeat:
Get a copy of netbsd. Look in src/bin/test.
>Fix:
Apply the following patch, and then move TEST.csh to TEST.sh. Done.
--- TEST.csh 1995-03-21 00:03:59.000000000 -0700
+++ TEST.sh 2003-11-23 16:39:47.000000000 -0700
@@ -1,8 +1,13 @@
-# $NetBSD: TEST.csh,v 1.2 1995/03/21 07:03:59 cgd Exp $
+# $NetBSD: TEST.csh,v 1.2 1995/03/21 07:03:59 cgd Exp $
# @(#)TEST.csh 5.2 (Berkeley) 4/30/93
#alias t '/usr/src/bin/test/obj/test \!*; echo $status'
-alias t '/bin/test \!*; echo $status'
+#alias t '/bin/test \!*; echo $status'
+
+t () {
+ /bin/test "$@"
+ echo $?
+}
echo 't -b /dev/ttyp2'
t -b /dev/ttyp2
>Release-Note:
>Audit-Trail:
>Unformatted: