# Is it normal for juliac to still produce 280 MB of libraries for a "println" example?

**URL:** <https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140>\
**Category:** General Usage\
**Tags:** juliac, trim, trimming\
**Created:** [October 14, 2025, 2:06pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140 "2025-10-14T14:06:33Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [October 14, 2025, 2:06pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/1 "2025-10-14T14:06:33Z")

</div>

Sorry, possibly coming from an “over-expectations” mind setting… I had a quick try on [juliac](https://github.com/JuliaLang/JuliaC.jl), but compiling the trivial example, even with `--trim=safe`, produces yes an executable of ~1.7 MB, but also a set of libraries ~ 280MB.  
Is this the expected outcome, or am I doing something wrong ?

---

<div class="post-metadata">

**Author:** ![GunnarFarneback](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gunnarfarneback/32/1827_2.png) [@GunnarFarneback](https://discourse.julialang.org/u/GunnarFarneback)\
**Post date:** [October 14, 2025, 2:16pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/2 "2025-10-14T14:16:42Z")

</div>

That’s still normal, as far as I understand, although there is likely potential to trim the set of libraries as well.

Edit: The latter was based on relatively old experiments with juliac. When I try now with 1.12.0 on Linux I get a 1.7 MB binary and 92 MB of libraries.

---

<div class="post-metadata">

**Author:** ![LeePhillips](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/leephillips/32/205514_2.png) [@LeePhillips](https://discourse.julialang.org/u/LeePhillips)\
**Post date:** [October 14, 2025, 10:11pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/3 "2025-10-14T22:11:05Z")

</div>

When I compile a Hello World on Linux with v1.12.0 I get 1 1.6MB binary and 313MB of libraries.

EDIT: I just compiled another small program and got 91MB of libraries. Don’t know why I saw 313MB before.

---

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [October 15, 2025, 1:03pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/4 "2025-10-15T13:03:11Z")

</div>

It seems you don’t get the “full” size when you run juliac multiple times.

I run juliac on Julia v1.12.0 on the [AppProject](https://github.com/JuliaLang/JuliaC.jl/tree/main/test/AppProject) in the juliac repository:

`~/.julia/bin/juliac --output-exe app_test_exe --project AppProject --bundle build --trim=safe --experimental --verbose AppProject/src/test.jl`

If I run it once, I get “Total library file size: 272.985 MiB”, that is consistent with what I actually get on disk, but if I run it a second time I have “Total library file size: 182.938 MiB” that seems to consider only a subset of the base libraries, but the libraries on disk are still 280MB.

---

<div class="post-metadata">

**Author:** ![GunnarFarneback](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gunnarfarneback/32/1827_2.png) [@GunnarFarneback](https://discourse.julialang.org/u/GunnarFarneback)\
**Post date:** [October 15, 2025, 1:37pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/5 "2025-10-15T13:37:44Z")

</div>

I never figured how the “Total library file size” information related to anything and only measured what I actually had on disk.

---

<div class="post-metadata">

**Author:** ![affans](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/affans/32/11911_2.png) [@affans](https://discourse.julialang.org/u/affans)\
**Post date:** [October 15, 2025, 4:04pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/6 "2025-10-15T16:04:26Z")

</div>

These libraries might often already exist on a Linux system. In that case, does `juliac` link to the existing libraries or still bundle its own? I am guessing the latter, given Julia likes to be as self-contained as possible.

---

<div class="post-metadata">

**Author:** ![gbaraldi](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gbaraldi/32/22101_2.png) [@gbaraldi](https://discourse.julialang.org/u/gbaraldi)\
**Post date:** [October 15, 2025, 7:26pm UTC](https://discourse.julialang.org/t/is-it-normal-for-juliac-to-still-produce-280-mb-of-libraries-for-a-println-example/133140/7 "2025-10-15T19:26:36Z")

</div>

The printing it does is currently not great :). So I would use du or similar to measure the actual disk space.
