Skip to content
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

Fix fourmolu with -f-fixity-th in nix env #3400

Merged
merged 3 commits into from
Dec 16, 2022

Conversation

wavewave
Copy link
Contributor

on current master, .#haskell-language-server-925-dev-nix shell is broken.

% nix develop .#haskell-language-server-925-dev-nix
warning: Using saved setting for 'extra-substituters = https://haskell-language-server.cachix.org' from ~/.local/share/nix/trusted-settings.json.
warning: Using saved setting for 'extra-trusted-public-keys = haskell-language-server.cachix.org-1:juFfHrwkOxqIOZShtC4YC1uT1bBcq2RSvC7OMKx0Nz8=' from ~/.local/share/nix/trusted-settings.json.
[1/44/249 built, 3 copied (1489.5 MiB), 127.6 MiB DL] building HsYAML-0.2.1.1 (buildPhase): [ 4 of 14] Compiling Data.YAML.Token  ( src/Derror: interrupted by the user
ianwookim@IANWOOs-MacBook-Pro haskell-language-server % nix develop -j auto .#haskell-language-server-925-dev-nix
warning: Using saved setting for 'extra-substituters = https://haskell-language-server.cachix.org' from ~/.local/share/nix/trusted-settings.json.
warning: Using saved setting for 'extra-trusted-public-keys = haskell-language-server.cachix.org-1:juFfHrwkOxqIOZShtC4YC1uT1bBcq2RSvC7OMKx0Nz8=' from ~/.local/share/nix/trusted-settings.json.
[5/191/205 built] building ghc-lib-parser-9.2.4.20220729 (buildPhase): [330 of 333] Compiling GHC.Tc.Erro[1/202/205 built] building fourmolu-0.9.0.0 (buildPhase): [ 5 of 55] Compiling Ormolu.Fixity    ( serror: builder for '/nix/store/36r7hcfph5f8xn2vcs0sn5s2rba5vjly-fourmolu-0.9.0.0.drv' failed with exit code 1;
       last 10 log lines:
       > [54 of 55] Compiling Ormolu.Utils.Fixity ( src/Ormolu/Utils/Fixity.hs, dist/build/Ormolu/Utils/Fixity.o, dist/build/Ormolu/Utils/Fixity.dyn_o )
       > [55 of 55] Compiling Ormolu           ( src/Ormolu.hs, dist/build/Ormolu.o, dist/build/Ormolu.dyn_o )
       > Preprocessing executable 'fourmolu' for fourmolu-0.9.0.0..
       > Building executable 'fourmolu' for fourmolu-0.9.0.0..
       > [1 of 2] Compiling Paths_fourmolu   ( dist/build/fourmolu/autogen/Paths_fourmolu.hs, dist/build/fourmolu/fourmolu-tmp/Paths_fourmolu.o, dist/build/fourmolu/fourmolu-tmp/Paths_fourmolu.dyn_o )
       > [2 of 2] Compiling Main             ( app/Main.hs, dist/build/fourmolu/fourmolu-tmp/Main.o, dist/build/fourmolu/fourmolu-tmp/Main.dyn_o )
       > Linking dist/build/fourmolu/fourmolu ...
       > /nix/store/v069wkyb6y6qw2bhpzag5kka19j7clgg-clang-wrapper-11.1.0/bin/ld: line 256: 74868 Segmentation fault: 11  /nix/store/lyjnk6a0hi0d6favfz7vvj1dg8f1sqgq-cctools-binutils-darwin-973.0.1/bin/ld ${extraBefore+"${extraBefore[@]}"} ${params+"${params[@]}"} ${extraAfter+"${extraAfter[@]}"}
       > clang-11: error: linker command failed with exit code 139 (use -v to see invocation)
       > `cc' failed in phase `Linker'. (Exit code: 139)
       For full logs, run 'nix log /nix/store/36r7hcfph5f8xn2vcs0sn5s2rba5vjly-fourmolu-0.9.0.0.drv'.
error: 1 dependencies of derivation '/nix/store/51jz1h324rkrdgwa9siim1p8vlqiq4y3-ghc-9.2.5-with-packages.drv' failed to build
error: 1 dependencies of derivation '/nix/store/51f5mynbnc9sz7knrlr6qz1rz7vqlrmw-haskell-language-server-dev-nix-ghc9.2.5-env.drv' failed to build

This fixes the issue.

Copy link
Collaborator

@fendor fendor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wavewave wavewave mentioned this pull request Dec 16, 2022
@michaelpj
Copy link
Collaborator

Please include a comment explaining why the workaround is there so that future us will know when to remove it.

@wavewave
Copy link
Contributor Author

@michaelpj Added a small comment with a link to the issue. Thanks!

@michaelpj michaelpj added the merge me Label to trigger pull request merge label Dec 16, 2022
@mergify mergify bot merged commit a235ec9 into haskell:master Dec 16, 2022
@wavewave wavewave deleted the wavewave/fourmolu-fix branch December 19, 2022 17:48
@georgefst
Copy link
Collaborator

Just saw this. Makes sense, but note that the flag has now been totally removed: tweag/ormolu#954.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge me Label to trigger pull request merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants