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

Introduce the primesieve package #55196

Merged
merged 2 commits into from Feb 4, 2019
Merged

Introduce the primesieve package #55196

merged 2 commits into from Feb 4, 2019

Conversation

guibou
Copy link
Contributor

@guibou guibou commented Feb 4, 2019

Motivation for this change

primesieve contains an efficient C++ library to generate prime numbers.
That's also a dependency of the haskellPackages.primesieve haskell binding which was not building due to the absence of primesieve from nixpkgs.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Copy link
Member

@peti peti left a comment

Choose a reason for hiding this comment

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

Please do not edit hackage-packages.nix. Note the comment at the very top of the file.

pkgs/development/haskell-modules/configuration-common.nix Outdated Show resolved Hide resolved
@guibou
Copy link
Contributor Author

guibou commented Feb 4, 2019

@peti sorry for the missing patch, I'll push the fix with the fetchpatch command instead.

About hackage-packages.nix, my fix is temporary because it will be correctly (I assumed) overrode by the next update to hackage-packages.nix. Should I add a fix in configuration-common.nix which may become outdated really soon (next hackage-packages.nix) or should I add nothing and wait for the next hackage-packages.nix to fix itself?

Temporaries changes in `configuration-common.nix` to fix the cabal
file which does not specify that the haskell library depends on the
C++ shared library. Pull request had been sent upstream.
@peti
Copy link
Member

peti commented Feb 4, 2019

@GrahamcOfBorg build primesieve

@peti
Copy link
Member

peti commented Feb 4, 2019

Should I add nothing and wait for the next hackage-packages.nix to fix itself?

Yes, I think that is the way to go. The problem with manually editing hackage-packages.nix is that you don't know whether our automatic process will actually produce a working version of the build once it's been run. The only way to know that for sure is to create the patch by running hackage2nix locally to generate the modifications.

@peti peti merged commit 790e14c into NixOS:master Feb 4, 2019
@guibou guibou deleted the primesieve branch February 4, 2019 13:34
@peti
Copy link
Member

peti commented Feb 4, 2019

The build now works in 4974e85.

@guibou
Copy link
Contributor Author

guibou commented Feb 4, 2019

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants