ie.sh revision 3f54fd611f536639ec30dd53c48e5ec1897cc7d9
########################################################################
# #
# This software is part of the ast package #
# Copyright (c) 1984-2011 AT&T Intellectual Property #
# and is licensed under the #
# Eclipse Public License, Version 1.0 #
# by AT&T Intellectual Property #
# #
# A copy of the License is available at #
# (with md5 checksum b35adb5213ca9657e911e9befb180842) #
# #
# Information and Software Systems Research #
# AT&T Research #
# Florham Park NJ #
# #
# David Korn <dgk@research.att.com> #
# Pat Sullivan #
# #
########################################################################
command=ie
USAGE=$'
[-?
@(#)$Id: ie (AT&T Labs Research) 1998-11-30 $
]
[+NAME?ie - execute a command with ksh-style input editing]
[+DESCRIPTION?\bie\b executes a dynamically linked \acommand\a
with ksh-style input editing on the standard input terminal. The
default history file name is \b$HOME/.\abase\a, where \abase\a is
the base name of \acommand\a with leading [\bnox\b]] deleted. All processes
executed by \acommand\a will have input editing enabled on the same
history file.]
[h:history?Sets the history file name to \apath\a.]:[path]
[n!:exec?Execute \acommand\a. \b--noexec\b shows how \acommand\a would be
invoked but does not execute.]
[+DETAILS?Input editing is implemented by intercepting the \bread\b(2) system call
on file descriptor 0 with a dll that is preloaded at process startup
before \amain\a() is called. The interception mechanism may involve the
environment on some systems; in those cases commands like \benv\b(1)
that clear the enviroment before execution may defeat the \bie\b
intercept.]
[+?Also intercepted are the \b_\b and \b_libc_\b name permutations of the
\bread\b call, as well as any 32-bit and 64-bit versions. \bie\b
ignores calls not present in a particular host system. In addition,
\bie\b only works on dynamically linked executables that have neither
set-uid nor set-gid permissions. It may not have the intended effect
on programs written in a language or linked with a language runtime
that hides or mangles system call library symbols, or that
directly emit system call instruction sequences rather than using
the corresponding library functions, or that dynamically link
libraries outside of the scope of the \bie\b intercepts.]
[+?Multi-process client-server applications may misbehave if the \bie\b
environment between the related processes is not kept in sync.]
command [ arg ... ]
[+ENVIRONMENT?\bie\b is implemented by two components: the \bie\b script,
located on \b$PATH\b and the \bie\b dll (shared library), located
\b$PATH\b, depending on local compilation system conventions. Systems
multiple versions of the \bie\b dll. In all cases the \bie\b script
handles the dll search.]
[+SEE ALSO?\b3d\b(1), \bsh\b(1), \btrace\b(1), \bwarp\b(1), \bread\b(2)]
'
;;
*) ARGV0=""
USAGE='h:[history]nt command [ arg ... ]'
;;
esac
n) show=print ;;
*) exit 2 ;;
esac
done
shift $OPTIND-1
case $# in
esac
if test -x "$1"
then command=$1
else command=$(whence $1)
fi
shift
esac
;;
esac
'}
IFS=:
if test -f $dll
then break
fi
done
case $_RLDN32_LIST in
*) env="$env:$_RLDN32_LIST" ;;
esac
;;
case $_RLD64_LIST in
*) env="$env:$_RLD64_LIST" ;;
esac
case $_RLDN32_LIST in
*) env="$env:$_RLDN32_LIST" ;;
esac
case $_RLD_LIST in
*) env="$env:$_RLD_LIST" ;;
esac
case $_RLD64_LIST in
*) env="$env:$_RLD64_LIST" ;;
esac
case $_RLDN32_LIST in
*) env="$env:$_RLDN32_LIST" ;;
esac
case $_RLD_LIST in
*) env="$env:$_RLD_LIST" ;;
esac
case $_RLD64_LIST in
*) env="$env:$_RLD64_LIST" ;;
esac
case $_RLDN32_LIST in
*) env="$env:$_RLDN32_LIST" ;;
esac
case $_RLD_LIST in
*) env="$env:$_RLD_LIST" ;;
esac
;;
case $_RLD_LIST in
*) env="$env:$_RLD_LIST" ;;
esac
esac
fi
;;
esac
: engage
esac