Skip to content
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

Installing gr1c on Windows #34

Closed
abadithela opened this issue Jul 17, 2019 · 8 comments
Closed

Installing gr1c on Windows #34

abadithela opened this issue Jul 17, 2019 · 8 comments
Assignees

Comments

@abadithela
Copy link

I'm new to using TuLiP. I'm trying to install gr1c but I don't think it works with Windows. Should I use a VM? Could you please advise on how I should proceed?

@slivingston
Copy link
Member

@abadithela is this issue still open for you ?

@slivingston slivingston self-assigned this Oct 29, 2019
@slivingston
Copy link
Member

related issue: tulip-control/tulip-control#197

@slivingston
Copy link
Member

also related: #35

@abadithela
Copy link
Author

Hi Scott, Yes, this is still an issue for me. However, I'm able to use most TuLiP functions without gr1c.

@slivingston
Copy link
Member

I am going to re-open this issue because it is not actually solved if you are not using gr1c.

slivingston added a commit that referenced this issue Mar 26, 2020
With this changeset, building gr1c for Windows is operational but not
fully tested. To do it, first install a cross-compiler from the
mingw-w64 project (http://mingw-w64.org/). Major GNU/Linux
distributions have this available in respective package repositories;
e.g., on Fedora or RedHat, `dnf install mingw64-gcc`, and on Ubuntu,
`apt-get install gcc-mingw-w64`. Then,

    export CC=x86_64-w64-mingw32-gcc
    export LD="x86_64-w64-mingw32-ld -r"

Then, for building CUDD,

    ./configure --prefix=`pwd`/../.. --host=x86_64-w64-mingw32

and for gr1c,

    make -e

This is part of work for issue #34
and tulip-control/tulip-control#197

* about _WIN32 and _WIN64 macros, https://docs.microsoft.com/en-us/cpp/preprocessor/predefined-macros?view=vs-2019
* about _spawnvp(), https://docs.microsoft.com/en-us/cpp/c-runtime-library/spawn-wspawn-functions?view=vs-2019
@slivingston
Copy link
Member

As of commit 3287935, gr1c can be cross-compiled for Windows from GNU/Linux hosts. The commit message has a summary of instructions, which I will expand and put in the documentation.

I tried several examples both for gr1c and gr1c rg, all of which gave output that has no obvious error. However, I have performed some but not all tests. I am working to port the testing suite now.

slivingston added a commit that referenced this issue Mar 27, 2020
Write instructions about building gr1c for Windows. These instructions
are known to work when cross-compiling on a GNU/Linux host with target
of 64-bit Windows.

This is part of work for issue #34
@slivingston
Copy link
Member

@abadithela I built gr1c for Windows. If you have an opportunity, I would greatly appreciate your feedback. Built executables are available at https://github.com/tulip-control/gr1c/releases/download/v0.13.0/gr1c-0.13.0-Win64.zip (part of the new release).

@slivingston
Copy link
Member

no reported errors since the release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants