Question about compiling .jar files?

Dan Bolser dmb@mrc-dunn.cam.ac.uk
Sat Nov 27 16:17:00 GMT 2004


On Sat, 27 Nov 2004, Andrew Haley wrote:

>Dan Bolser writes:
> > 
> > Hi I am new to gcc / gcj.
> > 
> > I am trying to compile jung-1.5.jar, which requires colt-1.2.0.zip. I
> > (think) I can compile colt-1.2.0.zip without a problem, but I can't seem
> > to satisfy jung-1.5.jar to the existence of colt-1.2.0.zip. 
> > 
> > I am not sure what I should / should not be doing.
> > 
> > I get messages like this...
> > 
> > edu/uci/ics/jung/algorithms/GraphMatrixOperations.java: In class
> > `edu.uci.ics.jung.algorithms.GraphMatrixOperations':
> > edu/uci/ics/jung/algorithms/GraphMatrixOperations.java: In method
> > `edu.uci.ics.jung.algorithms.GraphMatrixOperations.matrixToGraph(cern.colt.matrix.DoubleMatrix2D,java.lang.String)':
> > edu/uci/ics/jung/algorithms/GraphMatrixOperations.java:108: error: cannot
> > find file for class cern.colt.matrix.DoubleMatrix2D
> > edu/uci/ics/jung/algorithms/GraphMatrixOperations.java:108: error: cannot
> > find file for class cern.colt.matrix.DoubleMatrix2D
> > 
> > when I try 
> > 
> > gcj -c jung-1.5.jar -o jung-1.5.o
> > 
> > 
> > I am trying things like... 
> > 
> > gcj -c jung-1.5.jar -o jung-1.5.o --classpath=colt-1.2.0.zip
> > 
> > But to no avail.
>
>What is inside colt-1.2.0.zip?  class files, source files?
>
>Somewhow you need colt-1.2.0.jar, which you can create with "jar cf".
>
>Andrew.
>



Cheers, I finally found the .jar files which are inside the .zip files
(doh!).

I am now getting the following warnings...

Any help is appreciated ! :)


gcj -c jung-1.5.jar -o jung-1.5.o
--classpath=/usr/share/java/colt.jar:/usr/share/java/commons-collections-3.1.jar:/usr/share/java/xmlParserAPIs.jar
2> warnings.dmp



