D for microservices
Joakim
dlang at joakim.fea.st
Sat Feb 24 10:03:07 UTC 2018
On Thursday, 22 February 2018 at 21:59:27 UTC, aberba wrote:
> On Thursday, 22 February 2018 at 08:54:04 UTC, Joakim wrote:
>> On Monday, 23 October 2017 at 18:18:28 UTC, Jacob Carlborg
>> wrote:
>>> [...]
>>
>> Yuxuan Shui has ported druntime to Musl over the last couple
>> months:
>>
>> https://github.com/dlang/druntime/pulls?q=is%3Apr+author%3Ayshui+is%3Aclosed
>>
>> With his changes, all druntime unit tests pass, now only a few
>> asserts tripping in the additional tests for shared libraries.
>> I added a couple more tweaks to get all but one of the Phobos
>> unit tests passing too.
>>
>> With a last tiny patch to add a command-line flag to dmd to
>> easily use this port- already added to the latest ldc 1.8
>> beta, though it doesn't have all the druntime support:
>> https://github.com/ldc-developers/ldc/pull/2373 - anyone can
>> use D with Alpine/Musl containers for microservices.
>
> That makes me very happy!! Very much appreciated.
I've updated ldc master to use Yuxuan's druntime port, which
means the upcoming ldc 1.8 release will likely be a viable
Alpine/Musl cross-compiler out of the box, provided you give it a
C/Musl cross-compiler/linker to work with, by using the bundled
ldc-build-runtime tool:
https://wiki.dlang.org/Building_LDC_runtime_libraries
Cross-compiling has not been tested however: do people normally
cross-compile to Alpine containers or build their software in
Alpine itself? If the latter, building ldc from master on
Alpine/x64 3.7.0 passes all of the druntime/phobos stdlib unit
tests but one, so you're good to go there, as long as you don't
need a pre-built binary. Maybe we'll put one out for ldc with the
upcoming 1.8 release.
More information about the Digitalmars-d
mailing list