Skip to content

Commit b364d73

Browse files
authored
also bundle certificate (#711)
* also bundle certificate should fix JuliaLang/MbedTLS.jl#219 (comment)
1 parent 57102e2 commit b364d73

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/PackageCompiler.jl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,7 @@ function create_app(package_dir::String,
704704
bundle_julia_libraries(app_dir)
705705
bundle_julia_executable(app_dir)
706706
bundle_project(ctx, app_dir)
707+
bundle_cert(app_dir)
707708

708709
sysimage_path = joinpath(app_dir, "lib", "julia", "sys." * Libdl.dlext)
709710

@@ -887,6 +888,7 @@ function create_library(package_dir::String,
887888
bundle_julia_libraries(dest_dir)
888889
bundle_artifacts(ctx, dest_dir; include_lazy_artifacts)
889890
bundle_headers(dest_dir, header_files)
891+
bundle_cert(dest_dir)
890892

891893
lib_dir = Sys.iswindows() ? joinpath(dest_dir, "bin") : joinpath(dest_dir, "lib")
892894

@@ -1191,4 +1193,11 @@ function bundle_headers(dest_dir, header_files)
11911193
return
11921194
end
11931195

1196+
function bundle_cert(dest_dir)
1197+
cert_path = joinpath(Sys.BINDIR, "..", "share", "julia", "cert.pem")
1198+
share_path = joinpath(dest_dir, "share", "julia")
1199+
mkpath(share_path)
1200+
cp(cert_path, joinpath(share_path, "cert.pem"))
1201+
end
1202+
11941203
end # module

0 commit comments

Comments
 (0)