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

Add Nix #22459

Open
5 tasks done
Ericson2314 opened this issue Nov 8, 2024 · 9 comments · May be fixed by #22499
Open
5 tasks done

Add Nix #22459

Ericson2314 opened this issue Nov 8, 2024 · 9 comments · May be fixed by #22499

Comments

@Ericson2314
Copy link
Contributor

Ericson2314 commented Nov 8, 2024

Package name

Nix

Brief description of package

Nix, the purely functional package manager.

Nix has a Windows port in progress, which I am involved with. It is not yet feature-complete, but it does build. We understand if packaging software that isn't yet useful is putting the cart before the horse, but we would love to better do native builds of Nix while we finish the port, and also learn a bit more about MSYS / toolchain setups in the process.

Once we're far enough to be attempting to build Nixpkgs on Windows natively with Cygwin/MSYS, we'll also need to learn a lot from you all in general. (See NixOS/nixpkgs#354137 for the first steps on that.) So consider this a hybrid packaging requestion / general knowledge sharing and collaboration request.

(And of course, if someday you all want to ditch pacman for nix, we won't complain :))

URL for package's homepage

Repo: https://github.com/nixos/nix

Chat for Port: https://matrix.to/#/#windows:nixos.org

Provide a basic test case to validate the package's functionality.

We have unit tests for the libraries that run, and some in-progress work to run the shell-script-based integration tests.

MINGW environments where you need the package

  • MINGW64
  • MINGW32
  • UCRT64
  • CLANG64
  • CLANGARM64

Are you willing to submit a PR?

I think one of us porting Nix to Windows could do it but we would need hand-holding. Ideally one of you could drive the PR, and we would be highly available to answer questions.

@lazka
Copy link
Member

lazka commented Nov 8, 2024

Would nix (as in the tool) target the Windows APIs via C++, or is this a cygwin port? Just to be sure.. :)

@Ericson2314
Copy link
Contributor Author

@lazka No Cygwin! 🎉 We're cross building from Linux with MinGW now, and a previous version of the port (nix-windows/nix@windows) in fact got things building with MSVC.

The newish C++ filesystem library helps a lot, here :)

@puffnfresh
Copy link
Contributor

puffnfresh commented Nov 10, 2024

I'll take this on, since I've got an automated build of Nix using mingw64. There are two dependencies missing:

@Kreijstal
Copy link
Contributor

@lazka No Cygwin! 🎉 We're cross building from Linux with MinGW now, and a previous version of the port (nix-windows/nix@windows) in fact got things building with MSVC.

The newish C++ filesystem library helps a lot, here :)

there are many programs still depending on autotools.. it would've be certainly easier if it was cygwin based. (Would support more from source built software as it is right now) But maybe there is less dependency on it than before.. We will see.

@Kreijstal
Copy link
Contributor

@lazka No Cygwin! 🎉 We're cross building from Linux with MinGW now, and a previous version of the port (nix-windows/nix@windows) in fact got things building with MSVC.
The newish C++ filesystem library helps a lot, here :)

there are many programs still depending on autotools.. it would've be certainly easier if it was cygwin based. (Would support more from source built software as it is right now) But maybe there is less dependency on it than before.. We will see.

Pd: maybe with nix, I can finally get guix :)

@lazka
Copy link
Member

lazka commented Nov 11, 2024

We've updated libgit2 now in #20396. In theory we could backport things if needed there.

@Ericson2314
Copy link
Contributor Author

@lazka Yeah if you would be open to a patch, I think it is a pretty non-invasive change. https://github.com/libgit2/libgit2/compare/v1.8.4..main/#diff-069ad7b34be69df5ba08a066f481b6d5b5f473894137065f33eebfc2a7722442 shows it is not yet landed in that patch release. I'll see what I can do if @puffnfresh doesn't beat me to it :).

lazka added a commit to lazka/MINGW-packages that referenced this issue Nov 11, 2024
@lazka
Copy link
Member

lazka commented Nov 11, 2024

#22492

@Ericson2314
Copy link
Contributor Author

Wonderful! Really appreciate that @lazka :)

lazka added a commit that referenced this issue Nov 11, 2024
@puffnfresh puffnfresh linked a pull request Nov 12, 2024 that will close this issue
ognevny pushed a commit to ognevny/MINGW-packages that referenced this issue Nov 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants