nh2 / static-haskell-nix

easily build most Haskell programs into fully static Linux executables
388 stars 36 forks source link

Update pinned nixpgks #121

Closed teggotic closed 1 month ago

teggotic commented 10 months ago

I've tried to update pinned nixpkgs by rebasing @nh2 's commits to the latest master branch (as of 2023-09-16).

https://github.com/teggotic/nixpkgs/tree/static-haskell

teggotic commented 10 months ago

Hey @nh2, how do I really verify/test that this really works.

I'm working on a tool, which now can be built with static version ghc946.

nh2 commented 10 months ago

@teggotic

how do I really verify/test that this really works.

Build nix-build --no-link survey/default.nix -A working and -A workingStackageExecutables (defined here). I generally add the ones that fail to that exclusion list, so that workingStackageExecutables produces build errors.

You also have to update this:

https://github.com/nh2/static-haskell-nix/blob/88f1e2d57e3f4cd6d980eb3d8f99d5e60040ad54/survey/default.nix#L24-L37

if the GHC version changes (e.g. if the nixpkgs default ghc changes from ghc927 to ghc928).

static-haskell-nix's master branch is generally based on the latest stable nixpkgs release. Given that this updates to nixpkgs master, we'd keep the PR open for now until that becomes NixOS 23.11, and then merge it.

Meanwhile, people who want to base on NixOS master can use the pin from this PR.


Ideally you would also update this line to the same commit as pinned by your submodule update: https://github.com/nh2/static-haskell-nix/blob/88f1e2d57e3f4cd6d980eb3d8f99d5e60040ad54/nixpkgs.nix#L29