more warnings.dmp
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java: In class
`edu.uci.ics.jung.algorithms.cluster.KMeansClusterer':
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java: In method
`edu.uci.ics.jung.algorithms.cluster.KMeansClusterer.cluster(java.util.Map,int)':
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:64: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:64: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:119:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:119:
error: class 'scratch.joshua.utilities.DiscreteDistribution'
h[dmb@cpc2-cmbg1-4-0-cust179 jung-1.5]$ ls
edu           jung-1.5-src.jar  samples  warnings.dmp
jung-1.5.jar  META-INF          test
[dmb@cpc2-cmbg1-4-0-cust179 jung-1.5]$ gcj -c jung-1.5.jar -o jung-1.5.o
--classpath=/usr/share/java/colt.jar:/usr/share/java/commons-collections-3.1.jar:/usr/share/java/xmlParserAPIs.jar
2> warnings.dmp
m[dmb@cpc2-cmbg1-4-0-cust179 jung-1.5]$ more warnings.dmp
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java: In class
`edu.uci.ics.jung.algorithms.cluster.KMeansClusterer':
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java: In method
`edu.uci.ics.jung.algorithms.cluster.KMeansClusterer.cluster(java.util.Map,int)':
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:64: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:64: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:119:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:119:
error: class 'scratch.joshua.utilities.DiscreteDistribution' has no method
named 'mean' matching signature '([[D)[D'
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:120:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:120:
error: class 'scratch.joshua.utilities.DiscreteDistribution' has no method
named 'squaredError' matching signature
'([D[D)D'edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java: In
method
`edu.uci.ics.jung.algorithms.cluster.KMeansClusterer.assignToClusters(java.util.Map,java.util.Set)':
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:142:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:142:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:154:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:154:
error: class 'scratch.joshua.utilities.DiscreteDistribution' has no method
named 'squaredError' matching signature
'([D[D)D'edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:159:
error: cannot find file for class
scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/KMeansClusterer.java:159:
error: class 'scratch.joshua.utilities.DiscreteDistribution' has no method
named 'squaredError' matching signature
'([D[D)D'edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java: In
class `edu.uci.ics.jung.algorithms.cluster.VoltageClusterer':
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java: In
method
`edu.uci.ics.jung.algorithms.cluster.VoltageClusterer.cluster_internal(edu.uci.ics.jung.graph.ArchetypeGraph,edu.uci.ics.jung.graph.ArchetypeVertex,int)':
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:139: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:139: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:139: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:139: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:227: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:227: error: class
'scratch.joshua.utilities.DiscreteDistribution'
has no method named 'mean' matching signature '(Ljava/util/Collection;)[D'
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:228: error: cannot
find file for class scratch.joshua.utilities.DiscreteDistribution
edu/uci/ics/jung/algorithms/cluster/VoltageClusterer.java:228: error: class
'scratch.joshua.utilities.DiscreteDistribution'
has no method named 'mean' matching signature '(Ljava/util/Collection;)[D'
edu/uci/ics/jung/algorithms/importance/AbstractRanker.java: In class
`edu.uci.ics.jung.algorithms.importance.AbstractRanker':
edu/uci/ics/jung/algorithms/importance/AbstractRanker.java: In method
`edu.uci.ics.jung.algorithms.importance.AbstractRanker.printRankings(boolean,boolean)':
edu/uci/ics/jung/algorithms/importance/AbstractRanker.java:317: error: class
'corejava.Format' has no method named 'format'
matching signature '(D)Ljava/lang/String;'
edu/uci/ics/jung/algorithms/importance/AbstractRanker.java:328: error: class
'corejava.Format' has no method named 'format'
matching signature '(D)Ljava/lang/String;'
edu/uci/ics/jung/algorithms/importance/AbstractRanker.java:338: error: class
'corejava.Format' has no method named 'format'
matching signature '(D)Ljava/lang/String;'
AbstractArchetypeGraph.java: In class
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph$Requirements':
AbstractArchetypeGraph.java: In method
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph$Requirements.add(java.lang.Object)':
AbstractArchetypeGraph.java:203: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getEdges' matching signature '()Ljava/util/Set;'
AbstractArchetypeGraph.java:203: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getVertices' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java: In class
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph':
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java: In method
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph.toString()':
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java:113: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getVertices' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java: In method
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph.numVertices()':
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java:120: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getVertices' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java: In method
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph.numEdges()':
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java:127: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getEdges' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java: In method
`edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph.copy()':
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java:174: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getVertices' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractArchetypeGraph.java:178: error: class
'edu.uci.ics.jung.graph.impl.AbstractArchetypeGraph' has no method named
'getEdges' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractSparseVertex.java: In class
`edu.uci.ics.jung.graph.impl.AbstractSparseVertex':
edu/uci/ics/jung/graph/impl/AbstractSparseVertex.java: In method
`edu.uci.ics.jung.graph.impl.AbstractSparseVertex.findEdge(edu.uci.ics.jung.graph.Vertex)':
edu/uci/ics/jung/graph/impl/AbstractSparseVertex.java:225: error: class
'edu.uci.ics.jung.graph.impl.AbstractSparseVertex' has no method named
'getOutEdges' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/graph/impl/AbstractSparseVertex.java: In method
`edu.uci.ics.jung.graph.impl.AbstractSparseVertex.findEdgeSet(edu.uci.ics.jung.graph.Vertex)':
edu/uci/ics/jung/graph/impl/AbstractSparseVertex.java:244: error: class
'edu.uci.ics.jung.graph.impl.AbstractSparseVertex' has no method named
'getOutEdges' matching signature '()Ljava/util/Set;'
edu/uci/ics/jung/io/BipartiteGraphReader.java: In class
`edu.uci.ics.jung.io.BipartiteGraphReader':
edu/uci/ics/jung/io/BipartiteGraphReader.java: In method
`edu.uci.ics.jung.io.BipartiteGraphReader.load(java.io.Reader)':
edu/uci/ics/jung/io/BipartiteGraphReader.java:192: error: class
'java.lang.String' has no method named 'split' matching signature
'(Ljava/lang/String;)[Ljava/lang/String;'
edu/uci/ics/jung/io/BipartiteGraphReader.java:194: error: class
'java.lang.String' has no method named 'split' matching signature
'(Ljava/lang/String;I)[Ljava/lang/String;'
edu/uci/ics/jung/io/MatrixFile.java: In class
`edu.uci.ics.jung.io.MatrixFile':
edu/uci/ics/jung/io/MatrixFile.java: In method
`edu.uci.ics.jung.io.MatrixFile.save(edu.uci.ics.jung.graph.Graph,java.lang.String)':
edu/uci/ics/jung/io/MatrixFile.java:150: error: class 'corejava.Format'
has no method named 'format' matching signature '(D)Ljava/lang/String;'
edu/uci/ics/jung/io/PajekNetReader.java: In class
`edu.uci.ics.jung.io.PajekNetReader':
edu/uci/ics/jung/io/PajekNetReader.java: In method
`edu.uci.ics.jung.io.PajekNetReader.load(java.io.Reader,edu.uci.ics.jung.graph.Graph,edu.uci.ics.jung.graph.decorators.NumberEdgeValue)':
edu/uci/ics/jung/io/PajekNetReader.java:250: error: class
'java.lang.String' has no method named 'split' matching signature
'(Ljava/lang/String;I)[Ljava/lang/String;'
edu/uci/ics/jung/io/PartitionDecorationReader.java: In class
`edu.uci.ics.jung.io.PartitionDecorationReader':
edu/uci/ics/jung/io/PartitionDecorationReader.java: In method
`edu.uci.ics.jung.io.PartitionDecorationReader.loadStrings(edu.uci.ics.jung.graph.Graph,java.io.Reader,org.apache.commons.collections.Predicate,java.lang.Object)':
edu/uci/ics/jung/io/PartitionDecorationReader.java:89: error:
class 'java.lang.String' has no method named 'split' matching
signature '(Ljava/lang/String;I)[Ljava/lang/String;'
edu/uci/ics/jung/random/permuters/BernoulliEdgePermuter.java:
In class `edu.uci.ics.jung.random.permuters.BernoulliEdgePermuter':
edu/uci/ics/jung/random/permuters/BernoulliEdgePermuter.java:
In method
`edu.uci.ics.jung.random.permuters.BernoulliEdgePermuter.permuteEdges(edu.uci.ics.jung.graph.Graph,double)':
edu/uci/ics/jung/random/permuters/BernoulliEdgePermuter.java:91: error: class
'cern.jet.random.sampling.RandomSampler' has no method named '<init>'
matching signature '(JJJLcern/jet/random/engine/RandomEngine;)V'
edu/uci/ics/jung/random/permuters/BernoulliEdgePermuter.java:91: error: expected
type 'null' but stack contains 'void'
edu/uci/ics/jung/random/permuters/BernoulliEdgePermuter.java:97: confused
by earlier errors, bailing out




More information about the Java mailing list