# PackageCompiler - reduce system image

**URL:** <https://discourse.julialang.org/t/packagecompiler-reduce-system-image/97952>\
**Category:** New to Julia\
**Tags:** question\
**Created:** [April 26, 2023, 2:48pm UTC](https://discourse.julialang.org/t/packagecompiler-reduce-system-image/97952 "2023-04-26T14:48:09Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![gitboy16](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gitboy16/32/24906_2.png) [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Post date:** [April 27, 2023, 8:29am UTC](https://discourse.julialang.org/t/packagecompiler-reduce-system-image/97952/6 "2023-04-27T08:29:46Z")

</div>

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.

---

_[View the full topic](https://discourse.julialang.org/t/packagecompiler-reduce-system-image/97952)._
