Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 434a0111f6a7
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: cf64230d42ba
Choose a head ref

Commits on Apr 21, 2020

  1. Copy the full SHA
    8a061eb View commit details

Commits on May 24, 2020

  1. Copy the full SHA
    435340e View commit details

Commits on May 25, 2020

  1. nixos/hidpi: init

    Mic92 committed May 25, 2020
    Copy the full SHA
    2fb5a99 View commit details
  2. nixos/installer: suggest to load v32n instead if i32n

    v32n has more characters.
    Mic92 committed May 25, 2020
    Copy the full SHA
    b6a1dc5 View commit details

Commits on Jul 13, 2020

  1. rpackages.RcppParallel: Patch shebang

    Fixes hydra build error
    cfhammill committed Jul 13, 2020
    Copy the full SHA
    3c503aa View commit details

Commits on Jul 14, 2020

  1. Copy the full SHA
    3d86666 View commit details

Commits on Jul 18, 2020

  1. Copy the full SHA
    3f9b85e View commit details
  2. Copy the full SHA
    d6863de View commit details
  3. cataclysm-dda{,-git}: apply locale patch dynamically

    Each time src/translations.cpp is modified, we have to update the locale
    patch. Using sed to patch dynamically should be handy.
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    bf71f12 View commit details
  4. cataclysmDDA: add very basic framework for packaging mods

    Add new namespace 'cataclysmDDA', in which package builders, games, and
    mods are listed.
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    ac85554 View commit details
  5. Copy the full SHA
    bc88844 View commit details
  6. cataclysmDDA: make pkgs extensible

    Example:
    
    let
      customMods = self: super: lib.recursiveUpdate super {
        soundpack.AwesomeSounds = cataclysmDDA.buildSoundPack { ... };
      };
    in
    cataclysm-dda.withMods (mods: with mods.extend customMods; [
      tileset.UndeadPeople
      soundpack.AwesomeSounds
    ])
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    90c2652 View commit details
  7. Copy the full SHA
    de56294 View commit details
  8. Copy the full SHA
    ecf7b57 View commit details
  9. cataclysm-dda-git: make it overridable with git revision

    'cataclysm-dda-git.overrideAttrs (_: { version = ...; src = fetchFromGitHub { ... }; })'
    did not update VERSION make flag correctly.
    
    With this change, one can override 'cataclysm-dda-git' correctly and
    more easily:
    
    cataclysm-dda-git.override { version = ...; rev = ...; sha256 = ...; }
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    633f211 View commit details
  10. cataclysmDDA: add README

    mnacamura committed Jul 18, 2020
    Copy the full SHA
    d472eed View commit details
  11. Copy the full SHA
    bbe7b86 View commit details
  12. cataclysmDDA: update README

    Add description about `useXdgDir` flag
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    fbf4b4f View commit details
  13. cataclysmDDA: update mods

    mnacamura committed Jul 18, 2020
    Copy the full SHA
    cf0e2d5 View commit details
  14. doc: fix MD_TARGETS

    globstar (**) does not work in Makefile
    mnacamura committed Jul 18, 2020
    Copy the full SHA
    c9c6f5f View commit details
  15. Copy the full SHA
    f2b2347 View commit details
  16. nixos/gitlab: Make redis URL configurable

    We run Redis via Unix socket
    dasJ committed Jul 18, 2020
    Copy the full SHA
    e9bf4ca View commit details
  17. Copy the full SHA
    d20efd5 View commit details

Commits on Jul 20, 2020

  1. vivaldi: remove gstreamer

    eadwu committed Jul 20, 2020
    Copy the full SHA
    75ef721 View commit details
  2. oneDNN: enable on darwin

    marsam committed Jul 20, 2020
    Copy the full SHA
    8f1c949 View commit details
  3. oneDNN: update homepage

    marsam committed Jul 20, 2020
    Copy the full SHA
    f02babb View commit details

Commits on Jul 21, 2020

  1. oneDNN: 1.5 -> 1.5.1

    marsam committed Jul 21, 2020
    Copy the full SHA
    a19f443 View commit details
  2. redox: add as target

    aaronjanse committed Jul 21, 2020
    Copy the full SHA
    60fd049 View commit details

