On Monday, 26 March 2018 at 10:01:38 UTC, Nordlöw wrote:
On Sunday, 25 March 2018 at 20:35:01 UTC, Seb wrote:
For building everything locally, it should be as easy as:
---
git clone https://github.com/dlang/dmd
git clone https://github.com/dlang/druntime
git clone https://github.com/dlang/phobos
cd phobos && make -f posix.mak -j10
How do I build a release-inline-nobounds build with ldc? I want
to set
- DC=ldmd2,
- ENABLE_RELEASE=1
when building dmd.
BTW there's also this setup script:
https://github.com/dlang/tools/blob/master/setup.sh
Thanks.
1) With LDC
------------
make -f posix.mak HOST_DMD=ldmd (or ldmd2 - depending on your
distro)
2) Release mode params
-----------------------
It's defined here:
https://github.com/dlang/dmd/blob/master/src/posix.mak#L242
It doesn't add -noboundscheck by default.
Typically the Makefiles allow passing an initial DFLAG variable,
but that one doesn't seem to allow it, so I just submitted a PR
to do so (https://github.com/dlang/dmd/pull/8089).
With this PR you can do:
make -f posix.mak HOST_DMD=ldmd ENABLE_RELEASE=1
DFLAGS="-noboundscheck"
You might want to give ENABLE_LTO a try too.