ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yang Zhang <yanghates...@gmail.com>
Subject Setting environment variables
Date Fri, 01 Aug 2008 20:08:52 GMT
Hi, I know that I can set environment variables for a subprocess by
using <env> inside an <exec>, but if I have a bunch of targets that all
do <exec>s, and I'd like them all to have this same environment set up,
how may I accomplish this duplicating a bunch of <env>s everywhere?

My goal is to set things up for building/running a native Linux 
executable that links with the JVM and a JNI library (to make gdb-ing 
the JNI library easier), by setting:

- LD_LIBRARY_PATH and LIBRARY_PATH to "${java.library.path}"
- JAVA_HOME to "${java.home}/.."
- CPATH to "${java.home}/../include:${java.home}/../include/linux"

If there's a better way to do what I'm trying to do, I'm all ears. 
Thanks in advance for any answers!
-- 
Yang Zhang
http://www.mit.edu/~y_z/

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message