Commits on Jul 22, 2020

  1. Copy the full SHA
    68f6620 View commit details
  2. Copy the full SHA
    d2c8395 View commit details
  3. Copy the full SHA
    1c36177 View commit details
  4. Copy the full SHA
    6a39b90 View commit details
  5. syncthing: 1.7.0 -> 1.7.1

    kraem committed Jul 22, 2020
    Copy the full SHA
    c5f730e View commit details
  6. monitor: 0.7.2 -> 0.8.1

    xiorcale committed Jul 22, 2020
    Copy the full SHA
    6ac9782 View commit details
  7. nixos/manual: add a section about Vulkan drivers

    - Add a general block about how to configure and test Vulkan
    - Add a section about switching between mesa/radv and amdvlk on AMD
      GPUs.
    Flakebi committed Jul 22, 2020
    Copy the full SHA
    350f1d6 View commit details
  8. moarvm: 2020.06 -> 2020.07

    stigtsp committed Jul 22, 2020
    Copy the full SHA
    54b6a81 View commit details
  9. nqp: 2020.06 -> 2020.07

    stigtsp committed Jul 22, 2020
    Copy the full SHA
    1c4041e View commit details
  10. rakudo: 2020.06 -> 2020.07

    stigtsp committed Jul 22, 2020
    Copy the full SHA
    62a5a71 View commit details
  11. Merge pull request #93152 from ttuegel/kde-applications-20.04.3

    kdeApplications: 20.04.1 -> 20.04.3
    ttuegel authored Jul 22, 2020
    Copy the full SHA
    8fad714 View commit details
  12. pytmx: 3.21.7 -> 3.22.0

    Next to the version bump, this fixes the test for Python 2.
    oxzi authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    17dfbf4 View commit details
  13. pythonPackages.flower: 0.9.4 -> 0.9.5

    lsix authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    1e597a5 View commit details
  14. python37Packages.mpv: 0.4.6 -> 0.4.7

    r-ryantm authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    1f709cf View commit details
  15. python3Packages.aioharmony: 0.2.3 -> 0.2.5

    Oro authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    ade1348 View commit details
  16. python3Packages.HAP-python: 2.8.1 -> 2.9.2

    Oro authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    dc848ce View commit details
  17. python37Packages.aioftp: 0.16.0 -> 0.16.1

    r-ryantm authored and FRidh committed Jul 22, 2020
    Copy the full SHA
    fa401f5 View commit details
  18. Copy the full SHA
    2e531d5 View commit details
  19. Merge pull request #93591 from Flakebi/vulkan-manual

    nixos/manual: add a section about Vulkan drivers
    danieldk authored Jul 22, 2020
    Copy the full SHA
    5226e6b View commit details
  20. Merge pull request #93639 from stigtsp/package/rakudo-2020.07

    rakudo: 2020.06 -> 2020.07
    danieldk authored Jul 22, 2020
    Copy the full SHA
    d9160f2 View commit details
  21. Copy the full SHA
    63fa363 View commit details
  22. newsflash: init at 1.0.1

    kira-bruneau authored and danieldk committed Jul 22, 2020
    Copy the full SHA
    eaf27b3 View commit details
