Bugs item #1651741, was opened at 2007-02-04 15:52 Message generated for change (Comment added) made by nicove You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=379133&aid=1651741&group_id=23629
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: molvisions (molvisions) Assigned to: Nicolas (nicove) Summary: vecmath conflict on OS X Initial Comment: hi, some time ago, the email list carried a discussion about a problem between Jmol and the existing vecmath.jar on OS X. I continue to have trouble compiling Jmol on my OS X machine - I must remove vecmath.jar, compile Jmol, and then replace vecmath.jar. this has become very frustrating. can someone please explain why this is happening, and what steps can be taken to resolve the issue? if it is a problem with the OS, I will be happy to submit a bug to Apple, as long as someone can provide a concise technical description of the actual problem. this is Apple's Month of Bugs so we may have an increased chance of having it fixed. thanks, tim ---------------------------------------------------------------------- >Comment By: Nicolas (nicove) Date: 2007-02-04 16:35 Message: Logged In: YES user_id=1096197 Originator: NO Hi Miguel, we just cross-posted on this :) I diagnosed this problem a few months ago, and it was also on OS X. For me, this is really a compatibility problem between several versions of vecmath specifications. Nico ---------------------------------------------------------------------- Comment By: Nicolas (nicove) Date: 2007-02-04 16:29 Message: Logged In: YES user_id=1096197 Originator: NO The problem is due to the vecmath library itself. The class org.jmol.adapter.smarter.Atom extends Point3f from vecmath and defines a cloneAtom() method to clone itself. In the first releases of vecmath (the one that is bundled with Jmol is 1.2 compatible), Point3f didn't implement the Cloneable interface and so the clone() method was the one defined in Object itself: "Object clone() throws CloneNotSupportedException". Notice the "throws CloneNotSupportedException". In this situation, our cloneAtom() method must either explicitely catch this exception or explicitely throw it. In the following releases of vecmath, Point3f did implement Cloneable, but the clone method() was defined as "Object clone()". Notice the missing "throws CloneNotSupportedException". In this situation, our cloneAtom() method mustn't catch this exception or throw it (exactly the opposite of the first releases). A working solution (but not very clean) should be to modify our cloneAtom() method to catch an exception higher in the class hierarchy (Exception or Throwable) instead of CloneNotSupportedException. Could you try this patch on your own system ? Nico ---------------------------------------------------------------------- Comment By: Miguel (migueljmol) Date: 2007-02-04 16:24 Message: Logged In: YES user_id=1050060 Originator: NO Tim, I have been out of this for some time ... up until now I was not aware of this problem ... but I'll tell you what I know and will speculate as to the cause. The vecmath package that is used by Jmol is implementing an interface that was defined by Sun with Java3D. That is, it is an open source implementation of the API. It reuses exactly the same package/class names. In general I think that this was a pretty good thing. It provided a well-defined nearly 'standard' API to vector math that was needed for 3D calculations. The documentation provided by Sun was/is pretty good. Over the past few years I have lobbied Sun to include the vector math packages in the standard Java distributions. As of about two years ago I received responses from someone at Sun saying that it was "on their list of things to do". But, in reality, no one knows how long that list was/is ... and they probably have very limited resources. Now, with respect to Apple and Java on OSX ... Apple has a unique agreement with Sun and they build their own Java distributions. I strongly suspect that Apple is including the vecmath packages in their distribution and that is the source of your problems. That is, there is a class library conflict of some type going on. Note that this was not a problem in the old days. A few (4) years ago there were several people (including Egon perhaps) who were running Java3D on the same box as Jmol without having any class library conflict. But the rules may have changed because *if* java3d.vecmath is now part of a standard class-library distribution then the class library security may be tighter ... in order to prevent someone from overriding a standard class library with a rogue imposter implementation. I suspect that one of a few of things is happening: 1) Apple has incorporated the vecmath package into their core Java libraries. They may have done this before it has made it into the Sun distributions. This may be because Apple is being responsive to the (3D oriented) needs of its customer base. Overall, I this would be a good thing ... it is what I asked Sun to do for years. 2) Apple may have tried to incorporate all of Java3D, including the vecmath stuff, into its core distribution. Overall, this would be a bad thing ... because Java 3D is dead. 3) I suppose that it is possible that vecmath is now included in the Sun 1.6 distributions. If that were the case then either: a) no other Jmol developers have upgraded to Java 1.6, so they are not seeing the problem b) there is no class library conflict on other platforms. Tim, you said: > I must remove vecmath.jar, compile Jmol, and then replace vecmath.jar. Q: Please confirm that we are talking about the application, not the applet. Q: Are you sure that you must 'replace' vecmath.jar? Q: What happens if you don't replace it? (I think it should work, pulling java3d.vecmath packages from the 'standard class libraries') Q: Try to capture a sample of the compiler error output when you do not remove our 'imposter' vecmath.jar. Miguel ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=379133&aid=1651741&group_id=23629 ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Jmol-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jmol-developers
