dlang-tour / core

D Language online tour (https://tour.dlang.org/) and online editor (https://run.dlang.io/)
Boost Software License 1.0
119 stars 48 forks source link

[---] Build docker executable with musl libc. #751

Open looked-at-me opened 4 years ago

looked-at-me commented 4 years ago

The issue with gist not working seems to be related to a bug in glibc when it is used as a static library in a static executable. Possibly something related to the shared binaries not being able to access TLS of the executable. Found a few issues related to this, that were years old. Don't imagine using glibc as a static library is high on their list.

This should work now, this needs the regression in vibe-d fixed first though as it uses a newer ldc2, which is required for musl libc support.

Bit messy to build, the dockerfile will be much simpler if LDC2 starts releasing musl libc builds again.

Also not 100% on the tracis script, so WIP for now to test..

Geod24 commented 4 years ago

@Cogitri and myself maintain the Alpine packages. If you use alpine:edge, you have gdc in main, dub, ldc, and rdmd in community, and dmd in testing. The 3.12 release shouldn't be too far either. That should save you a lot of time.

looked-at-me commented 4 years ago

Got called back into work, has been a bit hectic. I'll see if I can get this building now.

@Geod24 How often do you update the packages? Is it a lot of work to maintain? Could be automated when LDC2 does a release? Preferably it would be nice to be able to select a specific version of LDC2.

looked-at-me commented 4 years ago

Alright looks to be good to go?

Geod24 commented 4 years ago

@Geod24 How often do you update the packages? Is it a lot of work to maintain? Could be automated when LDC2 does a release? Preferably it would be nice to be able to select a specific version of LDC2.

It is fairly trivial to do, except that there are still some quirks (read: bugs) to be worked out. There's quite a few things that could be automated, not only on the Alpine side, but also other package managers (e.g. Homebrew, Nix...).

looked-at-me commented 4 years ago

@wilzbach Any ETA on when this will be merged? Github links are still broken, though for a different reason than you mentioned. Right now it's crashing due to a bug in glibc with local thread variables not being accessible as the binary doesn't have a dynamic table for lookup for by the dynamic glibc library that is still loaded dynamically.

looked-at-me commented 4 years ago

@wilzbach Plonk. Is there someone else I can ping?

Geod24 commented 4 years ago

@looked-at-me : This is still listed as a WIP tho

ljmf00 commented 3 years ago

@looked-at-me @Geod24 what's the state of this?