ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Kuß <>
Subject Setting environment for forked java process on Win XP
Date Tue, 03 Dec 2002 11:08:23 GMT

I try to start a java task from ant 1.5.1 on Windows XP.

<java classname="" fork="yes">

The Problem is that I need a dll (DLL1) to call some JNI stuff.
This dll needs another dll (DLL2) not located in the PATH environment.
I have tried to modify the PATH for my java task with

<env key="PATH" path="${java.library.path}:${rundir}/Client/lib" />

The DLL2 is located in the ${rundir}/Client/lib directory.
I'm also setting

<sysproperty key="java.library.path"

If I start the java process the DLL2 will not be found in the PATH
environment. DLL1 is found in the java.library.path. It seems
that the PATH environment is not properly set. ant -v shows
that the PATH environment is set.

I have also tried to use "newenvironment=true" in my java task. That
leaves my program fully useless to network calls. I can't find my
host anymore (gethostbyname() failed:

Can anyone help me out of this?
How do I set the PATH environment properly and/or how do I get
a working environment with newenvironment=true?

Thanx in advance,

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message