Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4663688

javac should support JAR dependencies

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P2 P2
    • None
    • 1.4.0
    • tools
    • None
    • x86
    • windows_2000


      In working with the Web Services Developer Pack I was very
      frustrated over the number of JAR files and the non-obvious
      relationships between them. To use JAX-RPC you have to pull in
      a whole bunch of non-obvious JARs (like mail.jar) because
      some implementation aspect of jaxrpc-ri.jar depends on them.

      Well, I thought naively, fortunately this is all fixable.
      This is the problem we intended to solve with JAR dependencies.
      One JAR can use a "Class-Path:" entry in its manifest to
      specify what other JARs it depends on. So I can just reference
      a high-level JAR (such as jaxrpc.jar) and it can pull in the
      implementation JARs behind the scenes. Just like DLLs.

      The JRE implements JAR dependencies correctly. But javac
      doesn't. It seems to completely ignore the "Class-Path:"
      entries in JAR files.

      I was *very* surprised by this. This is a pretty serious
      ease-of-development problem for large projects with large
      sets of class libraries. It shouldn't be necessary for
      developers to have to manually track all implementation
      dependencies for all JARs they use.

      This may be too late for Hopper. But let's try and get it
      fixed for Mantis.

      ###@###.### 2002-04-05

            gafter Neal Gafter (Inactive)
            ghamiltosunw Graham Hamilton (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: