Skip to content
This repository was archived by the owner on Aug 16, 2023. It is now read-only.

[WIP] refactor into const globals #159

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions src/BinaryProvider.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,19 @@ include("Products.jl")
include("CompatShims.jl")

function __init__()
global global_prefix

# Initialize our global_prefix
global_prefix = Prefix(joinpath(dirname(pathof(@__MODULE__)), "..", "global_prefix"))

path = joinpath(@__DIR__, "..", "global_prefix")
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See #156 for my alternative fix. (Though I actually prefer your version personally.)

global_prefix[] = Prefix(path)
default_platkey[] = platform_key_abi(string(
Sys.MACHINE,
compiler_abi_str(detect_compiler_abi()),
))
# Find the right download/compression engines for this platform
probe_platform_engines!()
try
probe_platform_engines!()
catch e
@show e
end
end

# gotta go fast
Expand Down
Loading