Skip to content

Commit 73e0fba

Browse files
committed
update prebuilt binary link to v1.5.0
1 parent 2fbe8d9 commit 73e0fba

File tree

2 files changed

+11
-13
lines changed

2 files changed

+11
-13
lines changed

REQUIRE

Lines changed: 0 additions & 6 deletions
This file was deleted.

deps/build.jl

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ using LinearAlgebra
2323
# First try to detect and load existing libmxnet
2424
################################################################################
2525
libmxnet_detected = false
26-
libmxnet_curr_ver = get(ENV, "MXNET_COMMIT", "master")
27-
curr_win = "20180211" # v1.1.0
26+
libmxnet_curr_ver = get(ENV, "MXNET_COMMIT", "1.5.0")
27+
curr_win = "20190608" # v1.5.0
2828

2929
if haskey(ENV, "MXNET_HOME")
3030
MXNET_HOME = ENV["MXNET_HOME"]
@@ -119,21 +119,25 @@ if !libmxnet_detected
119119
base_url = "https://github.com/yajiedesign/mxnet/releases/download/weekly_binary_build_v2/prebuildbase_win10_x64_vc14_v2.7z"
120120

121121
if libmxnet_curr_ver == "master"
122+
_cmd = "{
123+
[System.Net.ServicePointManager]::SecurityProtocol='tls12';
124+
Invoke-WebRequest -Uri 'https://api.github.com/repos/yajiedesign/mxnet/releases/latest'
125+
-OutFile 'mxnet.json'}"
122126
# download_cmd uses powershell 2, but we need powershell 3 to do this
123-
run(`powershell -NoProfile -Command Invoke-WebRequest -Uri "https://api.github.com/repos/yajiedesign/mxnet/releases/latest" -OutFile "mxnet.json"`)
127+
run(`powershell -NoProfile -Command $_cmd`)
124128
curr_win = JSON.parsefile("mxnet.json")["tag_name"]
125129
@info("Can't use MXNet master on Windows, using latest binaries from $curr_win.")
126130
end
127131
# TODO: Get url from JSON.
128-
name = "mxnet_x64_vc14_$(HAS_CUDA ? "gpu" : "cpu").7z"
132+
# TODO: detect cuda version and select corresponding url.
133+
name = "mxnet_x64_$(HAS_CUDA ? "vc141_gpu_cu101" : "vc14_cpu").7z"
129134
package_url = "https://github.com/yajiedesign/mxnet/releases/download/$(curr_win)/$(curr_win)_$(name)"
130135

131-
exe7z = joinpath(JULIA_HOME, "7z.exe")
136+
exe7z = joinpath(Sys.BINDIR, "7z.exe")
132137

133138
run(download_cmd(package_url, "mxnet.7z"))
134139
# this command will create the dir "usr\\lib"
135-
run(`$exe7z x mxnet.7z build lib -y -ousr`)
136-
run(`cmd /c copy "usr\\build\\*.dll" "usr\\lib"`)
140+
run(`$exe7z e mxnet.7z *\\build\\* *\\lib\\* -y -ousr\\lib`)
137141

138142
run(download_cmd(base_url, "mxnet_base.7z"))
139143
run(`$exe7z x mxnet_base.7z -y -ousr`)

0 commit comments

Comments
 (0)