Skip to content

Commit

Permalink
Do not run precompilation for sys0.
Browse files Browse the repository at this point in the history
  • Loading branch information
yuyichao committed May 20, 2015
1 parent 8a1508d commit 5e4643b
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion base/sysimg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,20 @@ importall .Base64
include("io.jl")
include("iostream.jl")

const _is_sys0 = (JLOptions().image_file == C_NULL &&
(JLOptions().build_path != C_NULL &&
endswith(bytestring(JLOptions().build_path), "sys0")))

ccall(:jl_, Void, (Any,), _is_sys0)
ccall(:jl_, Void, (Any,), JLOptions().image_file == C_NULL)
ccall(:jl_, Void, (Any,), (JLOptions().build_path != C_NULL &&
endswith(bytestring(JLOptions().build_path), "sys0")))
ccall(:jl_, Void, (Any,), JLOptions().image_file)
ccall(:jl_, Void, (Any,), JLOptions().build_path)
ccall(:jl_, Void, (Any,), (JLOptions().build_path != C_NULL ?
bytestring(JLOptions().build_path) :
"(null)"))

# system & environment
include("libc.jl")
using .Libc: getpid, gethostname, time, msync
Expand Down Expand Up @@ -313,7 +327,9 @@ function __init__()
init_parallel()
end

include("precompile.jl")
if !_is_sys0
include("precompile.jl")
end

include = include_from_node1

Expand Down

0 comments on commit 5e4643b

Please sign in to comment.