#!/bin/sh # Run Medley # # Syntax: run-medley [options] [sysout name] # Options: # -nogreet # -greet # current limit 65536*32 bits # -g[eometry] x # -sc[reensize] x # -d[isplay] # -vmem # Environment variables set # Directory variables are accessible from Lisp via UNIX-GETENV # LDESRCESYSOUT SYSOUT full-file name you want to run # LDEDESTSYSOUT name for destination of SAVEVM/LOGOUT # MEDLEYDIR used by init file to set other path variables if [ -z "$MEDLEYDIR" ] ; then export MEDLEYDIR="`pwd`"; fi if [ ! -d $MEDLEYDIR/loadups ] ; then echo MEDLEYDIR not found: "$MEDLEYDIR" exit 1 fi ## should allow for local install? if [ -z "$MAIKODIR" ] ; then export MAIKODIR="$MEDLEYDIR/../maiko" if [ ! -d "$MAIKODIR"/bin ] ; then # should have more precise test echo "MAIKODIR not found: $MAIKODIR" exit 1 fi fi prog="lde" geometry="-g 1440x900" screensize="-sc 1440x900" export LDEDESTSYSOUT="~/lisp.virtualmem" export LDEINIT="$MEDLEYDIR/greetfiles/SIMPLE-INIT" export LDEKBDTYPE=x while [ "$#" -ne 0 ]; do case "$1" in "-nogreet") export LDEINIT="" ;; "-greet") export LDEINIT="$2" shift ;; "-geometry" | "-g") geometry="-g $2" shift ;; "-screensize" | "-sc") screensize="-sc $2" shift ;; "-display" | "-d") export DISPLAY="$2" shift ;; "-vmem") LDEDESTSYSOUT="$2" shift ;; "-full") export LDESRCESYSOUT="$MEDLEYDIR/loadups/xfull35.sysout" ;; "-lisp") export LDESRCESYSOUT="$MEDLEYDIR/loadups/xlisp.sysout" ;; "-*") echo unrecognized option "$1" exit 1 ;; *) export LDESRCESYSOUT="$1" ;; esac shift done if [ -z "$LDESRCESYSOUT" ] ; then if [ -f "$LDEDESTSYSOUT" ] ; then export LDESRCESYSOUT="$LDEDESTSYSOUT" else export LDESRCESYSOUT="$MEDLEYDIR/loadups/xfull35.sysout" ; fi fi export INMEDLEY=1 oldpath="$PATH" export PATH=.:"$PATH" cd "$MAIKODIR"/bin export PATH=$MAIKODIR/`osversion`.`machinetype`:"$oldpath" cd $old_wd echo "sysout is $LDESRCESYSOUT" echo "running `which $prog` $geometry $screensize" echo "start $LDEINIT" $prog $geometry $screensize -t "Medley Interlisp" "$LDESRCESYSOUT"