Skip to content

Commit

Permalink
Download toolchains in parallel
Browse files Browse the repository at this point in the history
  • Loading branch information
Octogonapus committed Apr 23, 2024
1 parent 0d6b224 commit 5d4b1d2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion gen/generate.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
dir=$(dirname "$0")
julia --project="$dir" -e 'using Pkg; Pkg.instantiate()'
julia --project="$dir" "$dir/generator.jl"
julia --project="$dir" -t auto "$dir/generator.jl"
16 changes: 14 additions & 2 deletions gen/generator.jl
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,21 @@ function get_docs(node, docs)
return docs
end

function should_skip_target(target)
# aws_c_common_jll does not support i686 windows https://github.com/JuliaPackaging/Yggdrasil/blob/bbab3a916ae5543902b025a4a873cf9ee4a7de68/A/aws_c_common/build_tarballs.jl#L48-L49
return target == "i686-w64-mingw32"
end

# download toolchains in parallel
Threads.@threads for target in JLLEnvs.JLL_ENV_TRIPLES
if should_skip_target(target)
continue
end
get_default_args(target) # downloads the toolchain
end

for target in JLLEnvs.JLL_ENV_TRIPLES
if target == "i686-w64-mingw32"
# aws_c_common_jll does not support i686 windows https://github.com/JuliaPackaging/Yggdrasil/blob/bbab3a916ae5543902b025a4a873cf9ee4a7de68/A/aws_c_common/build_tarballs.jl#L48-L49
if should_skip_target(target)
continue
end
options = load_options(joinpath(@__DIR__, "generator.toml"))
Expand Down

0 comments on commit 5d4b1d2

Please sign in to comment.