-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Yices2 windows support #215
base: master
Are you sure you want to change the base?
Conversation
I have just tested it on a new Windows environment and it works without any issues. |
For MathSAT we use an existing DLL from the original development team and then MinGW on Linux to build the bindings for Windows. |
We have to provide the GMP library additionally, but yes that should simplify it immensely. |
GMP can be build with MinGW on Linux. I have already done that for MathSAT. That's easy. |
Are you sure about GMP? The Windows-version is called MPIR. |
GMP is statically linked in the provided Yices2 Windows binary, so that solves that. It would most likely suffice to compile it on Linux, i can test it. |
I've tested the prebuilt |
Update: The linker can't know what is used by yices, only our wrapper, so it only statically adds the wrapper parts. Of course the needed yices components are missing then. This could be solved by using the Winpthread is needed but the linker won't link it when threads are not used. This is solved by the A problem arises when using the mentioned flag on all libraries, as mutex is defined in winpthread and stdc++, therefore it can't link all 3, just 2. (gcc is always fine, but just one of the others) Ideas: |
We already use (and used) our own version of Yices for Linux, based on some Git revision of their repository. |
I don't know if that is possible for Windows. The Yices2 devs only provide build documentation for Cygwin + Mingw (and Cygwin alone). I can test it and take a look at the build script. |
I tested building the Yices2 version on Linux, however the config does not seem to work for that purpose. But i updated to build information for Cygwin + Mingw and the script that builds the wrapper in Cygwin. The only issue with them is that multithreading is not supported as i get an error when trying to compile with it. If we were to use the prebuild Yices2 this issue would be resolved. But the script would have to be extended a little. I put instructions and possible hints if it fails into the script as i tested this with the old prebuild binaries. Would you like me to continue this until multithreading is supported? |
This PR covers the Windows support for Yices2.
The JNI-wrapper was changed to conform to Windows pointer standards.
A bash script is provided that explains how to build Yices2 for Windows and then compiles and links the wrapper to it.
Note: Yices2 only provides explanations as to how to build it inside Windows with Cygwin + Mingw.
I don't know if it is possible to simply skip Cygwin and compile it with Mingw on a Unix system, do you know more about that @kfriedberger ?
The Yices2 Windows components are the following:
-libyices.dll
-libyices2j.dll
-libgmp-10.dll
TODO:
This needs to be tested on a Windows environment that does NOT have libgmp-10.dll installed in any way!