Wednesday, July 15, 2009

gcj 1.5.x: error: /classname/ cannot be resolved to a type

I cannot compile GDCM against VTK anymore using gcj 1.5.x:

* http://gcc.gnu.org/ml/java/2009-07/msg00013.html

1 comment:

malat said...

Answer is at:

http://gcc.gnu.org/ml/java/2009-07/msg00018.html

hanks to Andrew, I was able to track down the issue to a problem with
the javac wrapper as distribute in the debian linux distribution.
Which basically provide a javac Sun-like cmd line, and forward args to
gcj. Namely:

...
} elsif ($arg eq '-classpath' or $arg eq '--classpath' or $arg eq '--cp') {
$appendNextArg = '--classpath=';
...

Thus -cp was never taken into account.