[Debichem-devel] Will we manage to upgrade jmol
Andreas Tille
tille at debian.org
Thu Dec 8 14:59:15 UTC 2016
Hi Ximin,
On Thu, Dec 08, 2016 at 12:28:00PM +0000, Ximin Luo wrote:
> Ximin Luo:
> > Andreas Tille:
> >> compile:
> >> [mkdir] Created dir: /build/biojava3-live-3.1.0+dfsg/build/biojava3-structure/classes
> >> [javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure/build.xml:72: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
> >> [javac] Compiling 342 source files to /build/biojava3-live-3.1.0+dfsg/build/biojava3-structure/classes
> >> [javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure/src/main/java/org/biojava/bio/structure/asa/AsaCalculator.java:8: error: package javax.vecmath does not exist
> >> [javac] import javax.vecmath.Point3d;
> >> [javac] ^
> >
> > Hey Andreas,
> >
> > The error occurs because either you're missing a dependency on libvecmath-java, and/or because biojava3-live's build files can't find it on the system.
> >
> > If I remember correctly, this didn't happen for Jmol 12 because it bundles all the class files of its dependencies inside Jmol.jar. This isn't what we like to do for Debian, so I did things differently for Jmol 14 - add a Class-Path attribute inside the jar manifest, to point to the other jars instead.
> >
> > The solution for biojava3-live will depend on the build system; for ANT you can take a look at my patches for Jmol. Its online documentation is quite good, and is how I learnt to work with it many years ago.
> >
>
> To clarify, this is also an upstream bug. If org/biojava/bio/structure/asa/AsaCalculator.java (and the other files) directly use classes from vecmath, then their build process should be searching for and using vecmath.jar, rather than relying on Jmol to include it transitively.
>
> There seems to be some more documentation in debian/{README.Debian,build.xml} about this. Probably you just need to add an extra entry for vecmath.
Ahh, the latter hint was quite helpful. I did:
$ svn diff
Index: build.xml
===================================================================
--- build.xml (Revision 23266)
+++ build.xml (Arbeitskopie)
@@ -40,6 +40,7 @@
<include name="hamcrest.jar"/>
<include name="json-simple.jar"/>
<include name="log4j-1.2.jar"/>
+ <include name="vecmath.jar"/>
</fileset>
<fileset dir="${dist.dir}">
<include name="*.jar"/>
Index: changelog
===================================================================
--- changelog (Revision 23269)
+++ changelog (Arbeitskopie)
@@ -4,6 +4,7 @@
* Watch file only reports 3.x series
* cme fix dpkg-control
* debhelper 10
+ * Build-Depends: libvecmath-java, add vecmath.jar to debian/build.xml
-- Andreas Tille <tille at debian.org> Thu, 08 Dec 2016 11:34:58 +0100
Index: control
===================================================================
--- control (Revision 23269)
+++ control (Arbeitskopie)
@@ -22,7 +22,8 @@
icedtea-netx,
libhamcrest-java,
libjson-simple-java (>= 1.1.1),
- liblog4j1.2-java
+ liblog4j1.2-java,
+ libvecmath-java
Standards-Version: 3.9.8
Vcs-Browser: https://anonscm.debian.org/viewvc/debian-med/trunk/packages/biojava3/trunk/
Vcs-Svn: svn://anonscm.debian.org/debian-med/trunk/packages/biojava3/trunk/
Which solved the said error but the next problem now smells jmol related:
jar:
[jar] Building jar: /build/biojava3-live-3.1.0+dfsg/dist/biojava3-structure.jar
BUILD SUCCESSFUL
Total time: 5 seconds
cd biojava3-structure-gui && ant jar
Buildfile: /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/build.xml
compile:
[mkdir] Created dir: /build/biojava3-live-3.1.0+dfsg/build/biojava3-structure-gui/classes
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/build.xml:73: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
[javac] Compiling 109 source files to /build/biojava3-live-3.1.0+dfsg/build/biojava3-structure-gui/classes
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:34: error: package org.jmol.constant does not exist
[javac] import org.jmol.constant.EnumCallback;
[javac] ^
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:114: error: cannot find symbol
[javac] public void notifyCallback(EnumCallback arg0, Object[] arg1) {
[javac] ^
[javac] symbol: class EnumCallback
[javac] location: class MyJmolStatusListener
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:120: error: cannot find symbol
[javac] public boolean notifyEnabled(EnumCallback arg0) {
[javac] ^
[javac] symbol: class EnumCallback
[javac] location: class MyJmolStatusListener
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/StructureAlignmentJmol.java:445: error: cannot find symbol
[javac] String atomInfo = viewer.getAtomInfo(pos);
[javac] ^
[javac] symbol: method getAtomInfo(int)
[javac] location: variable viewer of type JmolViewer
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/StructureAlignmentJmol.java:478: error: cannot find symbol
[javac] String atomInfo = viewer.getAtomInfo(pos);
[javac] ^
[javac] symbol: method getAtomInfo(int)
[javac] location: variable viewer of type JmolViewer
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:36: error: MyJmolStatusListener is not abstract and does not override abstract method resizeInnerPanel(String) in JmolStatusListener
[javac] public class MyJmolStatusListener implements JmolStatusListener {
[javac] ^
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:139: error: resizeInnerPanel(String) in MyJmolStatusListener cannot implement resizeInnerPanel(String) in JmolStatusListener
[javac] public void resizeInnerPanel(String data) {
[javac] ^
[javac] return type void is not compatible with int[]
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:79: error: name clash: notifyCallback(int,Object[]) in MyJmolStatusListener overrides a method whose erasure is the same as another method, yet neither overrides the other
[javac] public void notifyCallback(int arg0, Object[] arg1) {
[javac] ^
[javac] first method: notifyCallback(CBK,Object[]) in JmolCallbackListener
[javac] second method: notifyCallback(EnumCallback,Object[]) in MyJmolStatusListener
[javac] /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/MyJmolStatusListener.java:84: error: name clash: notifyEnabled(int) in MyJmolStatusListener overrides a method whose erasure is the same as another method, yet neither overrides the other
[javac] public boolean notifyEnabled(int arg0) {
[javac] ^
[javac] first method: notifyEnabled(CBK) in JmolCallbackListener
[javac] second method: notifyEnabled(EnumCallback) in MyJmolStatusListener
[javac] Note: /build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/src/main/java/org/biojava/bio/structure/align/gui/jmol/JmolPanel.java uses or overrides a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 9 errors
BUILD FAILED
/build/biojava3-live-3.1.0+dfsg/biojava3-structure-gui/build.xml:73: Compile failed; see the compiler error output for details.
Total time: 2 seconds
BTW, if it helps I could migrate biojava3-live from SVN to Git if this
might be more convenient for interested people to directly change things
in VCS.
Kind regards
Andreas.
--
http://fam-tille.de
More information about the Debichem-devel
mailing list