Alex Rivera | Logout

How to determine build architecture (32bit / 64bit) with ant?

Asked 2008-10-20T16:09:57.367
18

We have inherited an ant build file but now need to deploy to both 32bit and 64bit systems.

The non-Java bits are done with GNUMakefiles where we just call "uname" to get the info. Is there a similar or even easier way to mimic this with ant?

Edit
Report

2 Answers

1

BTW, the os.arch (arch property of the os tag) I got for 64-bit Linux was amd64.

answered 2011-02-17T01:10:18.690
0

Assuming you are using ANT for building Java Application, Why would you need to know if it is a 32 bit arch or 64-bit? We can always pass parameters to ant tasks. A cleaner way would be to programmaticaly emit the system properties file used by Ant before calling the actual build. There is this interesting post http://forums.sun.com/thread.jspa?threadID=5306174.

answered 2008-10-20T16:26:39.970

Your Answer