Showing with 6,001 additions and 1,870 deletions.
  1. +1 −1 doc/Makefile
  2. +94 −0 doc/builders/packages/cataclysm-dda.section.md
  3. +1 −0 doc/builders/packages/index.xml
  4. +2 −0 lib/systems/default.nix
  5. +3 −0 lib/systems/doubles.nix
  6. +9 −0 lib/systems/examples.nix
  7. +2 −1 lib/systems/inspect.nix
  8. +3 −0 lib/systems/parse.nix
  9. +4 −3 lib/tests/systems.nix
  10. +90 −1 nixos/doc/manual/configuration/gpu-accel.xml
  11. +1 −1 nixos/doc/manual/installation/installing.xml
  12. +16 −0 nixos/modules/hardware/video/hidpi.nix
  13. +29 −0 nixos/modules/hardware/xpadneo.nix
  14. +2 −2 nixos/modules/installer/tools/nixos-generate-config.pl
  15. +2 −0 nixos/modules/module-list.nix
  16. +11 −11 nixos/modules/security/acme.nix
  17. +7 −1 nixos/modules/services/misc/gitlab.nix
  18. +1 −1 pkgs/applications/kde/fetch.sh
  19. +868 −868 pkgs/applications/kde/srcs.nix
  20. +2 −2 pkgs/applications/networking/browsers/vivaldi/default.nix
  21. +3,374 −0 pkgs/applications/networking/feedreaders/newsflash/cargo.lock.patch
  22. +80 −0 pkgs/applications/networking/feedreaders/newsflash/default.nix
  23. +10 −0 pkgs/applications/networking/feedreaders/newsflash/no-post-install.patch
  24. +3 −3 pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix
  25. +2 −2 pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix
  26. +2 −2 pkgs/applications/networking/syncthing/default.nix
  27. +2 −2 pkgs/applications/system/monitor/default.nix
  28. +9 −3 pkgs/applications/video/jellyfin-mpv-shim/default.nix
  29. +5 −1 pkgs/desktops/pantheon/apps/appcenter/default.nix
  30. +532 −520 pkgs/development/compilers/elm/packages/node-packages.nix
  31. +9 −4 pkgs/development/compilers/gcc/6/default.nix
  32. +1 −1 pkgs/development/compilers/rust/rustc.nix
  33. +2 −2 pkgs/development/interpreters/rakudo/default.nix
  34. +2 −2 pkgs/development/interpreters/rakudo/moarvm.nix
  35. +2 −2 pkgs/development/interpreters/rakudo/nqp.nix
  36. +6 −5 pkgs/development/libraries/oneDNN/default.nix
  37. +2 −9 pkgs/development/libraries/pipewire/default.nix
  38. +32 −0 pkgs/development/libraries/relibc/default.nix
  39. +21 −0 pkgs/development/ocaml-modules/tsort/default.nix
  40. +3 −2 pkgs/development/python-modules/HAP-python/default.nix
  41. +2 −2 pkgs/development/python-modules/aioftp/default.nix
  42. +2 −2 pkgs/development/python-modules/aioharmony/default.nix
  43. +26 −0 pkgs/development/python-modules/ci-info/default.nix
  44. +26 −0 pkgs/development/python-modules/ci-py/default.nix
  45. +3 −3 pkgs/development/python-modules/etelemetry/default.nix
  46. +2 −2 pkgs/development/python-modules/flask-sqlalchemy/default.nix
  47. +10 −9 pkgs/development/python-modules/flower/default.nix
  48. +2 −2 pkgs/development/python-modules/jellyfin-apiclient-python/default.nix
  49. +2 −2 pkgs/development/python-modules/mpv/default.nix
  50. +2 −1 pkgs/development/python-modules/nibabel/default.nix
  51. +2 −2 pkgs/development/python-modules/python-mpv-jsonipc/default.nix
  52. +4 −10 pkgs/development/python-modules/pytmx/default.nix
  53. +4 −0 pkgs/development/r-modules/default.nix
  54. +46 −26 pkgs/development/tools/poetry2nix/poetry2nix/default.nix
  55. +3 −1 pkgs/development/tools/poetry2nix/poetry2nix/lib.nix
  56. +1 −2 pkgs/development/tools/poetry2nix/poetry2nix/overrides.nix
  57. +176 −144 pkgs/development/tools/poetry2nix/poetry2nix/pkgs/poetry/poetry.lock
  58. +1 −1 pkgs/development/tools/poetry2nix/poetry2nix/pkgs/poetry/pyproject.toml
  59. +2 −2 pkgs/development/tools/poetry2nix/poetry2nix/pkgs/poetry/src.json
  60. +2 −2 pkgs/development/web/nodejs/v10.nix
  61. +2 −2 pkgs/development/web/nodejs/v12.nix
  62. +0 −13 pkgs/development/web/nodejs/v13.nix
  63. +2 −2 pkgs/development/web/nodejs/v14.nix
  64. +49 −0 pkgs/games/cataclysm-dda/builder.nix
  65. +95 −92 pkgs/games/cataclysm-dda/common.nix
  66. +34 −17 pkgs/games/cataclysm-dda/default.nix
  67. +31 −23 pkgs/games/cataclysm-dda/git.nix
  68. +17 −0 pkgs/games/cataclysm-dda/lib.nix
  69. +0 −18 pkgs/games/cataclysm-dda/patches/fix_locale_dir.patch
  70. +0 −20 pkgs/games/cataclysm-dda/patches/fix_locale_dir_git.patch
  71. +27 −0 pkgs/games/cataclysm-dda/pkgs/default.nix
  72. +23 −0 pkgs/games/cataclysm-dda/pkgs/tilesets/UndeadPeople/default.nix
  73. +34 −0 pkgs/games/cataclysm-dda/stable.nix
  74. +47 −0 pkgs/games/cataclysm-dda/wrapper.nix
  75. +37 −0 pkgs/os-specific/linux/xpadneo/default.nix
  76. +2 −2 pkgs/stdenv/cross/default.nix
  77. +23 −14 pkgs/top-level/all-packages.nix
  78. +2 −0 pkgs/top-level/ocaml-packages.nix
  79. +5 −0 pkgs/top-level/perl-packages.nix
  80. +6 −2 pkgs/top-level/python-packages.nix
