我想用jaotc
. 虽然我能够构建 Java 10 模块的共享库,但我无法弄清楚如何编译单个类。我班的 FQCN 是net.sweblog.jm18.aot.hw.HelloWorld
,它的完整路径是target/classes/net/sweblog/jm18/aot/hw/HelloWorld.class
.
所以尝试jaotc
如下调用:
$ jaotc --output output/helloworld.so \
--search-path helloworld/target/classes/ \
--class-name net.sweblog.jm18.aot.hw.HelloWorld
Error: Failed to find class file: net.sweblog.jm18.aot.hw.HelloWorld
java.lang.NullPointerException
at jdk.aot/jdk.tools.jaotc.Main.run(Main.java:135)
at jdk.aot/jdk.tools.jaotc.Main.run(Main.java:101)
at jdk.aot/jdk.tools.jaotc.Main.main(Main.java:80)
有谁知道如何jaotc
正确调用来编译我的类文件?