From: Arne Vajhøj on 17 Apr 2010 19:12 On 17-04-2010 19:02, Bill Cunningham wrote: > Arne Vajh�j wrote: >> Does that directory contain the two exe's? > > Yes. Then if the directory is in PATH then the two commands should work. > So classpath isn't set anymore to the tools.jar? Correct. CLASSPATH is a bad idea from the mid 1990's. Arne
From: Bill Cunningham on 18 Apr 2010 16:55 "Arne Vajh�j" <arne(a)vajhoej.dk> wrote in message news:4bca4053$0$272$14726298(a)news.sunsite.dk... > Correct. > > CLASSPATH is a bad idea from the mid 1990's. Ok what about the ant variables? I've got ANT_HOMEand JAVA_HOME and have no idea how to set them. Bill
From: Lew on 18 Apr 2010 17:37 Bill Cunningham wrote: > Ok what about the ant variables? I've got ANT_HOMEand JAVA_HOME and have > no idea how to set them. JAVA_HOME, as said upthread, is used by more than Ant. Peter Duniho mentioned: > Note: in Windows 7 (and if I recall correctly, Vista…but I'm not 100% sure > about that), user-specific environment variables are set in the User Accounts > control panel. > > The "Advanced…/Environment" dialog has a "User variables…" section, but it's > unreliable for non-admin accounts, because you can only even get to the dialog > using admin credentials (and so it always is setting environment variables for > some admin account). > > Of course, if one is setting system-wide environment variables, this is not a > concern. For my own Java use, I set the variables only for the user account I > am using for the dev work (which is never an admin account), but I suppose in > other situations system-wide settings are called for. You set environment variables in the way specified by the operating system, not Java. Martin Gregorie wrote: > Its basic operating system stuff. See your XP documentation or use a > search engine for XP and search part or environment variable. Let's say you install the JDK into 'C:\java\jdk1.6.0_u20\', a.k.a. 'C:/java/jdk1.6.0_u20/' and Ant into 'C:/java/apache-ant-1.8.0/'. .. You'd set the environment variables JAVA_HOME='C:\java\jdk1.6.0_u20\' and ANT_HOME='C:\java\apache-ant-1.8.0\'. -- Lew
From: Martin Gregorie on 18 Apr 2010 17:56 On Sun, 18 Apr 2010 17:37:43 -0400, Lew wrote: > Let's say you install the JDK into 'C:\java\jdk1.6.0_u20\', a.k.a. > 'C:/java/jdk1.6.0_u20/' and Ant into 'C:/java/apache-ant-1.8.0/'. . > > You'd set the environment variables JAVA_HOME='C:\java\jdk1.6.0_u20\' > and ANT_HOME='C:\java\apache-ant-1.8.0\'. > And include C:/java/apache-ant-1.8.0/bin and C:/java/jdk1.6.0_u20/bin in the search path - that PATH for Linux. Dunno what it is for XP. Last but not least, if you're smart you'll put symbolic links in place, e.g. use one called C:/SDK that maps to C:/java/jdk1.6.0_u20 and do the same for Ant. Use the symlinks in environmental variables rather than the actual paths. The advantage is that, when you upgrade Java or Ant you simply swap the symbolic link to point to the new package without having to hunt down and change the environment variables. Disclaimer: the symlink trick works for Linux. I assume it also works for XP - if not, why would MS bother implementing symlinks? -- martin@ | Martin Gregorie gregorie. | Essex, UK org |
From: Bill Cunningham on 18 Apr 2010 18:05
Lew wrote: : > You'd set the environment variables JAVA_HOME='C:\java\jdk1.6.0_u20\' > and ANT_HOME='C:\java\apache-ant-1.8.0\'. I have been leaving the ' out. Maybe that's my problem. I also include the \bin in there so that might be part of my problem. I have also been including the bin directory. Bill |