Skip to Content.
Sympa Menu

texmacs-users - Re: [TeXmacs] TeXmacs on OSX

Subject: mailing-list for TeXmacs Users

List archive

Re: [TeXmacs] TeXmacs on OSX


Chronological Thread 
  • From: Neuwirth Erich <address@hidden>
  • To: "Andrey G. Grozin" <address@hidden>
  • Cc: address@hidden
  • Subject: Re: [TeXmacs] TeXmacs on OSX
  • Date: Sat, 16 Mar 2013 19:32:23 +0100

I am not a Unix wizard, and there seems some wizardry involved here.
On the Mac, maxima resides in
/Applications/Maxima.App/Contents/Resources/maxima/bin

So the script maxima in /usr/local/bin which probably is the one called by
TeXmacs
looks like this:
-=-=-=-=-=-

#!/bin/sh
# Gets the real path of a link, following all links
myreadlink() { [ ! -h "$1" ] && echo "$1" || \
(local link="$(expr "$(command ls -ld -- "$1")" : '.*-> \(.*\)$')"; \
cd $(dirname $1); \
myreadlink "$link" | sed "s|^\([^/].*\)\$|$(dirname $1)/\1|"); }
# Returns the absolute path to a command, maybe in $PATH (which) or not.
# If not found, returns the same
whereis() { echo $1 | \
sed "s|^\([^/].*/.*\)|$(pwd)/\1|;s|^\([^/]*\)$|$(which -- $1)|;s|^$|$1|"; }
# Returns the realpath of a called command.
whereis_realpath() { local SCRIPT_PATH=$(whereis $1); \
myreadlink ${SCRIPT_PATH} | \
sed "s|^\([^/].*\)\$|$(dirname ${SCRIPT_PATH})/\1|"; }
realdir() { local SCRIPT_PATH=$(whereis_realpath $1); dirname $SCRIPT_PATH ; }


ROOT=`realdir $0`
MAXIMA_PREFIX=$ROOT/maxima/
export MAXIMA_PREFIX



PATH="$MAXIMA_PREFIX/bin:$PATH"
export PATH

exec "$MAXIMA_PREFIX/bin/maxima" "$1" "$2" "$3" "$3" "$4" "$5" "$6" "$7" "$8"
"$9"

-=-=-=-=-=-=-=


On Mar 16, 2013, at 6:56 PM, "Andrey G. Grozin" <address@hidden> wrote:

> On Sat, 16 Mar 2013, Neuwirth Erich wrote:
>> Mahler:bin neuwirth$
>> TEXMACS_PATH=/Applications/TeXmacs-1.0.7.18.app/Contents/Resources/share/TeXmacs
>> Mahler:bin neuwirth$ export TEXMACS_PATH
>> Mahler:bin neuwirth$ ./tm_maxima 5.28.0 sbcl
>> /Applications/Maxima.app/Contents/Resources/maxima//bin/maxima: lisp="-l"
>> not known. Use --list-avail to see possible options.
> This explains why maxima is not started from TeXmacs.
>
> The script tm_maxima is short and trivial. I suppose you can find out why
> it does not work in OSX. Run the main command in this script by hand:
>
> maxima -u 5.28.0 -l sbcl -p
> /Applications/TeXmacs-1.0.7.18.app/Contents/Resources/share/TeXmacs/plugins/maxima/lisp/texmacs-maxima.lisp
>
> Does this produce the output I gave in my previous email?
>
> Andrey




Archive powered by MHonArc 2.6.19.

Top of Page