This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Re: jdk
- To: Noel L Yap <yap_noel at jpmorgan dot com>
- Subject: Re: jdk
- From: Daniel Steinmann <daniel dot steinmann at insonic dot com>
- Date: Fri, 17 Aug 2001 10:32:25 +0200
- Cc: cygwin at sourceware dot cygnus dot com
- References: <85256AAA.006DE0ED.00@nyc-ntgw-n01.ny.jpmorgan.com>
Noel L Yap wrote:
> Does anyone know of any jdk-1.2.2 executables (eg javac, java, ...) that
> recognize Cygwin mounts and symlinks?
There are probably none. My workaround is to invoke the program out
of a shell script (see below).
HTH,
Daniel.
----
#! /bin/sh
# Cygwin support.
case "`uname`" in
CYGWIN*) cygwin=true ;;
*) cygwin=false ;;
esac
.. snip ...
# For Cygwin, ensure paths are in UNIX format before doing anything
if $cygwin; then
[ -n "$CLASSPATH" ] &&
CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
... snip ...
fi
# Enhance CLASSPATH
CLASSPATH=$MYAPP/lib/foo.jar:$CLASSPATH
.. snip ...
# For Cygwin, switch paths to Windows format before running java
if $cygwin; then
[ -n "$CLASSPATH" ] &&
CLASSPATH=`cygpath --path --windows "$CLASSPATH"`
fi
java -classpath "$CLASSPATH" com.insonic.foo.bar "$@"
--
Daniel Steinmann, Insonic AG, Zuerich, Switzerland
daniel.steinmann@insonic.com, +41 1 317 88 99, fax: +41 1 317 88 90
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/