Nergar
October 23rd, 2007, 04:25 AM
Im having a problem with javac, it isn't using . as the classpath when not supplying one. why is that happening?
for example:
nergar@nergar-lap:class$ javac Catfish.java
Catfish.java:14: cannot find symbol
symbol: class LivingBeing
public class Catfish extends LivingBeing {
^
Catfish.java:206: cannot find symbol
symbol : method getRand()
location: class Simulation
row = simulation.getRand().nextInt(10);
^
Catfish.java:208: cannot find symbol
symbol : method getRand()
location: class Simulation
column = simulation.getRand().nextInt(10);
^
3 errors
nergar@nergar-lap:class$
and
nergar@nergar-lap:class$ javac -cp . Catfish.java
nergar@nergar-lap:class$
Works fine
for example:
nergar@nergar-lap:class$ javac Catfish.java
Catfish.java:14: cannot find symbol
symbol: class LivingBeing
public class Catfish extends LivingBeing {
^
Catfish.java:206: cannot find symbol
symbol : method getRand()
location: class Simulation
row = simulation.getRand().nextInt(10);
^
Catfish.java:208: cannot find symbol
symbol : method getRand()
location: class Simulation
column = simulation.getRand().nextInt(10);
^
3 errors
nergar@nergar-lap:class$
and
nergar@nergar-lap:class$ javac -cp . Catfish.java
nergar@nergar-lap:class$
Works fine