2 changes: 1 addition & 1 deletion doc/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
MD_TARGETS=$(addsuffix .xml, $(basename $(wildcard ./*.md ./**/*.md)))
MD_TARGETS=$(addsuffix .xml, $(basename $(shell find . -type f -regex '.*\.md$$')))

.PHONY: all
all: validate format out/html/index.html out/epub/manual.epub
94 changes: 94 additions & 0 deletions doc/builders/packages/cataclysm-dda.section.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
# Cataclysm: Dark Days Ahead

## How to install Cataclysm DDA

To install the latest stable release of Cataclysm DDA to your profile, execute
`nix-env -f "<nixpkgs>" -iA cataclysm-dda`. For the curses build (build
without tiles), install `cataclysmDDA.stable.curses`. Note: `cataclysm-dda` is
an alias to `cataclysmDDA.stable.tiles`.

If you like access to a development build of your favorite git revision,
override `cataclysm-dda-git` (or `cataclysmDDA.git.curses` if you like curses
build):

```nix
cataclysm-dda-git.override {
version = "YYYY-MM-DD";
rev = "YOUR_FAVORITE_REVISION";
sha256 = "CHECKSUM_OF_THE_REVISION";
}
```

The sha256 checksum can be obtained by

```sh
nix-prefetch-url --unpack "https://github.com/CleverRaven/Cataclysm-DDA/archive/${YOUR_FAVORITE_REVISION}.tar.gz"
```

The default configuration directory is `~/.cataclysm-dda`. If you prefer
`$XDG_CONFIG_HOME/cataclysm-dda`, override the derivation:

```nix
cataclysm-dda.override {
useXdgDir = true;
}
```

## Customizing with mods

To install Cataclysm DDA with mods of your choice, you can use `withMods`
attribute:

```nix
cataclysm-dda.withMods (mods: with mods; [
tileset.UndeadPeople
])
```

All mods, soundpacks, and tilesets available in nixpkgs are found in
`cataclysmDDA.pkgs`.

Here is an example to modify existing mods and/or add more mods not available
in nixpkgs:

