This is an extremely basic question, but I haven't been able to find the answer anywhere. I'm completely new to Java.
There's a Java program on github that I'm trying to get running on my Mac. The associated documentation does not give any information on compiling or running the code. I would prefer not disclosing in any more detail the specific program I'm trying to run.
The program contains multiple .java files and a classmexer.jar file for tracking memory usage. There is also a subfolder, cern, that contains additional subfolders that ultimately contain .class files. There is no makefile.
I've downloaded all of the source code as a tar.gz file and unwrapped it into ~/codeDirectory/. When I try to compile from this directory with
$ javac *.java
or
$ javac A.java
(where A.java is the first class that program calls), I get dozens of compile errors. This code clearly compiles successfully elsewhere, so I'm unsure what to make of this.
The first error that appears is
A.java:5: cannot access cern.colt.function.DoubleFunction
class file for cern.colt.function.DoubleFunction not found
cern.jet.random.AbstractDistribution.makeDefaultGenerator();
^
./B.java:4: package com.javamex.classmexer does not exist
import com.javamex.classmexer.*;
^
./B.java:180: cannot find symbol
symbol : variable MemoryUtil
location: class B
long noBytes = MemoryUtil.deepMemoryUsageOf(hp);
^
My suspicion is that there's an improperly or incorrectly specific path somewhere, but I haven't been able to find it.
Thanks in advance for any help troubleshooting.
coltlibraries, if they weren't included. If there is a POM file, it can maybe do this automatically when you use maven.