Using PackageCompiler with include function


#1

Hi there,

I am using PackageCompiler to build an executable on windows. I have a main function and run build_executable function to create my executable.

my julia_main is:
module mystuff
Base.@ccallable function julia_main(ARGS::Vector{String})::Cint
include(“hello.jl”)
return 0
end
end

where hello.jl countain a println(“Hello World”)

the build_executable work perfectly and create an exe file, but when I run the exe file it failed and doesnt not run the include(“hello.jl”) any idea why?

thank you


#2

sorry this

module mystuff
Base.@ccallable function julia_main(ARGS::Vector{String})::Cint
include(“hello.jl”)
return 0
end
end

is not working

but this is working

module mystuff
Base.@ccallable function julia_main(ARGS::Vector{String})::Cint
println(“hello.jl”)
return 0
end
end

Can someone help me to build an executable where I have a part of my code in an other julia script (part2.jl) for instance, that I can bring with include function?