Re: How to prepare and generate a simple lightweight binary?

2019-06-25 Thread kinke via Digitalmars-d-learn
On Tuesday, 25 June 2019 at 13:13:34 UTC, BoQsc wrote: What I would expect: A simple executable program that does a writeln and do not weight tons of megabytes. Thanks. void main() { import std.stdio; writeln("Hello world!"); } Ubuntu 18.04, LDC v1.16: ldc2 hello.d => ~1.7 MB ldc2

How to prepare and generate a simple lightweight binary?

2019-06-25 Thread BoQsc via Digitalmars-d-learn
There are lots of talks on this forum about Statical linking, Dynamic linking. There are even shouts: "use the ldc compiler instead, it can do all that and even more than the default dmd compiler!!!" and bunch of compiler flags, no instructions on how to start or even steps on how to reproduce