Skip to content

Commit

Permalink
Add Artifacts as dependency (#78)
Browse files Browse the repository at this point in the history
* Add Artifacts as dependency, fixes #60.

* correct location for inserting MKL stub

Co-authored-by: KristofferC <kcarlsson89@gmail.com>
  • Loading branch information
danielwe and KristofferC authored May 25, 2021
1 parent aa2d1ba commit e53eb68
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@ uuid = "33e6dc65-8f57-5167-99aa-e5a354878fb2"
version = "0.4.0"

[deps]
Artifacts = "56f22d72-fd6d-98f1-02f0-08ddc0907c33"
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
MKL_jll = "856f044c-d86e-5d09-b602-aeab76dc8ba7"
PackageCompiler = "9b87118b-4619-50d2-8e1e-99f35a4d4d9d"

[compat]
MKL_jll = "2021"
PackageCompiler = "1"
julia = "1.3"
MKL_jll = "2021"

[extras]
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Expand Down
6 changes: 5 additions & 1 deletion src/install.jl
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,11 @@ function insert_MKL_load(base_dir)
end

# After this the stdlibs get included, so insert MKL to be loaded here
start_idx = findfirst(match.(r"Base._track_dependencies\[\] = true", lines) .!= nothing)
if VERSION >= v"1.6.0"
start_idx = findfirst(match.(r"# Stdlibs sorted in dependency, then alphabetical, order by contrib/print_sorted_stdlibs.jl", lines) .!= nothing)
else
start_idx = findfirst(match.(r"Base._track_dependencies\[\] = true", lines) .!= nothing)
end

splice!(lines, (start_idx + 1):start_idx, MKL_PAYLOAD_LINES)
write(file, string(join(lines, '\n'), '\n'))
Expand Down

0 comments on commit e53eb68

Please sign in to comment.