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

Improve installation instructions #58

Open
ggrothendieck opened this issue Mar 7, 2021 · 3 comments
Open

Improve installation instructions #58

ggrothendieck opened this issue Mar 7, 2021 · 3 comments

Comments

@ggrothendieck
Copy link

ggrothendieck commented Mar 7, 2021

I installed the MiniZinc binary bundle but then itheinstallation instructions say to run this:

install.packages("rminizinc", configure.args="--with-mzn=/path/to/libminizinc --with-bin=/path/to/bin")

It would be a lot easier if it gave the exact command to run for each platform. I assume that the second path is
C:\Program Files\MiniZinc\bin but could not find libminizinc in the C:\Program Files\MiniZinc tree.
What is that? There is no explanation. Where is it?
Is it possible to just set environment variables instead?

C:\Program Files\MiniZinc>dir/s libminizinc
 Volume in drive C is Windows
 Volume Serial Number is 4E54-B4C8
File Not Found

Ideally minizinc would be included right in the rminizinc package so that installating
rminizinc is all you need to do. For example, RH2 includes H2 right in the RH2 package
and Ryacas includes yacas right in the Ryacas package making these trivial to install.

@acharaakshit
Copy link
Owner

Hi,

You can find the installation instructions in the README or in the rminizinc vignette.

The installation involves two steps:

  1. Downloading and building libminizinc (for using MiniZinc C++ API ).
  2. The models can be parsed and converted into R objects but can't be solved by just using libminizinc because the libminizinc source doesn't contain the solver binaries required to solve the models. This is why you need the MiniZinc binary bundle and give the path of its bin folder which contains solver binaries as the --with-bin=/path/to/minizinc/bundle/bin. So as you said, the argument --with-bin will be C:\Program Files\MiniZinc\bin.

So , in your case, the installation command will be:
install.packages("rminizinc", configure.args="--with-mzn=/path/to/libminizinc --with-bin=C:\Program Files\MiniZinc\bin")

Some of the necessary files like solver configuration files from libminizinc are already included in rminizinc. You might need to use cygwin to build libminizinc on Windows as it provides a linux-like environment in windows.

Please let me know if you have any issues with installation or if you have any other questions.

Thanks,
Akshit

@ggrothendieck
Copy link
Author

Thanks but its too complicated. If it ever gets easier to install I may try again.

@acharaakshit
Copy link
Owner

I will explore more options and see if I can make the installation easier in the next versions. I am keeping this issue open.

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