npwj - run Java command given UNIX® pathnames
npwj java_command [ parameters ]
The npwj (native path wrapper for Java ) converts UNIX format
pathnames to Windows® format pathnames and calls the specified Java command
with the converted pathnames. It is intended for use on a Windows host, and
provides a convenient way to call Windows based Java commands from an
environment using UNIX pathnames such as UWIN.
nmake calls npwj automatically when appropriate; no
special action or manual setup is required when using nmake's
built-in rules. This manual page describes npwj for standalone
use outside of nmake.
npwj does the following:
A parameter may contain a single pathname or a set of pathnames separated
by ':'. A set of pathnames is first converted to an pathname array. For each
UNIX absolute pathname, npwj calls the appropriate function
(uwin_path() in the case of UWIN) to convert the UNIX pathname
to the corresponding Windows pathname. When a set of paths is re-constructed,
';' replaces ':' as the path separator character. Since ';' is a special
character in the UNIX environment, it is re-written as "\;". Another special
character '$', which is often used in Java class filenames, is also
re-written as "\$".
npwj can be used for all Java commands including
java, javac, jdeps and
jar.
Here is a simple example using ksh on a UWIN platform:
$ npwj javac ~/tmp/a.java
Since javac is a Windows-based command, attempting to directly pass a UNIX style pathname would have resulted in an error:
$ javac ~/tmp/a.java error: cannot read: /home/na01/gms/tmp/a.java 1 error
A ksh alias may be used to make javac invocation
more convenient for interactive use:
$ alias jc='npwj javac' $ jc ~/tmp/a.java
Copyright 2004 Alcatel-Lucent. All Rights Reserved.
See http://www.bell-labs.com/project/nmake/licenseagreement.html
for terms of use.
npwj - run Java command with UNIX® pathnames
@(#)npwjman.html 6.1.2.1 03/31/04