Wanted: Help translating classpath from CMD.EXE to bash

Igor Pechtchanski pechtcha@cs.nyu.edu
Mon Oct 31 18:41:00 GMT 2005


On Mon, 31 Oct 2005, Siegfried Heintze wrote:

> Can someone help me translate this to bash? It works with CMD.EXE. java
> and javac are programs for sun that are not cygwin based so I believe
> they want windows style file specifications and not cygwin/bash/unix
> style file specifications.
>
> Here is the CMD.EXE script:
>
> SET CLASSPATH=.;c:\dev\xalan\xalan-j_2_7_0\samples\xsltcservlet.jar;c:\dev\xalan\xalan-j_2_7_0\samples\xsltcejb.jar;c:\dev\xalan\xalan-j_2_7_0\samples\xsltcbrazil.jar;c:\dev\xalan\xalan-j_2_7_0\samples\xsltcapplet.jar;c:\dev\xalan\xalan-j_2_7_0\samples\xalansamples.jar;c:\dev\xalan\xalan-j_2_7_0\serializer.jar;c:\dev\xalan\xalan-j_2_7_0\xalan.jar;c:\dev\xalan\xalan-j_2_7_0\xercesImpl.jar;c:\dev\xalan\xalan-j_2_7_0\xml-apis.jar;c:\dev\xalan\xalan-j_2_7_0\xsltc.jar
> javac -g ApplyXPathDOM.java
> java ApplyXPathDOM foo.xml /doc/name[1]/@last

As someone mentioned, you can use "cygpath -p" to convert a POSIX-style
path into a Win32-style one.

Alternatively, you can try using my java wrapper scripts that will do the
translation automatically for you (the scripts can be found at
<http://cygwin.com/cgi-bin/cvsweb.cgi/wrappers/java/?cvsroot=cygwin-apps>;
you'll need to edit the scripts to point them to your Java installation
directory).

<SHAMELESS_PLUG>
Or, since you're doing XML processing in Java, you might find XJ
(<http://www.research.ibm.com/xj/>) useful.  There's a prototype on IBM
alphaWorks (a free download), and it works under Cygwin.
</SHAMELESS_PLUG>

HTH,
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. /DA

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list