You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by Dominique Devienne <DD...@lgc.com> on 2003/01/23 16:25:05 UTC

RE: cvs commit: jakarta-ant/src/main/org/apache/tools/ant/types P ath.java

Why not pick up automatically all jars in jre/lib, instead of hard-coding
them? This would make it impervious to future changes like that, and anyone
putting JARs there deserves the trouble they'll get. Thanks, --DD

-----Original Message-----
From: bodewig@apache.org [mailto:bodewig@apache.org] 
Sent: Thursday, January 23, 2003 9:11 AM
To: jakarta-ant-cvs@apache.org
Subject: cvs commit: jakarta-ant/src/main/org/apache/tools/ant/types
Path.java

bodewig     2003/01/23 07:11:12

  Modified:    src/main/org/apache/tools/ant/types Path.java
  Log:
  Java Runtime Libraries in JDK 1.4 is a bit more than just rt.jar.
  
  PR: 16242
  Submitted by:	Ville Skyttä <ville dot skytta at iki dot fi>
  
  Revision  Changes    Path
  1.44      +12 -2
jakarta-ant/src/main/org/apache/tools/ant/types/Path.java
  
  Index: Path.java
  ===================================================================
  RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/Path.java,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -u -r1.43 -r1.44
  --- Path.java	30 Dec 2002 06:10:14 -0000	1.43
  +++ Path.java	23 Jan 2003 15:11:12 -0000	1.44
  @@ -1,7 +1,7 @@
   /*
    * The Apache Software License, Version 1.1
    *
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
    * reserved.
    *
    * Redistribution and use in source and binary forms, with or without
  @@ -621,7 +621,17 @@
                                    + File.separator + "lib"
                                    + File.separator + "rt.jar"));
   
  -            // IBM's 1.4 has rt.jar split into 5 smaller jars.
  +            // Sun's 1.4 has JCE and JSSE in separate jars.
  +            String[] secJars = { "jce", "jsse" };
  +            for (int i = 0; i < secJars.length; i++) {
  +                addExisting(new Path(null,
  +                                     System.getProperty("java.home")
  +                                     + File.separator + "lib"
  +                                     + File.separator + secJars[i] +
".jar"));
  +            }
  +
  +            // IBM's 1.4 has rt.jar split into 4 smaller jars and a
combined
  +            // JCE/JSSE in security.jar.
               String[] ibmJars =
                   { "core", "graphics", "security", "server", "xml" };
               for (int i = 0; i < ibmJars.length; i++) {
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: cvs commit: jakarta-ant/src/main/org/apache/tools/ant/types P ath.java

Posted by Stefan Bodewig <bo...@apache.org>.
On Thu, 23 Jan 2003, Dominique Devienne <DD...@lgc.com> wrote:

> Why not pick up automatically all jars in jre/lib, instead of
> hard-coding them?

Because there are already jars that are not part of the runtime in it:

[bodewig@bodewig jakarta-ant-1.5]$ ls /usr/local/java/j2sdk1.4.1_01/jre/lib/*.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/charsets.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/javaplugin.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/jce.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/jsse.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/rt.jar
/usr/local/java/j2sdk1.4.1_01/jre/lib/sunrsasign.jar

and I don't think javaplugin.jar (for example) is on my bootclasspath
when starting Java - although I'm not sure.

> anyone putting JARs there deserves the trouble they'll get.

Sure - but they'll call us for support 8-)

Stefan

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>