Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use system MbedTLS #66

Closed
wants to merge 5 commits into from
Closed
Changes from 2 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
15 changes: 12 additions & 3 deletions deps/build.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,21 @@ else
srcsha = "8f25b6f156ae5081e91bcc58b02455926d9324035fe5f7028a6bb5bc0139a757"
end

# Use the version of MbedTLS that ships with Julia .5 and later

provides(Binaries,
joinpath(dirname(JULIA_HOME), "..", "lib", "julia"),
Copy link
Contributor

Choose a reason for hiding this comment

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

One of either dirname or ".." are redundant, JULIA_HOME is already the bin directory. On Windows this should be just JULIA_HOME.

mbed_all)


# For Julia versions less than .5

provides(Sources,
source_uri,
mbed_all, unpacked_dir="mbedtls-2.1.1",
SHA = srcsha)

if is_unix()
if is_unix()
mbed_dir = joinpath(BinDeps.depsdir(mbed), "src", "mbedtls-2.1.1")
provides(BuildProcess,
(@build_steps begin
Expand All @@ -52,15 +61,15 @@ if is_unix()
end), mbed_all, installed_libpath=joinpath(mbed_dir, "library"))
end

if is_apple()
if is_apple()
if Pkg.installed("Homebrew") === nothing
error("Homebrew package not installed, please run Pkg.add(\"Homebrew\")")
end
using Homebrew
provides(Homebrew.HB, "mbedtls", mbed_all)
end

if is_windows()
if is_windows()
unpacked_dir = Int==Int32 ? "usr/bin32" : "usr/bin64"
provides(
Binaries,
Expand Down