PackageCompiler - reduce system image

After building some system images (which takes a lot of time), here is what works for me :

  • sysimage_build_args = --strip-metadata this produce the smallest system image for me (225MB)
  • sysimage_build_args = --compile=all --strip-metadata --strip-ir produce 297MB, --compile=all is important otherwise it does not work.
  • sysimage_build_args = --compile=all --strip-metadata --strip-ir + filter_stdlibs=true + incremental=false produce 266MB.

Thank you for your help on this.

2 Likes