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

nethack: nethack-x11 package created #42766

Merged
merged 1 commit into from Jun 30, 2018
Merged

nethack: nethack-x11 package created #42766

merged 1 commit into from Jun 30, 2018

Conversation

ghost
Copy link

@ghost ghost commented Jun 29, 2018

If x11Mode is false, ncurses NetHack version will be built (nethack).
If x11Mode is true, x11 NetHack version will be built (nethack-x11).
NetHack DevTeam provide x11 version support only for Linux.

Motivation for this change

To play a graphical version of NetHack on NixOS.

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)
  • Fits CONTRIBUTING.md.

/cc @abbradar

@@ -19568,6 +19568,10 @@ with pkgs;

nethack = callPackage ../games/nethack { };

nethack-x11 = nethack.override {
Copy link
Member

Choose a reason for hiding this comment

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

Is it okay to leave this out? I much prefer to have users set up these kind of overrides in their configs. You can definitely add documentation to the Nixpkgs manual if you think it needs to be more disoverable.

Copy link
Author

@ghost ghost Jun 29, 2018

Choose a reason for hiding this comment

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

I don't know how correct my approach is, but I used the crawlTiles and crawl packages as a sample. Everything is done exactly the same way there.

What would you suggest to do in this case? Basically, I could make a separate nix expression for the x11 version and maintain it separately.

Copy link
Member

Choose a reason for hiding this comment

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

No - I definitely think it's good to reuse the nethack expression - I just don't want it to go in all-packages.nix.

Copy link
Author

Choose a reason for hiding this comment

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

@matthewbauer

nethack-x11 = callPackage ../games/nethack { x11Mode = true; };

Perhaps it would be better?

Copy link
Author

Choose a reason for hiding this comment

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

I've made some changes.

If x11Mode is false, ncurses NetHack version will be built (nethack).
If x11Mode is true, x11 NetHack version will be built (nethack-x11).
NetHack DevTeam provide x11 version support only for Linux.
@matthewbauer matthewbauer merged commit bdb0b2d into NixOS:master Jun 30, 2018
@ghost
Copy link
Author

ghost commented Jul 2, 2018

Thanks!

@ghost ghost mentioned this pull request Aug 11, 2018
9 tasks
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

2 participants