Skip to content

Revamp nix flake for nix-tools #2010

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

Merged
merged 42 commits into from
Aug 17, 2023
Merged

Revamp nix flake for nix-tools #2010

merged 42 commits into from
Aug 17, 2023

Conversation

andreabedini
Copy link
Member

This PR revamps the nix-tools flake and adds a binary tarball with static builds (for now only on x86_64-linux).

We already have a Hydra jobset monitoring the nix-tools (sub?)flake, refreshing every hour:
https://ci.zw3rk.com/jobset/input-output-hk-haskell-nix/nix-tools

I did a brief test of Haskell.nix with this branch and it seems ok. Let's see what the main CI says.

@andreabedini
Copy link
Member Author

Integration with Haskell.nix still to do.

@angerman
Copy link
Collaborator

angerman commented Aug 1, 2023

We should also try to compile some perf metrics. With/without; hot/cold.

@andreabedini andreabedini self-assigned this Aug 1, 2023
@andreabedini
Copy link
Member Author

andreabedini commented Aug 1, 2023

@hamishmack what's the role of nix-tools/nix/hix.nix? is it needed? nix-tools is loaded in haskell.nix as a hix project.

@hamishmack
Copy link
Collaborator

You can remove nix/hix.nix (it does not look like we will need to pass any project args). If we were passing modules for something then we would want to keep it to make the hix commands see that.

@hamishmack
Copy link
Collaborator

nix-tools is loaded in haskell.nix as a hix project.

Will that be replaced with the derivations to download the static nix-tools?

@andreabedini
Copy link
Member Author

I am going to include the required changes in haskell.nix in this PR.

@andreabedini andreabedini marked this pull request as draft August 1, 2023 10:28
@michaelpj
Copy link
Collaborator

Am I missing the motivation here? The tarball will still need to be built by haskell.nix, so won't we still have the same build-time work to do?

@andreabedini
Copy link
Member Author

Will that be replaced with the derivations to download the static nix-tools?

@hamishmack The plan would be for haskell.nix optionally download a static build of nix-tools rather that bulding it as part of the bootstrap process. We can then asses whether this helps (e.g. with adding a new version of GHC).

Am I missing the motivation here? The tarball will still need to be built by haskell.nix, so won't we still have the same build-time work to do?

The tarball will still need to be built by haskell.nix that's correct. The difference is that, having its own flake, it can be built separately. I hope this can simplify (and shorten) the bootstrap process.

@hamishmack hamishmack marked this pull request as ready for review August 17, 2023 04:40
@hamishmack hamishmack changed the title Revamp nix flake for nix-tools, including static builds Revamp nix flake for nix-tools Aug 17, 2023
@hamishmack hamishmack merged commit 0ad4dcb into master Aug 17, 2023
@andreabedini andreabedini deleted the static-nix-tools branch August 17, 2023 06:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants