Compile errors for Z3's JavaExample.java test of java bindings

江枫思渺然 提交于 2019-12-12 02:27:56

问题


I am trying to use Z3's java binding, particularly trying to run the Java example JavaExample.java that's distributed in Z3's 4.4.2 version.

JavaExample.java was compiling fine when I was using the 4.4.2 com.microsoft.z3.jar file. However, it would not run because the default libz3java.dll was 32-bit and my environment is 64-bit. I tried building a 64-bit Z3 with the -x flag for its Makefile maker scripts/mk_make.py but that generated an error when I ran nmake (posted about that here).

Anyway, I then downloaded the binary for Z3 4.3.2 version, which contained a 64-bit libz3java.dll. However, now JavaExample.java doesn't compile, generating a ton of errors, such as:

FiniteDomainNum cannot be resolved to a type    Z3Example.java  line 2222

for line

FiniteDomainNum s1 = (FiniteDomainNum)ctx.mkNumeral(1, s);

There are hundreds of such errors.

The jar file is properly included in the Eclipse project, just like the 4.4.2 was when JavaExample.java was compiling.

Any help on getting this going? Thanks.


回答1:


These errors are likely due to the fact that com.microsoft.z3.jar is missing or incomplete. You need to sort out the compilation issues described in the other post before the Java API will behave as it should.



来源:https://stackoverflow.com/questions/35286636/compile-errors-for-z3s-javaexample-java-test-of-java-bindings

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!