Some Fink packages exist solely for backward compatibility. For instance, there is a db3 as well as a db4 package because certain programs depend on version 3, while others depend on version 4. Normally, this isn't such a big deal because the older package simply embeds its version number in the files it installs (e.g., libdb-3.3.dylib), allowing dependent packages to explicitly reference the version they need.

Unfortunately, this doesn't work for Java. Even if you put two JARs with different names on the CLASSPATH, and a package tries to load a class that exists in both JARs, then Java will load whatever it happens to see first. There is no way packages can explicitly request a version number for a JAR.

This is a problem for me because I'm trying to write a Fink package description for a Java library called Saxon. Some packages require Saxon 8.1.1, since that was the last version to fully support Java 1.4, while others require the newer features of Saxon 8.2 or higher. Therefore, Fink must be able to supply either of the two versions, depending on what the user needs, but the two packages cannot both be installed at the same time because of the lack of versioning in Java.

One way of solving this is to provide two packages, saxon and saxon811. Each package can reference the other in its Conflicts field. However, this means that packages depending on *any* version of Saxon must specify "Depends: saxon | saxon811". Otherwise (if they only specify "Depends: saxon"), installing a package requiring Saxon 8.1.1 would force those packages to be removed.

Another way of solving this is to have packages that require Saxon 8.1.1 to specify "Depends: saxon (= 8.1.1)". However, this brings about other problems. Namely, how can Fink's repository hold package descriptions for both Saxon 8.1.1 and Saxon 8.whatever if they both have the same name ("saxon")?

Any suggestions on what to do? Thanks,

Trevor

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to