Julia static compilation

Read @joaquimg’s summary above. What you’re asking for isn’t static compilation: it’s compilation of a script to an executable that includes the Julia runtime. This is what MATLAB/Python/R do, which is why the resulting executables are large.

Julia can actually do something else as well: it can generate all of its compiled code and make that executable without Julia. This second case is static compilation, and is more akin to compiling C than it is to compiling MATLAB/Python/R. But it has more restrictions: it cannot do anything that requires the Julia runtime (no @eval and no @generated).

Either way it generates binaries that hide code. But they are different.

2 Likes