Vala: reducing dependency size

I am developing small command line utilities using Vala on win32. Programs compiled using vala depend on the following DLLs

  • libgobject-2.0-0.dll
  • libgthread-2.0-0.dll
  • libglib-2.0-0.dll

They occupy 1,500 kilobytes of space. Is there a way to reduce the size of these dependencies (in addition to compressing them using UPX, etc.)? I can not imagine simple helloworld as an application, using all the functions provided by glib.

Thanks!

+7
source share
1 answer

If your vala source is pretty simple, you can compile it in a posix profile

valac --profile posix hello.vala 

Then your binary will not have any dependency outside the C standard library. However, the posix profile may be experimental.

+9
source

All Articles