From 05b085928d13bdc81af6577e665a3d0c806620a9 Mon Sep 17 00:00:00 2001 From: Tony Kelman Date: Fri, 20 Feb 2015 23:49:27 -0800 Subject: [PATCH] Use julia_exename() for julia_cmd and in repl, spawn, cmdlineargs tests ref https://github.com/JuliaLang/julia/commit/2670c7710185e8b3f9705125c1c9bd3e891c38f4#commitcomment-9836070 --- base/util.jl | 2 +- test/cmdlineargs.jl | 2 +- test/repl.jl | 2 +- test/spawn.jl | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/base/util.jl b/base/util.jl index f7295ec2b7e98..f50055f4cc0ba 100644 --- a/base/util.jl +++ b/base/util.jl @@ -260,7 +260,7 @@ warn(io::IO, err::Exception; prefix="ERROR: ", kw...) = warn(err::Exception; prefix="ERROR: ", kw...) = warn(STDERR, err, prefix=prefix; kw...) -function julia_cmd(julia=joinpath(JULIA_HOME, "julia")) +function julia_cmd(julia=joinpath(JULIA_HOME, julia_exename())) opts = JLOptions() cpu_target = bytestring(opts.cpu_target) image_file = bytestring(opts.image_file) diff --git a/test/cmdlineargs.jl b/test/cmdlineargs.jl index 716e42a8cfffc..4c3ac2ab972c2 100644 --- a/test/cmdlineargs.jl +++ b/test/cmdlineargs.jl @@ -1,4 +1,4 @@ -let exename = joinpath(JULIA_HOME, (ccall(:jl_is_debugbuild, Cint, ()) == 0 ? "julia" : "julia-debug")) +let exename = joinpath(JULIA_HOME, Base.julia_exename()) # --version let v = split(readall(`$exename -v`), "julia version ")[end] @test VERSION == VersionNumber(v) diff --git a/test/repl.jl b/test/repl.jl index ab6a77e063121..5a1bdc9e4a557 100644 --- a/test/repl.jl +++ b/test/repl.jl @@ -217,7 +217,7 @@ end ccall(:jl_exit_on_sigint, Void, (Cint,), 1) -let exename=joinpath(JULIA_HOME,(ccall(:jl_is_debugbuild,Cint,())==0?"julia":"julia-debug")) +let exename = joinpath(JULIA_HOME, Base.julia_exename()) # Test REPL in dumb mode @unix_only begin diff --git a/test/spawn.jl b/test/spawn.jl index 7cba8bada11c0..b3ad59138102e 100644 --- a/test/spawn.jl +++ b/test/spawn.jl @@ -160,7 +160,7 @@ unmark(sock) close(sock) # issue #4535 -exename=joinpath(JULIA_HOME,(ccall(:jl_is_debugbuild,Cint,())==0?"julia":"julia-debug")) +exename = joinpath(JULIA_HOME, Base.julia_exename()) if valgrind_off # If --trace-children=yes is passed to valgrind, we will get a # valgrind banner here, not "Hello World\n".