I am trying to write a Java 9 module, but no matter what I do, I get the error message "package is empty or does not exist." I tried searching the Internet for the expected catalog layout and tried every option in the catalog layout that I can think of, but nothing works.
For example, here is one layout I tried
bar.foo/module-info.java
module bar.foo {
exports bar.foo;
}
bar.foo/bar/foo/wtf.java
package bar.foo;
public class wtf {
}
However, compilation still gives the same error as usual.
> javac bar.foo/module-info.java
bar.foo/module-info.java:2: error: package is empty or does not exist: bar.foo
exports bar.foo;
^
1 error
source
share