-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Segfault during configuring #41
Comments
@nnmm Maybe benz0li/ghc-musl#1 (comment) and the following posts have the answer you are looking for. |
IMHO @nnmm See also jgm/pandoc#9068 for a similar case. |
@benz0li Thanks for your comment. I don't think I'm doing anything all that different from what is suggested in these threads. I've uploaded a minimal reproducer here: https://github.com/nnmm/stack-musl-repro - I've also tried using a |
On a host with docker installed docker run --rm -ti glcr.b-data.ch/ghc/ghc-musl:9.8.2 bash Inside the container cd /var/tmp/ \
&& git clone https://github.com/nnmm/stack-musl-repro.git \
&& cd stack-musl-repro \
&& cabal build \
&& file /var/tmp/stack-musl-repro/dist-newstyle/build/x86_64-linux/ghc-9.8.2/repro-0.1.0.0/x/repro/build/repro/repro output:
👉 |
You may try the following flags: {}
packages:
- '.'
resolver: lts-22.7
# This enables static linking, so that there are no libc problems with the Debian server
docker:
enable: true
image: quay.io/benz0li/ghc-musl:9.6.4 |
@benz0li That works, thanks so much! Seems like the conclusion is that I should have been looking at https://github.com/benz0li/ghc-musl instead of this repo :) |
That is, the configuring error is gone - there is still a linker error. But I can create a separate issue for that if needed. |
@nnmm You may create an issue at https://github.com/benz0li/ghc-musl. If possible: Use a Dev Container so it can be easily reproduced. |
I have enabled the ghc-musl container in my
stack.yaml
like so:The resolver is
lts-21.16
, which I think should be compatible.In the cabal file, I've added
as recommended by this comment.
However, when running
stack build
, every build process exits with code -11 (segfault).Is there something I should do differently?
Full build output
``` ➜ stack build --ghc-options ' -static -optl-static -optl-pthread -fPIC' --no-nix OneTuple > configure Only > configure StateVar > configure appar > configure Progress 4/208
Error: [S-7282]
Stack failed to execute the build
plan.
The text was updated successfully, but these errors were encountered: