To make this even easier for people, I’ve got a repo set up where you can start with a working project.
Just clone the repo:
https://github.com/dlakelan/JuliaDataSysimageMaker
then in buildimg.jl go in and change the output path for the sysimage to match where you want it on your machine…
then
julia buildimg.jl
and go to lunch or get some coffee. It takes like 10 mins to build on my machine.
If you have additional packages you’d like to include and additional functionality you’d like to exercise before the build, then add the packages to the buildimg.jl file package list, and edit the dataanalys.jl “exerciser” file.
You can install the command juliadata which is a shell script, edit the path to your sysimage in that file before copying it to your ~/bin/ directory then you can run
juliadata ....
and it’ll work just like julia except with your precompiled packages.
If you don’t have the packages installed in the “root environment” then you’ll get warnings that seem to be inconsequential when you start it up. It all seems to work fine though.
All this tested on Linux, but not Windows or Mac.