-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update build.jl * Update REQUIRE * Update build.jl * Update build.jl * Update REQUIRE * Update build.jl * Update build.jl * Update .gitignore * Update REQUIRE * Update build.jl * Update REQUIRE * Update REQUIRE * downgrade to 2.0.5 * updated binaries installation make sure updated versions of binaries are installed * Update MOIWrapper.jl * Update MPBWrapper.jl * Update README.md * Fix WIN32 tests * custom install instructions
- Loading branch information
1 parent
2359497
commit db356d4
Showing
7 changed files
with
57 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
julia 0.6 | ||
BinDeps | ||
MathProgBase 0.5 0.8 | ||
MathOptInterface 0.6 0.7 | ||
@osx Homebrew | ||
Compat 0.68 | ||
BinaryProvider 0.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,2 @@ | ||
deps.jl | ||
usr/ | ||
downloads/ | ||
src/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,48 @@ | ||
using BinDeps | ||
using Compat | ||
|
||
@BinDeps.setup | ||
|
||
ecos = library_dependency("ecos", aliases=["libecos"]) | ||
|
||
if Compat.Sys.isapple() | ||
using Homebrew | ||
provides( Homebrew.HB, "ecos", ecos, os = :Darwin ) | ||
using BinaryProvider # requires BinaryProvider 0.3.0 or later | ||
|
||
# Parse some basic command-line arguments | ||
const verbose = "--verbose" in ARGS | ||
const prefix = Prefix(get([a for a in ARGS if a != "--verbose"], 1, joinpath(@__DIR__, "usr"))) | ||
products = [ | ||
LibraryProduct(prefix, String["libecos"], :ecos), | ||
] | ||
|
||
# Download binaries from hosted location | ||
bin_prefix = "https://github.com/juan-pablo-vielma/ECOSBuilder/releases/download/v2.0.5-beta" | ||
|
||
# Listing of files generated by BinaryBuilder: | ||
download_info = Dict( | ||
Linux(:aarch64, :glibc) => ("$bin_prefix/ECOSBuilder.v2.0.5.aarch64-linux-gnu.tar.gz", "9e6279a971889df14eaa384c8138136c5918e1a3a97e913d1a23fb3e80d711a6"), | ||
Linux(:aarch64, :musl) => ("$bin_prefix/ECOSBuilder.v2.0.5.aarch64-linux-musl.tar.gz", "afeb89f158dbcb506230e35e13ad63ab374a35f8b4ebe3ff4d1c604acb98e79f"), | ||
Linux(:armv7l, :glibc, :eabihf) => ("$bin_prefix/ECOSBuilder.v2.0.5.arm-linux-gnueabihf.tar.gz", "2fd091c5581156acc1a135d7ad969563f4a356b2631b3d2f2e215c114960c98b"), | ||
Linux(:armv7l, :musl, :eabihf) => ("$bin_prefix/ECOSBuilder.v2.0.5.arm-linux-musleabihf.tar.gz", "776ceedd12467a761354e73641dba4c0e0b34df9e5635360880e0d7f4c347c64"), | ||
Linux(:i686, :glibc) => ("$bin_prefix/ECOSBuilder.v2.0.5.i686-linux-gnu.tar.gz", "2b622c881c0c0cb9a12f514a211512b8a0c2404c6e35f4817e0c590095a759aa"), | ||
Linux(:i686, :musl) => ("$bin_prefix/ECOSBuilder.v2.0.5.i686-linux-musl.tar.gz", "0318aafa7457e0d1cb9a85e0938498457341d0050036ac24ab05b8f2d0ea7d4f"), | ||
Windows(:i686) => ("$bin_prefix/ECOSBuilder.v2.0.5.i686-w64-mingw32.tar.gz", "2c5fba5caed62b5edc1199ebd62e702212197b916f6bab8f7ba30c2c16326117"), | ||
Linux(:powerpc64le, :glibc) => ("$bin_prefix/ECOSBuilder.v2.0.5.powerpc64le-linux-gnu.tar.gz", "9d75f00a0bd9ba2aa917f073cb9544f4fb74f0cd711eeb5b06ab13efe70cf16a"), | ||
MacOS(:x86_64) => ("$bin_prefix/ECOSBuilder.v2.0.5.x86_64-apple-darwin14.tar.gz", "617f20ee41dbbd34dd7f8cb4c8c5f84bf5e52646886880679d8c116de418fd29"), | ||
Linux(:x86_64, :glibc) => ("$bin_prefix/ECOSBuilder.v2.0.5.x86_64-linux-gnu.tar.gz", "69ea265aab6701b9ce2b9c3b6d574bd88f1fd4640527a8d106385359abe88021"), | ||
Linux(:x86_64, :musl) => ("$bin_prefix/ECOSBuilder.v2.0.5.x86_64-linux-musl.tar.gz", "52f6c0f3742e316eb15d5180cfa41c6a7985104745f7ede0bf0577087af97384"), | ||
FreeBSD(:x86_64) => ("$bin_prefix/ECOSBuilder.v2.0.5.x86_64-unknown-freebsd11.1.tar.gz", "52f2167039d40115a92f428c81e81b3de000cece3756ea9bfcf12c07ef6bd9bc"), | ||
Windows(:x86_64) => ("$bin_prefix/ECOSBuilder.v2.0.5.x86_64-w64-mingw32.tar.gz", "f38e30147d12bb06eab3517c314444ffaedf13f252947cb458bd34cddb73e481"), | ||
) | ||
|
||
# Install unsatisfied or updated dependencies: | ||
unsatisfied = any(!satisfied(p; verbose=verbose) for p in products) | ||
if haskey(download_info, platform_key()) | ||
url, tarball_hash = download_info[platform_key()] | ||
# Check if this build.jl is providing new versions of the binaries, and | ||
# if so, ovewrite the current binaries even if they were installed by the user | ||
if unsatisfied || !isinstalled(url, tarball_hash; prefix=prefix) | ||
# Download and install binaries | ||
install(url, tarball_hash; prefix=prefix, force=true, verbose=verbose) | ||
end | ||
elseif unsatisfied | ||
# If we don't have a BinaryProvider-compatible .tar.gz to download, complain. | ||
# Alternatively, you could attempt to install from a separate provider, | ||
# build from source or something even more ambitious here. | ||
error("Your platform $(triplet(platform_key())) is not supported by this package!") | ||
end | ||
|
||
version = "2.0.5" | ||
win_version = "2.0.2" | ||
provides(Sources, URI("https://github.com/ifa-ethz/ecos/archive/v$version.tar.gz"), | ||
[ecos], os = :Unix, unpacked_dir="ecos-$version") | ||
|
||
prefix = joinpath(BinDeps.depsdir(ecos),"usr") | ||
srcdir = joinpath(BinDeps.depsdir(ecos),"src","ecos-$version") | ||
|
||
provides(Binaries, URI("https://cache.julialang.org/https://bintray.com/artifact/download/tkelman/generic/ecos-$win_version.7z"), | ||
[ecos], unpacked_dir="usr/bin$(Sys.WORD_SIZE)", os = :Windows, | ||
SHA="b90254220a9a63cba08700f3664519d360f45d363454e5c107e6f30e144a60a1") | ||
|
||
# We'll keep this around for emergencies, but OSX users should be able to use Homebrew | ||
provides(SimpleBuild, | ||
(@build_steps begin | ||
GetSources(ecos) | ||
CreateDirectory(joinpath(prefix,"lib")) | ||
FileRule(joinpath(prefix,"lib","libecos.dylib"),@build_steps begin | ||
ChangeDirectory(srcdir) | ||
`make shared` | ||
`mv libecos.dylib $prefix/lib` | ||
end) | ||
end),[ecos], os = :Darwin) | ||
|
||
provides(SimpleBuild, | ||
(@build_steps begin | ||
GetSources(ecos) | ||
CreateDirectory(joinpath(prefix,"lib")) | ||
FileRule(joinpath(prefix,"lib","libecos.so"),@build_steps begin | ||
ChangeDirectory(srcdir) | ||
`make shared` | ||
`mv libecos.so $prefix/lib` | ||
end) | ||
end),[ecos], os = :Unix) | ||
|
||
@BinDeps.install Dict(:ecos => :ecos) | ||
# Write out a deps.jl file that will contain mappings for our products | ||
write_deps_file(joinpath(@__DIR__, "deps.jl"), products, verbose=verbose) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters