Skip to content

Commit c1b241a

Browse files
committed
Add support for Windows
1 parent 8a3404b commit c1b241a

File tree

3 files changed

+4
-18
lines changed

3 files changed

+4
-18
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
fail-fast: false
1313
matrix:
1414
version: ['1.6', '1'] # Test against LTS and current minor release
15-
os: [ubuntu-latest, macOS-latest] # MiniZinc_jll broken on windows-latest
15+
os: [ubuntu-latest, macOS-latest, windows-latest]
1616
arch: [x64]
1717
steps:
1818
- uses: actions/checkout@v2

README.md

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,8 @@ import Pkg
2626
Pkg.add("MiniZinc")
2727
```
2828

29-
**Windows**
30-
31-
On Linux and macOS, this package automatically installs `libminizinc`. However,
32-
we're still working out problems with the install on Windows. To use
33-
MiniZinc.jl, you'll need to manually install a copy of `libminizinc` from
34-
[minizinc.org](https://www.minizinc.org) or compile one yourself from
35-
[MiniZinc/libminizinc](https://github.com/MiniZinc/libminizinc).
36-
37-
To teach MiniZinc.jl where to look for `libminizinc`, set the
38-
`JULIA_LIBMINIZINC_DIR` environment variable. For example:
29+
To use a custom install of MiniZinc, set the `JULIA_LIBMINIZINC_DIR` environment
30+
variable. For example:
3931
```julia
4032
ENV["JULIA_LIBMINIZINC_DIR"] = "C:\\Program Files\\MiniZinc"
4133
```

src/optimize.jl

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,8 @@ function _minizinc_exe(f::F) where {F}
4545
else
4646
return f(joinpath(user_dir, "minizinc"))
4747
end
48-
elseif Sys.islinux() || Sys.isapple()
49-
return MiniZinc_jll.minizinc(f)
5048
end
51-
return error(
52-
"Unable to call libminizinc. Please manually install a copy and set " *
53-
"the `JULIA_LIBMINIZINC_DIR` environment variable. See the README.md " *
54-
"for more details",
55-
)
49+
return MiniZinc_jll.minizinc(f)
5650
end
5751

5852
function _run_minizinc(dest::Optimizer)

0 commit comments

Comments
 (0)