polish, mop up whitespace, etc.
passes regressions on MirOS
This commit is contained in:
parent
bb629ad8eb
commit
6c8eabf72e
47
Build.sh
47
Build.sh
@ -1,24 +1,25 @@
|
||||
#!/bin/sh
|
||||
# $MirBSD: Build.sh,v 1.2 2004/05/24 16:24:40 tg Exp $
|
||||
# $MirBSD: Build.sh,v 1.3 2004/05/24 19:55:51 tg Exp $
|
||||
#-
|
||||
# Copyright (c) 2004
|
||||
# Thorsten "mirabile" Glaser <x86@ePost.de>
|
||||
# Thorsten Glaser <x86@ePost.de>
|
||||
#
|
||||
# Subject to these terms, everybody who obtained a copy of this work
|
||||
# is hereby permitted to deal in the work without restriction inclu-
|
||||
# ding without limitation the rights to use, distribute, sell, modi-
|
||||
# fy, publically perform, give away, merge or sublicence it provided
|
||||
# this notice is kept and the authors and contributors are given due
|
||||
# credit in derivates or accompanying documents.
|
||||
# Licensee is hereby permitted to deal in this work without restric-
|
||||
# tion, including unlimited rights to use, publically perform, modi-
|
||||
# fy, merge, distribute, sell, give away or sublicence, provided the
|
||||
# above copyright notices, these terms and the disclaimer are retai-
|
||||
# ned in all redistributions, or reproduced in accompanying documen-
|
||||
# tation or other materials provided with binary redistributions.
|
||||
#
|
||||
# This work is provided by its developers (authors and contributors)
|
||||
# "as is" and without any warranties whatsoever, express or implied,
|
||||
# to the maximum extent permitted by applicable law; in no event may
|
||||
# developers be held liable for damage caused, directly or indirect-
|
||||
# ly, but not by a developer's malice intent, even if advised of the
|
||||
# possibility of such damage.
|
||||
# Licensor hereby provides this work "AS IS" and WITHOUT WARRANTY of
|
||||
# any kind, expressed or implied, to the maximum extent permitted by
|
||||
# applicable law, but with the warranty of being written without ma-
|
||||
# licious intent or gross negligence; in no event shall an author or
|
||||
# contributor be held liable for any direct, indirect or other dama-
|
||||
# ge, however caused, arising in any way out of the usage of covered
|
||||
# work, even if advised of the possibility of such damage.
|
||||
#-
|
||||
# Build the mirbsdksh on GNU and other operating systems.
|
||||
# Build the more||less portable mirbsdksh on most operating systems.
|
||||
# Notes for building on various operating systems:
|
||||
# - on most OSes, you will need a pre-installed bash or ksh to build
|
||||
# because the Bourne shell chokes on some statements below.
|
||||
@ -30,25 +31,23 @@ SHELL="${SHELL:-/bin/sh}"; export SHELL
|
||||
CONFIG_SHELL="${SHELL}"; export CONFIG_SHELL
|
||||
CC="${CC:-gcc}"
|
||||
CPPFLAGS="$CPPFLAGS -DHAVE_CONFIG_H -I. -DKSH"
|
||||
CFLAGS="-O2 -fomit-frame-pointer -fno-strict-aliasing $CFLAGS"
|
||||
COPTS="-O2 -fomit-frame-pointer -fno-strict-aliasing -fno-strength-reduce"
|
||||
[ -z "$WEIRD_OS" ] && LDFLAGS="${LDFLAGS:--static}"
|
||||
|
||||
if [ -e strlfun.c ]; then
|
||||
if test -e strlfun.c; then
|
||||
echo "Configuring..."
|
||||
$SHELL ./configure
|
||||
echo "Generating prerequisites..."
|
||||
$SHELL ./siglist.sh "gcc -E $CPPFLAGS" <siglist.in >siglist.out
|
||||
$SHELL ./emacs-gen.sh emacs.c >emacs.out
|
||||
echo "Building..."
|
||||
$CC $CFLAGS $CPPFLAGS $LDFLAGS -o ksh *.c
|
||||
$CC $COPTS $CFLAGS $CPPFLAGS $LDFLAGS -o ksh.unstripped *.c
|
||||
echo "Finalizing..."
|
||||
tbl <ksh.1tbl | nroff -mandoc -Tascii >ksh.cat1
|
||||
tbl <ksh.1tbl >ksh.1
|
||||
nroff -mandoc -Tascii <ksh.1 >ksh.cat1
|
||||
if [ -z "$WEIRD_OS" ]; then
|
||||
cp ksh ksh.unstripped
|
||||
strip -R .note -R .comment -R .rel.dyn -R .sbss \
|
||||
--strip-unneeded --strip-all ksh \
|
||||
|| strip ksh || mv ksh.unstripped ksh
|
||||
rm -f ksh.unstripped
|
||||
--strip-unneeded --strip-all ksh || strip ksh
|
||||
else
|
||||
echo "Remember to strip the ksh binary!"
|
||||
fi
|
||||
@ -63,5 +62,5 @@ else
|
||||
echo "it and try again! Due to the folks of Ulrich"
|
||||
echo "Drepper & co. not including strlcpy/strlcat,"
|
||||
echo "this is a necessity to circumvent the broken"
|
||||
echo "libc imitation of GNU."
|
||||
echo "libc imitation of GNU's."
|
||||
fi
|
||||
|
16
LEGAL
16
LEGAL
@ -1,16 +0,0 @@
|
||||
$MirBSD: LEGAL,v 1.6 2004/04/24 21:45:00 tg Exp $
|
||||
$OpenBSD: LEGAL,v 1.2 2003/07/17 20:59:43 deraadt Exp $
|
||||
|
||||
pdksh is provided AS IS, with NO WARRANTY, either expressed or implied.
|
||||
|
||||
The vast majority of the code that makes pdksh is in the public domain.
|
||||
The exceptions are not included in the MirBSD source tree.
|
||||
|
||||
That's it. Short and simple.
|
||||
|
||||
Now european (except Commonwealth) copyright laws come into the game.
|
||||
This means, public domain does not exist, and authors are always
|
||||
liable for a minimum of things.
|
||||
That's why, this package is placed under the MirOS licence template, found
|
||||
at https://mirbsd.bsdadvocacy.org/cvs.cgi/src/share/misc/licence.template
|
||||
or at the top of the "Build.sh" file found in the standalone distfile.
|
1
PROJECTS
1
PROJECTS
@ -1,3 +1,4 @@
|
||||
$MirBSD: PROJECTS,v 1.2 2004/05/24 19:55:53 tg Exp $
|
||||
$OpenBSD: PROJECTS,v 1.5 1999/07/14 13:37:23 millert Exp $
|
||||
|
||||
Things to be done in pdksh (see also the NOTES file):
|
||||
|
45
README
45
README
@ -1,4 +1,47 @@
|
||||
$MirBSD: README,v 1.2 2004/04/17 00:47:16 tg Exp $
|
||||
$MirBSD: README,v 1.3 2004/05/24 19:55:53 tg Stab $
|
||||
|
||||
This is the README for mirbsdksh, developed as part of the MirBSD
|
||||
operating system at The MirOS Project, and produced portably.
|
||||
Legal information is provided about a screenpage farther down.
|
||||
|
||||
To build on MirOS only, issue 'make obj && make depend && make'.
|
||||
|
||||
To build on other systems, consult:
|
||||
* if you have a pre-installed GNU bash or (pd)ksh
|
||||
=> there have been build problems e.g. with /bin/sh on
|
||||
Solaris, which isn't the Bourne shell anyways
|
||||
* if you can build statically
|
||||
=> this is not possible on Solaris and Mac OSX, for example
|
||||
* if you need additional libs
|
||||
|
||||
Then issue a command like
|
||||
$ SHELL=bash bash ./Build.sh
|
||||
$ SHELL=ksh WEIRD_OS=1 LDFLAGS=-ldl ksh ./Build.sh
|
||||
|
||||
Always try with as few options first as possible.
|
||||
|
||||
Set the CC, CFLAGS, CPPFLAGS and LDFLAGS environment variables
|
||||
to your likes. Don't complain if anything doesn't work.
|
||||
|
||||
|
||||
LEGAL INFORMATION
|
||||
|
||||
This package as a whole is placed under the MirOS licence, found at
|
||||
https://mirbsd.bsdadvocacy.org/cvs.cgi/src/share/misc/licence.template
|
||||
as well as on top of the "Build.sh" or "rnd.c" files found in the
|
||||
distribution.
|
||||
The files alloc.c (Marc Espie), ksh.1tbl and sh.1tbl (University of
|
||||
California, Berkeley) are provided under a 2-clause or 3-clause BSD
|
||||
licence, respectively.
|
||||
|
||||
All files from the original pdksh distribution which were not public
|
||||
domain have been removed from the source tree, with the exception of
|
||||
aclocal.m4, from which only the functions which required the file to
|
||||
be under the GNU GPL have been removed.
|
||||
|
||||
|
||||
________________________________________________________________________
|
||||
|
||||
$OpenBSD: README,v 1.10 2003/03/10 03:48:16 david Exp $
|
||||
|
||||
Last updated Jul '99 for pdksh-5.2.14.
|
||||
|
2
aclocal.m4
vendored
2
aclocal.m4
vendored
@ -1,4 +1,4 @@
|
||||
dnl $MirBSD: aclocal.m4,v 1.8 2004/05/24 17:32:10 tg Exp $
|
||||
dnl $MirBSD: aclocal.m4,v 1.9 2004/05/24 19:55:54 tg Stab $
|
||||
dnl
|
||||
dnl Copyright (c) 2004 Thorsten Glaser
|
||||
dnl Copyright (C) 1996, Memorial University of Newfoundland.
|
||||
|
2
alloc.c
2
alloc.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: alloc.c,v 1.3 2004/05/23 12:47:00 tg Exp $ */
|
||||
/* $MirBSD: alloc.c,v 1.4 2004/05/24 19:55:55 tg Stab $ */
|
||||
/* $OpenBSD: alloc.c,v 1.7 2004/02/19 18:51:17 deraadt Exp $ */
|
||||
|
||||
/*
|
||||
|
2
c_ksh.c
2
c_ksh.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: c_ksh.c,v 1.3 2004/05/23 12:47:00 tg Exp $ */
|
||||
/* $MirBSD: c_ksh.c,v 1.4 2004/05/24 19:55:55 tg Stab $ */
|
||||
/* $OpenBSD: c_ksh.c,v 1.18 2004/02/10 13:03:36 jmc Exp $ */
|
||||
|
||||
/*
|
||||
|
4
c_sh.c
4
c_sh.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: c_sh.c,v 1.2 2004/04/17 00:47:17 tg Exp $ */
|
||||
/* $OpenBSD: c_sh.c,v 1.17 2003/03/13 09:03:07 deraadt Exp $ */
|
||||
/* $MirBSD: c_sh.c,v 1.3 2004/05/24 19:55:55 tg Stab $ */
|
||||
/* $OpenBSD: c_sh.c,v 1.17 2003/03/13 09:03:07 deraadt Exp $ */
|
||||
|
||||
/*
|
||||
* built-in Bourne commands
|
||||
|
4
c_test.c
4
c_test.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: c_test.c,v 1.2 2004/04/17 00:47:17 tg Exp $ */
|
||||
/* $OpenBSD: c_test.c,v 1.10 2003/10/10 19:09:07 millert Exp $ */
|
||||
/* $MirBSD: c_test.c,v 1.3 2004/05/24 19:55:57 tg Stab $ */
|
||||
/* $OpenBSD: c_test.c,v 1.10 2003/10/10 19:09:07 millert Exp $ */
|
||||
|
||||
/*
|
||||
* test(1); version 7-like -- author Erik Baalbergen
|
||||
|
3
c_test.h
3
c_test.h
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: c_test.h,v 1.2 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: c_test.h,v 1.2 2004/05/24 19:55:58 tg Stab $ */
|
||||
/* $OpenBSD: c_test.h,v 1.2 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/* Various types of operations. Keeping things grouped nicely
|
||||
* (unary,binary) makes switch() statements more efficient.
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: c_ulimit.c,v 1.4 2004/04/07 17:14:11 tg Exp $ */
|
||||
/* $MirBSD: c_ulimit.c,v 1.5 2004/05/24 19:55:58 tg Stab $ */
|
||||
/* $OpenBSD: c_ulimit.c,v 1.10 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
@ -19,8 +19,6 @@
|
||||
that was originally under case SYSULIMIT in source file "xec.c".
|
||||
*/
|
||||
|
||||
static const char RCSId[] = "$MirBSD: c_ulimit.c,v 1.4 2004/04/07 17:14:11 tg Exp $";
|
||||
|
||||
#include "sh.h"
|
||||
#include "ksh_time.h"
|
||||
#ifdef HAVE_SYS_RESOURCE_H
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: conf-end.h,v 1.5 2004/05/24 19:08:52 tg Exp $ */
|
||||
/* $MirBSD: conf-end.h,v 1.6 2004/05/24 19:55:59 tg Stab $ */
|
||||
/* $OpenBSD: conf-end.h,v 1.2 1996/08/25 12:37:58 downsj Exp $ */
|
||||
|
||||
/* Include ksh features? */
|
||||
|
2
config.h
2
config.h
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: config.h,v 1.9 2004/05/24 19:06:54 tg Exp $ */
|
||||
/* $MirBSD: config.h,v 1.10 2004/05/24 19:56:00 tg Exp $ */
|
||||
/* $OpenBSD: config.h,v 1.9 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
|
4
edit.c
4
edit.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: edit.c,v 1.5 2004/04/17 00:47:18 tg Exp $ */
|
||||
/* $OpenBSD: edit.c,v 1.18 2003/08/22 18:17:10 fgsch Exp $ */
|
||||
/* $MirBSD: edit.c,v 1.6 2004/05/24 19:56:04 tg Stab $ */
|
||||
/* $OpenBSD: edit.c,v 1.18 2003/08/22 18:17:10 fgsch Exp $ */
|
||||
|
||||
/*
|
||||
* Command line editing - common code
|
||||
|
18
edit.h
18
edit.h
@ -1,18 +1,6 @@
|
||||
/* $OpenBSD: edit.h,v 1.3 1999/11/14 22:04:02 d Exp $ */
|
||||
|
||||
/* NAME:
|
||||
* edit.h - globals for edit modes
|
||||
*
|
||||
* DESCRIPTION:
|
||||
* This header defines various global edit objects.
|
||||
*
|
||||
* SEE ALSO:
|
||||
*
|
||||
*
|
||||
* RCSid:
|
||||
* $From: edit.h,v 1.2 1994/05/19 18:32:40 michael Exp michael $
|
||||
*
|
||||
*/
|
||||
/* $MirBSD: edit.h,v 1.2 2004/05/24 19:56:05 tg Stab $ */
|
||||
/* $OpenBSD: edit.h,v 1.3 1999/11/14 22:04:02 d Exp $ */
|
||||
/* $From: edit.h,v 1.2 1994/05/19 18:32:40 michael Exp michael $ */
|
||||
|
||||
/* some useful #defines */
|
||||
#ifdef EXTERN
|
||||
|
@ -1,5 +1,6 @@
|
||||
#!/bin/sh
|
||||
# $OpenBSD: emacs-gen.sh,v 1.1.1.1 1996/08/14 06:19:10 downsj Exp $
|
||||
# $MirBSD: emacs-gen.sh,v 1.2 2004/05/24 19:56:05 tg Stab $
|
||||
# $OpenBSD: emacs-gen.sh,v 1.1.1.1 1996/08/14 06:19:10 downsj Exp $
|
||||
|
||||
case $# in
|
||||
1) file=$1;;
|
||||
|
4
emacs.c
4
emacs.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: emacs.c,v 1.7 2003/12/23 13:41:48 tg Exp $ */
|
||||
/* $OpenBSD: emacs.c,v 1.28 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: emacs.c,v 1.8 2004/05/24 19:56:05 tg Stab $ */
|
||||
/* $OpenBSD: emacs.c,v 1.28 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* Emacs-like command line editing and history
|
||||
|
3
eval.c
3
eval.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: eval.c,v 1.14 2003/11/10 21:26:39 millert Exp $ */
|
||||
/* $MirBSD: eval.c,v 1.2 2004/05/24 19:56:06 tg Stab $ */
|
||||
/* $OpenBSD: eval.c,v 1.14 2003/11/10 21:26:39 millert Exp $ */
|
||||
|
||||
/*
|
||||
* Expansion - quoting, separation, substitution, globbing
|
||||
|
3
exec.c
3
exec.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: exec.c,v 1.31 2003/12/15 05:25:52 otto Exp $ */
|
||||
/* $MirBSD: exec.c,v 1.2 2004/05/24 19:56:07 tg Stab $ */
|
||||
/* $OpenBSD: exec.c,v 1.31 2003/12/15 05:25:52 otto Exp $ */
|
||||
|
||||
/*
|
||||
* execute command tree
|
||||
|
3
expand.h
3
expand.h
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: expand.h,v 1.3 2001/03/26 16:19:45 todd Exp $ */
|
||||
/* $MirBSD: expand.h,v 1.2 2004/05/24 19:56:08 tg Stab $ */
|
||||
/* $OpenBSD: expand.h,v 1.3 2001/03/26 16:19:45 todd Exp $ */
|
||||
|
||||
/*
|
||||
* Expanding strings
|
||||
|
7
expr.c
7
expr.c
@ -1,12 +1,9 @@
|
||||
/* $MirBSD: expr.c,v 1.2 2004/04/17 00:47:18 tg Exp $ */
|
||||
/* $OpenBSD: expr.c,v 1.9 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: expr.c,v 1.3 2004/05/24 19:56:09 tg Stab $ */
|
||||
/* $OpenBSD: expr.c,v 1.9 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* Korn expression evaluation
|
||||
*/
|
||||
/*
|
||||
* todo: better error handling: if in builtin, should be builtin error, etc.
|
||||
*/
|
||||
|
||||
#include "sh.h"
|
||||
#include <ctype.h>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: history.c,v 1.7 2004/04/17 00:47:18 tg Exp $ */
|
||||
/* $OpenBSD: history.c,v 1.22 2003/05/18 01:02:42 jsyn Exp $ */
|
||||
/* $MirBSD: history.c,v 1.8 2004/05/24 19:56:09 tg Exp $ */
|
||||
/* $OpenBSD: history.c,v 1.22 2003/05/18 01:02:42 jsyn Exp $ */
|
||||
|
||||
/*
|
||||
* command history
|
||||
|
2
io.c
2
io.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: io.c,v 1.3 2004/04/07 17:24:40 tg Exp $ */
|
||||
/* $MirBSD: io.c,v 1.4 2004/05/24 19:56:10 tg Stab $ */
|
||||
/* $OpenBSD: io.c,v 1.13 2003/11/10 21:26:39 millert Exp $ */
|
||||
|
||||
/*
|
||||
|
2
jobs.c
2
jobs.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: jobs.c,v 1.3 2004/04/17 00:47:19 tg Exp $ */
|
||||
/* $MirBSD: jobs.c,v 1.4 2004/05/24 19:56:11 tg Stab $ */
|
||||
/* $OpenBSD: jobs.c,v 1.21 2003/11/10 21:26:39 millert Exp $ */
|
||||
|
||||
/*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: ksh_dir.h,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $ */
|
||||
/* $MirBSD: ksh_dir.h,v 1.2 2004/05/24 19:56:13 tg Stab $ */
|
||||
/* $OpenBSD: ksh_dir.h,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $ */
|
||||
|
||||
/* Wrapper around the ugly dir includes/ifdefs */
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: ksh_limval.h,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $ */
|
||||
/* $MirBSD: ksh_limval.h,v 1.2 2004/05/24 19:56:13 tg Stab $ */
|
||||
/* $OpenBSD: ksh_limval.h,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $ */
|
||||
|
||||
/* Wrapper around the values.h/limits.h includes/ifdefs */
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: ksh_stat.h,v 1.2 2004/05/24 17:25:43 tg Exp $ */
|
||||
/* $MirBSD: ksh_stat.h,v 1.3 2004/05/24 19:56:14 tg Stab $ */
|
||||
/* $OpenBSD: ksh_stat.h,v 1.3 1996/10/01 02:05:39 downsj Exp $ */
|
||||
|
||||
/* Wrapper around the ugly sys/stat includes/ifdefs */
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: ksh_time.h,v 1.2 1996/10/01 02:05:40 downsj Exp $ */
|
||||
/* $MirBSD: ksh_time.h,v 1.2 2004/05/24 19:56:14 tg Stab $ */
|
||||
/* $OpenBSD: ksh_time.h,v 1.2 1996/10/01 02:05:40 downsj Exp $ */
|
||||
|
||||
#ifndef KSH_TIME_H
|
||||
# define KSH_TIME_H
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: ksh_times.h,v 1.2 1996/10/01 02:05:41 downsj Exp $ */
|
||||
/* $MirBSD: ksh_times.h,v 1.2 2004/05/24 19:56:14 tg Stab $ */
|
||||
/* $OpenBSD: ksh_times.h,v 1.2 1996/10/01 02:05:41 downsj Exp $ */
|
||||
|
||||
#ifndef KSH_TIMES_H
|
||||
# define KSH_TIMES_H
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: ksh_wait.h,v 1.3 1997/06/19 13:58:43 kstailey Exp $ */
|
||||
/* $MirBSD: ksh_wait.h,v 1.2 2004/05/24 19:56:15 tg Stab $ */
|
||||
/* $OpenBSD: ksh_wait.h,v 1.3 1997/06/19 13:58:43 kstailey Exp $ */
|
||||
|
||||
/* Wrapper around the ugly sys/wait includes/ifdefs */
|
||||
|
||||
|
4
lex.c
4
lex.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: lex.c,v 1.2 2004/04/17 00:47:19 tg Exp $ */
|
||||
/* $OpenBSD: lex.c,v 1.18 2003/08/06 21:08:05 millert Exp $ */
|
||||
/* $MirBSD: lex.c,v 1.3 2004/05/24 19:56:15 tg Stab $ */
|
||||
/* $OpenBSD: lex.c,v 1.18 2003/08/06 21:08:05 millert Exp $ */
|
||||
|
||||
/*
|
||||
* lexical analysis and source input
|
||||
|
6
lex.h
6
lex.h
@ -1,11 +1,11 @@
|
||||
/* $OpenBSD: lex.h,v 1.7 2003/02/28 09:45:09 jmc Exp $ */
|
||||
/* $MirBSD: lex.h,v 1.2 2004/05/24 19:56:16 tg Stab $ */
|
||||
/* $OpenBSD: lex.h,v 1.7 2003/02/28 09:45:09 jmc Exp $ */
|
||||
/* $From: lex.h,v 1.4 1994/05/31 13:34:34 michael Exp $ */
|
||||
|
||||
/*
|
||||
* Source input, lexer and parser
|
||||
*/
|
||||
|
||||
/* $From: lex.h,v 1.4 1994/05/31 13:34:34 michael Exp $ */
|
||||
|
||||
#define IDENT 64
|
||||
|
||||
typedef struct source Source;
|
||||
|
3
mail.c
3
mail.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: mail.c,v 1.9 1999/06/15 01:18:35 millert Exp $ */
|
||||
/* $MirBSD: mail.c,v 1.2 2004/05/24 19:56:16 tg Stab $ */
|
||||
/* $OpenBSD: mail.c,v 1.9 1999/06/15 01:18:35 millert Exp $ */
|
||||
|
||||
/*
|
||||
* Mailbox checking code by Robert J. Gibson, adapted for PD ksh by
|
||||
|
2
main.c
2
main.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: main.c,v 1.7 2004/05/24 19:06:55 tg Exp $ */
|
||||
/* $MirBSD: main.c,v 1.8 2004/05/24 19:56:16 tg Exp $ */
|
||||
/* $OpenBSD: main.c,v 1.26 2004/01/08 05:43:14 jmc Exp $ */
|
||||
|
||||
/*
|
||||
|
4
misc.c
4
misc.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: misc.c,v 1.7 2004/05/24 19:06:55 tg Exp $ */
|
||||
/* $OpenBSD: misc.c,v 1.20 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: misc.c,v 1.8 2004/05/24 19:56:16 tg Stab $ */
|
||||
/* $OpenBSD: misc.c,v 1.20 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* Miscellaneous functions
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: missing.c,v 1.5 2003/05/16 18:49:46 jsyn Exp $ */
|
||||
/* $MirBSD: missing.c,v 1.2 2004/05/24 19:56:17 tg Stab $ */
|
||||
/* $OpenBSD: missing.c,v 1.5 2003/05/16 18:49:46 jsyn Exp $ */
|
||||
|
||||
/*
|
||||
* Routines which may be missing on some machines
|
||||
|
3
path.c
3
path.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: path.c,v 1.9 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: path.c,v 1.2 2004/05/24 19:56:17 tg Stab $ */
|
||||
/* $OpenBSD: path.c,v 1.9 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
#include "sh.h"
|
||||
#include "ksh_stat.h"
|
||||
|
7
proto.h
7
proto.h
@ -1,10 +1,9 @@
|
||||
/* $MirBSD: proto.h,v 1.3 2004/05/24 19:06:55 tg Exp $ */
|
||||
/* $MirBSD: proto.h,v 1.4 2004/05/24 19:56:17 tg Stab $ */
|
||||
/* $OpenBSD: proto.h,v 1.11 2003/05/16 19:58:57 jsyn Exp $ */
|
||||
|
||||
/*
|
||||
/* $From: proto.h,v 1.3 1994/05/19 18:32:40 michael Exp michael $
|
||||
*
|
||||
* prototypes for PD-KSH
|
||||
* originally generated using "cproto.c 3.5 92/04/11 19:28:01 cthuang "
|
||||
* $From: proto.h,v 1.3 1994/05/19 18:32:40 michael Exp michael $
|
||||
*/
|
||||
|
||||
/* alloc.c */
|
||||
|
2
sh.h
2
sh.h
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: sh.h,v 1.8 2004/05/24 19:06:55 tg Exp $ */
|
||||
/* $MirBSD: sh.h,v 1.9 2004/05/24 19:56:17 tg Exp $ */
|
||||
/* $OpenBSD: sh.h,v 1.17 2004/05/10 16:28:47 pvalchev Exp $ */
|
||||
/* $From: sh.h,v 1.2 1994/05/19 18:32:40 michael Exp michael $ */
|
||||
|
||||
|
4
shf.c
4
shf.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: shf.c,v 1.2 2004/04/17 00:47:19 tg Exp $ */
|
||||
/* $OpenBSD: shf.c,v 1.8 2003/02/28 09:45:09 jmc Exp $ */
|
||||
/* $MirBSD: shf.c,v 1.3 2004/05/24 19:56:18 tg Stab $ */
|
||||
/* $OpenBSD: shf.c,v 1.8 2003/02/28 09:45:09 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* Shell file I/O routines
|
||||
|
3
shf.h
3
shf.h
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: shf.h,v 1.2 1999/01/08 20:25:02 millert Exp $ */
|
||||
/* $MirBSD: shf.h,v 1.2 2004/05/24 19:56:18 tg Stab $ */
|
||||
/* $OpenBSD: shf.h,v 1.2 1999/01/08 20:25:02 millert Exp $ */
|
||||
|
||||
#ifndef SHF_H
|
||||
# define SHF_H
|
||||
|
@ -1,4 +1,5 @@
|
||||
# $OpenBSD: siglist.in,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $
|
||||
# $MirBSD: siglist.in,v 1.2 2004/05/24 19:56:18 tg Stab $
|
||||
# $OpenBSD: siglist.in,v 1.1.1.1 1996/08/14 06:19:11 downsj Exp $
|
||||
#
|
||||
# List of signals used to initialize ksh's signal table (see trap.c
|
||||
# and siglist.sh).
|
||||
|
@ -1,10 +1,9 @@
|
||||
#!/bin/sh
|
||||
# $OpenBSD: siglist.sh,v 1.4 1997/06/19 13:58:47 kstailey Exp $
|
||||
|
||||
# $MirBSD: siglist.sh,v 1.2 2004/05/24 19:56:19 tg Stab $
|
||||
# $OpenBSD: siglist.sh,v 1.4 1997/06/19 13:58:47 kstailey Exp $
|
||||
#
|
||||
# Script to generate a sorted, complete list of signals, suitable
|
||||
# for inclusion in trap.c as array initializer.
|
||||
#
|
||||
|
||||
set -e
|
||||
|
||||
|
4
syn.c
4
syn.c
@ -1,5 +1,5 @@
|
||||
/* $MirBSD: syn.c,v 1.2 2004/04/17 00:47:20 tg Exp $ */
|
||||
/* $OpenBSD: syn.c,v 1.14 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: syn.c,v 1.3 2004/05/24 19:56:19 tg Stab $ */
|
||||
/* $OpenBSD: syn.c,v 1.14 2003/10/22 07:40:38 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* shell parser (C version)
|
||||
|
3
table.c
3
table.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: table.c,v 1.5 1999/01/10 17:55:03 millert Exp $ */
|
||||
/* $MirBSD: table.c,v 1.2 2004/05/24 19:56:19 tg Stab $ */
|
||||
/* $OpenBSD: table.c,v 1.5 1999/01/10 17:55:03 millert Exp $ */
|
||||
|
||||
/*
|
||||
* dynamic hashed associative table for commands and variables
|
||||
|
4
table.h
4
table.h
@ -1,5 +1,5 @@
|
||||
/* $OpenBSD: table.h,v 1.5 1999/06/15 01:18:36 millert Exp $ */
|
||||
|
||||
/* $MirBSD: table.h,v 1.2 2004/05/24 19:56:19 tg Stab $ */
|
||||
/* $OpenBSD: table.h,v 1.5 1999/06/15 01:18:36 millert Exp $ */
|
||||
/* $From: table.h,v 1.3 1994/05/31 13:34:34 michael Exp $ */
|
||||
|
||||
/*
|
||||
|
@ -7,7 +7,7 @@ consistent):
|
||||
sh-v generic any system V bourne shell like thing
|
||||
ksh generic any ksh
|
||||
posix generic basic posix shell
|
||||
posix-upu generic `user portability utility' options
|
||||
posix-upu generic 'user portability utility' options
|
||||
sh-v7 specific the real v7 bourne shell
|
||||
sh-sysv specific the real sysv bourne shell
|
||||
pdksh specific public domain ksh
|
||||
@ -15,7 +15,7 @@ consistent):
|
||||
ksh93 specific at&t ksh93
|
||||
bash specific GNU bourne-again shell
|
||||
|
||||
The idea is to categorize all the tests according to the `best match'
|
||||
The idea is to categorize all the tests according to the 'best match'
|
||||
(most generic thing). All generics that apply should be specified.
|
||||
Generally, at most one specific shell will be given.
|
||||
|
||||
|
@ -109,4 +109,3 @@ expected-stdout:
|
||||
hi
|
||||
there
|
||||
---
|
||||
|
||||
|
@ -76,4 +76,3 @@ expected-stdout:
|
||||
6
|
||||
6,5,3
|
||||
---
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
|
||||
|
||||
# $MirBSD: bksl-nl.t,v 1.2 2004/05/24 19:56:24 tg Stab $
|
||||
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
|
||||
#
|
||||
# These tests deal with how \newline is handled in various situations. The
|
||||
# first group of tests are places where it shouldn't be collapsed, the next
|
||||
@ -338,4 +338,3 @@ stdin:
|
||||
expected-stdout:
|
||||
3
|
||||
---
|
||||
|
||||
|
@ -191,5 +191,3 @@ expected-exit: e != 0
|
||||
expected-stderr-pattern:
|
||||
/.*continue.*/
|
||||
---
|
||||
|
||||
|
||||
|
@ -142,4 +142,3 @@ expected-stdout:
|
||||
3: abcdef
|
||||
4: cdef
|
||||
---
|
||||
|
||||
|
@ -96,4 +96,3 @@ stdin:
|
||||
expected-stdout:
|
||||
-bc abc bbc cbc ebc
|
||||
---
|
||||
|
||||
|
@ -328,4 +328,3 @@ expected-stdout:
|
||||
hi
|
||||
Left overs: *
|
||||
---
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
|
||||
|
||||
# $MirBSD: history.t,v 1.2 2004/05/24 19:56:25 tg Stab $
|
||||
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
|
||||
#
|
||||
# Not tested yet:
|
||||
# - commands in history file are not numbered negatively
|
||||
# (and a few hundred other things)
|
||||
@ -169,7 +170,7 @@ expected-stderr-pattern:
|
||||
|
||||
name: history-list-3
|
||||
description:
|
||||
Can give number `options' to fc
|
||||
Can give number 'options' to fc
|
||||
arguments: !-i!
|
||||
env-setup: !ENV=./Env!HISTFILE=hist.file!
|
||||
file-setup: file 644 "Env"
|
||||
|
@ -159,4 +159,3 @@ expected-stdout:
|
||||
<10> <h> <ith> <ere>
|
||||
<11> <h:ith:ere>
|
||||
---
|
||||
|
||||
|
@ -13,7 +13,7 @@ expected-stderr-pattern:
|
||||
|
||||
name: integer-base-err-2
|
||||
description:
|
||||
Can't have multiple bases in a `constant' (causes shell to exit)
|
||||
Can't have multiple bases in a 'constant' (causes shell to exit)
|
||||
(ksh88 fails this test)
|
||||
expected-exit: e != 0
|
||||
stdin:
|
||||
@ -73,7 +73,7 @@ expected-stdout:
|
||||
|
||||
name: integer-base-2
|
||||
description:
|
||||
Check `stickyness' of base in various situations
|
||||
Check 'stickyness' of base in various situations
|
||||
stdin:
|
||||
typeset -i i=8
|
||||
echo $i
|
||||
@ -215,4 +215,3 @@ expected-stdout:
|
||||
64
|
||||
64
|
||||
---
|
||||
|
||||
|
@ -108,4 +108,3 @@ expected-stdout:
|
||||
dot B 3
|
||||
C 3
|
||||
---
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
|
||||
|
||||
# $MirBSD: read.t,v 1.2 2004/05/24 19:56:25 tg Stab $
|
||||
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
|
||||
#
|
||||
# To test:
|
||||
# POSIX:
|
||||
@ -55,4 +55,3 @@ stdin:
|
||||
expected-stdout:
|
||||
[abc]
|
||||
---
|
||||
|
||||
|
@ -1,8 +1,7 @@
|
||||
# $OpenBSD: regress.t,v 1.12 2003/11/08 19:17:27 jmc Exp $
|
||||
|
||||
# $MirBSD: regress.t,v 1.2 2004/05/24 19:56:25 tg Stab $
|
||||
# $OpenBSD: regress.t,v 1.12 2003/11/08 19:17:27 jmc Exp $
|
||||
#
|
||||
# The first 39 of these tests are from the old Bugs script.
|
||||
#
|
||||
|
||||
name: regression-1
|
||||
description:
|
||||
@ -1090,4 +1089,3 @@ expected-stdout:
|
||||
nt OK
|
||||
ot OK
|
||||
---
|
||||
|
||||
|
@ -7,4 +7,3 @@ expected-exit: e != 0
|
||||
expected-stderr-pattern:
|
||||
/syntax error/
|
||||
---
|
||||
|
||||
|
9
tests/th
9
tests/th
@ -1,7 +1,6 @@
|
||||
#!/usr/bin/perl
|
||||
# $OpenBSD: th,v 1.10 2003/09/01 05:16:46 fgsch Exp $
|
||||
|
||||
|
||||
# $MirBSD: th,v 1.2 2004/05/24 19:56:25 tg Stab $
|
||||
# $OpenBSD: th,v 1.10 2003/09/01 05:16:46 fgsch Exp $
|
||||
#
|
||||
# Test harness for pdksh tests.
|
||||
#
|
||||
@ -91,7 +90,7 @@
|
||||
# time-limit Time limit - the program is sent a
|
||||
# SIGKILL N seconds. Default is no
|
||||
# limit.
|
||||
# expected-fail `yes' if the test is expected to fail.
|
||||
# expected-fail 'yes' if the test is expected to fail.
|
||||
# expected-exit expected exit code. Can be a number,
|
||||
# or a C expression using the variables
|
||||
# e, s and w (exit code, termination
|
||||
@ -105,7 +104,7 @@
|
||||
# expected-stderr-pattern m A perl pattern which matches the
|
||||
# expected standard error.
|
||||
# category m Specify a comma separated list of
|
||||
# `categories' of program that the test
|
||||
# 'categories' of program that the test
|
||||
# is to be run for. A category can be
|
||||
# negated by prefixing the name with a !.
|
||||
# The idea is that some tests in a
|
||||
|
@ -1,7 +1,6 @@
|
||||
#!/bin/sh
|
||||
# $OpenBSD: th.sh,v 1.4 2001/01/28 23:04:57 niklas Exp $
|
||||
|
||||
|
||||
# $MirBSD: th.sh,v 1.2 2004/05/24 19:56:25 tg Stab $
|
||||
# $OpenBSD: th.sh,v 1.4 2001/01/28 23:04:57 niklas Exp $
|
||||
#
|
||||
# Simple script to find perl and run it
|
||||
#
|
||||
|
@ -127,7 +127,7 @@ expected-stdout:
|
||||
name: xxx-param-subst-qmark-1
|
||||
description:
|
||||
Check suppresion of error message with null string. According to
|
||||
POSIX, it shouldn't print the error as `word' isn't ommitted.
|
||||
POSIX, it shouldn't print the error as 'word' isn't ommitted.
|
||||
stdin:
|
||||
unset foo
|
||||
x=
|
||||
@ -160,4 +160,3 @@ expected-stdout:
|
||||
expected-stderr: !
|
||||
XX
|
||||
---
|
||||
|
||||
|
3
trap.c
3
trap.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: trap.c,v 1.13 2003/02/28 09:45:09 jmc Exp $ */
|
||||
/* $MirBSD: trap.c,v 1.2 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: trap.c,v 1.13 2003/02/28 09:45:09 jmc Exp $ */
|
||||
|
||||
/*
|
||||
* signal handling
|
||||
|
3
tree.c
3
tree.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: tree.c,v 1.10 2002/02/27 19:37:09 dhartmei Exp $ */
|
||||
/* $MirBSD: tree.c,v 1.2 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: tree.c,v 1.10 2002/02/27 19:37:09 dhartmei Exp $ */
|
||||
|
||||
/*
|
||||
* command tree climbing
|
||||
|
6
tree.h
6
tree.h
@ -1,11 +1,11 @@
|
||||
/* $OpenBSD: tree.h,v 1.8 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $MirBSD: tree.h,v 1.2 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: tree.h,v 1.8 2003/10/22 07:40:38 jmc Exp $ */
|
||||
/* $From: tree.h,v 1.3 1994/05/31 13:34:34 michael Exp $ */
|
||||
|
||||
/*
|
||||
* command trees for compile/execute
|
||||
*/
|
||||
|
||||
/* $From: tree.h,v 1.3 1994/05/31 13:34:34 michael Exp $ */
|
||||
|
||||
#define NOBLOCK ((struct op *)NULL)
|
||||
#define NOWORD ((char *)NULL)
|
||||
#define NOWORDS ((char **)NULL)
|
||||
|
3
tty.c
3
tty.c
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: tty.c,v 1.2 1996/10/01 02:05:51 downsj Exp $ */
|
||||
/* $MirBSD: tty.c,v 1.2 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: tty.c,v 1.2 1996/10/01 02:05:51 downsj Exp $ */
|
||||
|
||||
#include "sh.h"
|
||||
#include "ksh_stat.h"
|
||||
|
3
tty.h
3
tty.h
@ -1,4 +1,5 @@
|
||||
/* $OpenBSD: tty.h,v 1.2 1996/11/21 07:59:36 downsj Exp $ */
|
||||
/* $MirBSD: tty.h,v 1.2 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: tty.h,v 1.2 1996/11/21 07:59:36 downsj Exp $ */
|
||||
|
||||
/*
|
||||
tty.h -- centralized definitions for a variety of terminal interfaces
|
||||
|
2
var.c
2
var.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: var.c,v 1.6 2004/05/24 19:06:55 tg Exp $ */
|
||||
/* $MirBSD: var.c,v 1.7 2004/05/24 19:56:20 tg Stab $ */
|
||||
/* $OpenBSD: var.c,v 1.17 2004/05/08 19:42:35 deraadt Exp $ */
|
||||
|
||||
#include "sh.h"
|
||||
|
3
vi.c
3
vi.c
@ -1,4 +1,4 @@
|
||||
/* $MirBSD: vi.c,v 1.4 2004/05/23 12:47:01 tg Exp $ */
|
||||
/* $MirBSD: vi.c,v 1.5 2004/05/24 19:56:21 tg Stab $ */
|
||||
/* $OpenBSD: vi.c,v 1.13 2004/05/10 16:28:47 pvalchev Exp $ */
|
||||
|
||||
/*
|
||||
@ -7,6 +7,7 @@
|
||||
* bludgeoned to fit pdksh by Larry Bouzane, Jeff Sparkes & Eric Gisin
|
||||
*
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
#ifdef VI
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user