```nix
let
customMods = self: super: lib.recursiveUpdate super {
# Modify existing mod
tileset.UndeadPeople = super.tileset.UndeadPeople.overrideAttrs (old: {
# If you like to apply a patch to the tileset for example
patches = [ ./path/to/your.patch ];
});
# Add another mod
mod.Awesome = cataclysmDDA.buildMod {
modName = "Awesome";
version = "0.x";
src = fetchFromGitHub {
owner = "Someone";
repo = "AwesomeMod";
rev = "...";
sha256 = "...";
};
# Path to be installed in the unpacked source (default: ".")
modRoot = "contents/under/this/path/will/be/installed";
};
# Add another soundpack
soundpack.Fantastic = cataclysmDDA.buildSoundPack {
# ditto
};
# Add another tileset
tileset.SuperDuper = cataclysmDDA.buildTileSet {
# ditto
};
};
in
cataclysm-dda.withMods (mods: with mods.extend customMods; [
tileset.UndeadPeople
mod.Awesome
soundpack.Fantastic
tileset.SuperDuper
])
```
1 change: 1 addition & 0 deletions doc/builders/packages/index.xml
Original file line number Diff line number Diff line change
@@ -18,6 +18,7 @@
<xi:include href="opengl.xml" />
<xi:include href="shell-helpers.xml" />
<xi:include href="steam.xml" />
<xi:include href="cataclysm-dda.section.xml" />
<xi:include href="urxvt.xml" />
<xi:include href="weechat.xml" />
<xi:include href="xorg.xml" />
2 changes: 2 additions & 0 deletions lib/systems/default.nix
Original file line number Diff line number Diff line change
@@ -32,6 +32,7 @@ rec {
/**/ if final.isDarwin then "libSystem"
else if final.isMinGW then "msvcrt"
else if final.isWasi then "wasilibc"
else if final.isRedox then "relibc"
else if final.isMusl then "musl"
else if final.isUClibc then "uclibc"
else if final.isAndroid then "bionic"
@@ -65,6 +66,7 @@ rec {
freebsd = "FreeBSD";
openbsd = "OpenBSD";
wasi = "Wasi";
redox = "Redox";
genode = "Genode";
}.${final.parsed.kernel.name} or null;

3 changes: 3 additions & 0 deletions lib/systems/doubles.nix
Original file line number Diff line number Diff line change
@@ -22,6 +22,8 @@ let

"wasm64-wasi" "wasm32-wasi"

"x86_64-redox"

"powerpc64le-linux"

"riscv32-linux" "riscv64-linux"
@@ -69,6 +71,7 @@ in {
openbsd = filterDoubles predicates.isOpenBSD;
unix = filterDoubles predicates.isUnix;
wasi = filterDoubles predicates.isWasi;
redox = filterDoubles predicates.isRedox;
windows = filterDoubles predicates.isWindows;
genode = filterDoubles predicates.isGenode;

9 changes: 9 additions & 0 deletions lib/systems/examples.nix
Original file line number Diff line number Diff line change
@@ -163,6 +163,15 @@ rec {
libc = "newlib";
};

#
# Redox
#

x86_64-unknown-redox = {
config = "x86_64-unknown-redox";
libc = "relibc";
};

#
# Darwin
#
3 changes: 2 additions & 1 deletion lib/systems/inspect.nix
Original file line number Diff line number Diff line change
@@ -33,7 +33,7 @@ rec {

isBSD = { kernel = { families = { inherit (kernelFamilies) bsd; }; }; };
isDarwin = { kernel = { families = { inherit (kernelFamilies) darwin; }; }; };
isUnix = [ isBSD isDarwin isLinux isSunOS isCygwin ];
isUnix = [ isBSD isDarwin isLinux isSunOS isCygwin isRedox ];

isMacOS = { kernel = kernels.macos; };
isiOS = { kernel = kernels.ios; };
@@ -46,6 +46,7 @@ rec {
isCygwin = { kernel = kernels.windows; abi = abis.cygnus; };
isMinGW = { kernel = kernels.windows; abi = abis.gnu; };
isWasi = { kernel = kernels.wasi; };
isRedox = { kernel = kernels.redox; };
isGhcjs = { kernel = kernels.ghcjs; };
isGenode = { kernel = kernels.genode; };
isNone = { kernel = kernels.none; };
3 changes: 3 additions & 0 deletions lib/systems/parse.nix
Original file line number Diff line number Diff line change
@@ -277,6 +277,7 @@ rec {
openbsd = { execFormat = elf; families = { inherit bsd; }; };
solaris = { execFormat = elf; families = { }; };
wasi = { execFormat = wasm; families = { }; };
redox = { execFormat = elf; families = { }; };
windows = { execFormat = pe; families = { }; };
ghcjs = { execFormat = unknown; families = { }; };
genode = { execFormat = elf; families = { }; };
@@ -390,6 +391,8 @@ rec {
then { cpu = elemAt l 0; vendor = elemAt l 1; kernel = "windows"; }
else if (elemAt l 2 == "wasi")
then { cpu = elemAt l 0; vendor = elemAt l 1; kernel = "wasi"; }
else if (elemAt l 2 == "redox")
then { cpu = elemAt l 0; vendor = elemAt l 1; kernel = "redox"; }
else if hasPrefix "netbsd" (elemAt l 2)
then { cpu = elemAt l 0; vendor = elemAt l 1; kernel = elemAt l 2; }
else if (elem (elemAt l 2) ["eabi" "eabihf" "elf"])
7 changes: 4 additions & 3 deletions lib/tests/systems.nix
Original file line number Diff line number Diff line change
@@ -12,22 +12,23 @@ let
expected = lib.sort lib.lessThan y;
};
in with lib.systems.doubles; lib.runTests {
testall = mseteq all (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ wasi ++ windows ++ embedded ++ js ++ genode);
testall = mseteq all (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ wasi ++ windows ++ embedded ++ js ++ genode ++ redox);

testarm = mseteq arm [ "armv5tel-linux" "armv6l-linux" "armv6l-none" "armv7a-linux" "armv7l-linux" "arm-none" "armv7a-darwin" ];
testi686 = mseteq i686 [ "i686-linux" "i686-freebsd" "i686-netbsd" "i686-openbsd" "i686-cygwin" "i686-windows" "i686-none" "i686-darwin" ];
testmips = mseteq mips [ "mipsel-linux" ];
testx86_64 = mseteq x86_64 [ "x86_64-linux" "x86_64-darwin" "x86_64-freebsd" "x86_64-genode" "x86_64-openbsd" "x86_64-netbsd" "x86_64-cygwin" "x86_64-solaris" "x86_64-windows" "x86_64-none" ];
testx86_64 = mseteq x86_64 [ "x86_64-linux" "x86_64-darwin" "x86_64-freebsd" "x86_64-genode" "x86_64-redox" "x86_64-openbsd" "x86_64-netbsd" "x86_64-cygwin" "x86_64-solaris" "x86_64-windows" "x86_64-none" ];

testcygwin = mseteq cygwin [ "i686-cygwin" "x86_64-cygwin" ];
testdarwin = mseteq darwin [ "x86_64-darwin" "i686-darwin" "aarch64-darwin" "armv7a-darwin" ];
testfreebsd = mseteq freebsd [ "i686-freebsd" "x86_64-freebsd" ];
testgenode = mseteq genode [ "aarch64-genode" "x86_64-genode" ];
testredox = mseteq redox [ "x86_64-redox" ];
testgnu = mseteq gnu (linux /* ++ kfreebsd ++ ... */);
testillumos = mseteq illumos [ "x86_64-solaris" ];
testlinux = mseteq linux [ "aarch64-linux" "armv5tel-linux" "armv6l-linux" "armv7a-linux" "armv7l-linux" "i686-linux" "mipsel-linux" "riscv32-linux" "riscv64-linux" "x86_64-linux" "powerpc64le-linux" ];
testnetbsd = mseteq netbsd [ "i686-netbsd" "x86_64-netbsd" ];
testopenbsd = mseteq openbsd [ "i686-openbsd" "x86_64-openbsd" ];
testwindows = mseteq windows [ "i686-cygwin" "x86_64-cygwin" "i686-windows" "x86_64-windows" ];
testunix = mseteq unix (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ cygwin);
testunix = mseteq unix (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ cygwin ++ redox);
}
91 changes: 90 additions & 1 deletion nixos/doc/manual/configuration/gpu-accel.xml
Original file line number Diff line number Diff line change
@@ -52,7 +52,7 @@
<para>
The proper installation of OpenCL drivers can be verified through
the <command>clinfo</command> command of the <package>clinfo</package>
package. This command will report the number of hardware devides
package. This command will report the number of hardware devices
that is found and give detailed information for each device:
</para>

@@ -101,4 +101,93 @@ ROCR_EXT_DIR=`nix-build '&lt;nixpkgs&gt;' --no-out-link -A rocm-runtime-ext`/lib
</para>
</section>
</section>

<section xml:id="sec-gpu-accel-vulkan">
<title>Vulkan</title>

<para>
<link xlink:href="https://en.wikipedia.org/wiki/Vulkan_(API)">Vulkan</link> is a
graphics and compute API for GPUs. It is used directly by games or indirectly though
compatibility layers like <link xlink:href="https://github.com/doitsujin/dxvk/wiki">DXVK</link>.
</para>

<para>
By default, if <xref linkend="opt-hardware.opengl.driSupport"/> is enabled,
<package>mesa</package> is installed and provides Vulkan for supported hardware.
</para>

<para>
Similar to OpenCL, Vulkan drivers are loaded through the <emphasis>Installable Client
Driver</emphasis> (ICD) mechanism. ICD files for Vulkan are JSON files that specify
the path to the driver library and the supported Vulkan version. All successfully
loaded drivers are exposed to the application as different GPUs.
In NixOS, there are two ways to make ICD files visible to Vulkan applications: an
environment variable and a module option.
</para>

<para>
The first option is through the <varname>VK_ICD_FILENAMES</varname>
environment variable. This variable can contain multiple JSON files, separated by
<literal>:</literal>. For example:

<screen><prompt>$</prompt> export \
VK_ICD_FILENAMES=`nix-build '&lt;nixpkgs&gt;' --no-out-link -A amdvlk`/share/vulkan/icd.d/amd_icd64.json</screen>
</para>

<para>
The second mechanism is to add the Vulkan driver package to
<xref linkend="opt-hardware.opengl.extraPackages"/>. This links the
ICD file under <filename>/run/opengl-driver</filename>, where it will
be visible to the ICD loader.
</para>

<para>
The proper installation of Vulkan drivers can be verified through
the <command>vulkaninfo</command> command of the <package>vulkan-tools</package>
package. This command will report the hardware devices and drivers found,
in this example output amdvlk and radv:
</para>

<screen><prompt>$</prompt> vulkaninfo | grep GPU
GPU id : 0 (Unknown AMD GPU)
GPU id : 1 (AMD RADV NAVI10 (LLVM 9.0.1))
...
GPU0:
deviceType = PHYSICAL_DEVICE_TYPE_DISCRETE_GPU
deviceName = Unknown AMD GPU
GPU1:
deviceType = PHYSICAL_DEVICE_TYPE_DISCRETE_GPU</screen>

<para>
A simple graphical application that uses Vulkan is <command>vkcube</command>
from the <package>vulkan-tools</package> package.
</para>

<section xml:id="sec-gpu-accel-vulkan-amd">
<title>AMD</title>

<para>
Modern AMD <link
xlink:href="https://en.wikipedia.org/wiki/Graphics_Core_Next">Graphics
Core Next</link> (GCN) GPUs are supported through either radv, which is
part of <package>mesa</package>, or the <package>amdvlk</package> package.
Adding the <package>amdvlk</package> package to
<xref linkend="opt-hardware.opengl.extraPackages"/> makes both drivers
available for applications and lets them choose. A specific driver can
be forced as follows:

<programlisting><xref linkend="opt-hardware.opengl.extraPackages"/> = [
<package>amdvlk</package>
];

# For amdvlk
<xref linkend="opt-environment.variables"/>.VK_ICD_FILENAMES =
"/run/opengl-driver/share/vulkan/icd.d/amd_icd64.json";
# For radv
<xref linkend="opt-environment.variables"/>.VK_ICD_FILENAMES =
"/run/opengl-driver/share/vulkan/icd.d/radeon_icd.x86_64.json";
</programlisting>
</para>
</section>
</section>
</chapter>
2 changes: 1 addition & 1 deletion nixos/doc/manual/installation/installing.xml
Original file line number Diff line number Diff line change
@@ -42,7 +42,7 @@
</para>

<para>
If the text is too small to be legible, try <command>setfont ter-132n</command>
If the text is too small to be legible, try <command>setfont ter-v32n</command>
to increase the font size.
</para>

16 changes: 16 additions & 0 deletions nixos/modules/hardware/video/hidpi.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{ lib, pkgs, config, ...}:
with lib;

{
options.hardware.video.hidpi.enable = mkEnableOption "Font/DPI configuration optimized for HiDPI displays";

config = mkIf config.hardware.video.hidpi.enable {
console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-v32n.psf.gz";

# Needed when typing in passwords for full disk encryption
console.earlySetup = mkDefault true;
boot.loader.systemd-boot.consoleMode = mkDefault "1";

# TODO Find reasonable defaults X11 & wayland
};
}
29 changes: 29 additions & 0 deletions nixos/modules/hardware/xpadneo.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{ config, lib, ... }:

with lib;
let
cfg = config.hardware.xpadneo;
in
{
options.hardware.xpadneo = {
enable = mkEnableOption "the xpadneo driver for Xbox One wireless controllers";
};

config = mkIf cfg.enable {
boot = {
# Must disable Enhanced Retransmission Mode to support bluetooth pairing
# https://wiki.archlinux.org/index.php/Gamepad#Connect_Xbox_Wireless_Controller_with_Bluetooth
extraModprobeConfig =
mkIf
config.hardware.bluetooth.enable
"options bluetooth disable_ertm=1";

extraModulePackages = with config.boot.kernelPackages; [ xpadneo ];
kernelModules = [ "hid_xpadneo" ];
};
};

meta = {
maintainers = with maintainers; [ metadark ];
};
}
4 changes: 2 additions & 2 deletions nixos/modules/installer/tools/nixos-generate-config.pl
Original file line number Diff line number Diff line change
@@ -497,8 +497,8 @@ sub in {
$modes =~ m/([0-9]+)x([0-9]+)/;
my $console_width = $1, my $console_height = $2;
if ($console_width > 1920) {
push @attrs, "# High-DPI console";
push @attrs, 'console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz";';
push @attrs, "# high-resolution display";
push @attrs, 'hardware.video.hidpi.enable = lib.mkDefault true;';
}
}

Loading