Mac OS Help

Discussions about Java virtual machine, installation, and running

Moderator: Moderators

Mac OS Help

Postby Warren Burton » Mon Apr 23, 2001 4:43 am

I trying to get MD4.1 running on os X with this script as supplied by magic
draw but modified

#!/bin/sh

# Specify the MD_HOME for this script. MD_HOME should refer to the
# home location where MagicDraw files is installed.
MD_HOME=/applications/magicdraw


# Specify the JAVA_HOME for this script. JAVA_HOME should refer to the
# home location where your system's Java Development Kit is installed
# For instance, the supplied example assumes the JDK is installed at
# /usr/local/java
if [ -z "$JAVA_HOME" ]; then
JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.3
fi

if [ -x $JAVA_HOME/bin/java ]; then
$JAVA_HOME/jre/bin/java -Xmx200M -Dinstall.root=$MD_HOME -cp
$MD_HOME/lib/md.jar md.Main -D$MD_HOME $*
else
echo "ERROR!"
echo "Java executable not found in" $JAVA_HOME/bin/java
echo "Please set JAVA_HOME environment variable, or specify it in this
script" $0
fi

but when i try to run it out of the terminal (everyone has
read-write-execute permissions) i get the message no command found.
can anyone offer some tips as to how to get this to run.

thanks
warren burton

Warren Burton
 
Posts Rating:

Re: Mac OS Help

Postby Egidijus Vaisnora » Mon Apr 23, 2001 8:55 am

Hello,

Try to modify your run.sh by throwing "if" sentences:

MD_HOME=/applications/magicdraw
JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.3
// java launcher is in Commands/java
$JAVA_HOME/Commands/java -Xmx200M -Dinstall.root=$MD_HOME -cp
$MD_HOME/lib/md.jar md.Main

And running run.sh specify full path to it.
This should help.

Best regards,
--
Egidijus Vaisnora
Programmer
No Magic
Gedimino g. 47- 408, 3000 Kaunas
P.O. box 2166, LT- 3000, Kaunas
Phone: +370 7 324032 Fax: +370 7 320670
e-mail: Egidijus.Vaisnora
WWW: http://www.nomagic.com
--
OO software design can be an appealing challenge if you have
the best UML modeling tool: http://www.magicdraw.com


Warren Burton wrote:

> I trying to get MD4.1 running on os X with this script as supplied by magic
> draw but modified
>
> #!/bin/sh
>
> # Specify the MD_HOME for this script. MD_HOME should refer to the
> # home location where MagicDraw files is installed.
> MD_HOME=/applications/magicdraw
>
> # Specify the JAVA_HOME for this script. JAVA_HOME should refer to the
> # home location where your system's Java Development Kit is installed
> # For instance, the supplied example assumes the JDK is installed at
> # /usr/local/java
> if [ -z "$JAVA_HOME" ]; then
> JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.3
> fi
>
> if [ -x $JAVA_HOME/bin/java ]; then
> $JAVA_HOME/jre/bin/java -Xmx200M -Dinstall.root=$MD_HOME -cp
> $MD_HOME/lib/md.jar md.Main -D$MD_HOME $*
> else
> echo "ERROR!"
> echo "Java executable not found in" $JAVA_HOME/bin/java
> echo "Please set JAVA_HOME environment variable, or specify it in this
> script" $0
> fi
>
> but when i try to run it out of the terminal (everyone has
> read-write-execute permissions) i get the message no command found.
> can anyone offer some tips as to how to get this to run.
>
> thanks
> warren burton

Egidijus Vaisnora
 
Posts Rating:

Re: Mac OS Help

Postby Caitlin Bestler » Mon Apr 23, 2001 9:22 am



Warren Burton wrote:

> I trying to get MD4.1 running on os X with this script as supplied by magic
> draw but modified
>
> #!/bin/sh
>
> <<snip>>
>
> but when i try to run it out of the terminal (everyone has
> read-write-execute permissions) i get the message no command found.
> can anyone offer some tips as to how to get this to run.
>
> thanks
> warren burton

Is the *file* marked executable? You need to mark the file as executable
or explicitly invoke a shell, as in "sh ./run.sh"

Everything worked fine under the beta, which used JVM 1.2. 10.0 and
10.0.1 use JVM 1.3 which spins off into a CPU consumption frenzy when
you run MagicDraw. I presume setting JAVA_HOME back to 1.2 will
fix this, but I haven't had time to confirm this behavior since I only run
magicdraw under MacOS X on weekends.


Caitlin Bestler
 
Posts Rating:

Re: Mac OS Help

Postby Warren Burton » Tue Apr 24, 2001 11:10 am

Oh strangeness

I threw it all away and unzipped the original download while in os x.

With the usual mods to the script straight off it worked except for bringing
OSX to its knees (hard reset needed to escape from magic draw on an iBook).
Ill have to try that suggestion about using the 1.2 VM

I had unzipped the previous version while in os 9 and I guess it throws the
permissions on text files which pop up as simple text files and even if you
strip the type/creator it don¹t work.

Thanks all


Warren Burton
 
Posts Rating:


Return to Installing and running

Who is online

Users browsing this forum: No registered users and 1 guest