我的代码中出现以下异常,我不确定系统找不到哪个文件。是我正在执行的命令找不到gfortran.exe
还是 gfortran 依赖的动态库?我怎么知道,哪个文件是找不到的?
java.io.IOException: CreateProcess error=2, The system cannot find the file specified
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.<init>(ProcessImpl.java:376)
at java.lang.ProcessImpl.start(ProcessImpl.java:136)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1022)
Caused: java.io.IOException: Cannot run program "gfortran.exe" (in directory "C:\Users\Jason Zwolak\AppData\Local\Temp\pet2-biopack-Jason Zwolak"): CreateProcess error=2, The system cannot find the file specified
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1041)
at com.insilicalabs.pet2.publish.mpf.BiopackCompiler.compile(BiopackCompiler.java:154)
[catch] at com.insilicalabs.pet2.publish.mpf.PublishToMPFProvider.publishImpl(PublishToMPFProvider.java:190)
at com.insilicalabs.pet2.publish.mpf.PublishToMPFProvider.access$000(PublishToMPFProvider.java:60)
at com.insilicalabs.pet2.publish.mpf.PublishToMPFProvider$1.run(PublishToMPFProvider.java:67)
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432)
at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2044)
更新
澄清一下,如果gfortran.exe
是找不到文件,是否总是会出现这样的错误?还是找不到共享库?我怎么知道找不到哪个文件?