wine-wayland: added derivation for building the experimental Wayland driver for Wine

main
jmc-figueira 2 years ago
parent 5d70684de9
commit abdbf22a30
No known key found for this signature in database
GPG Key ID: DC7AE56AE98E02D7
  1. 2
      nixos/tests/wine.nix
  2. 11
      pkgs/misc/emulators/wine/default.nix
  3. 15
      pkgs/misc/emulators/wine/sources.nix
  4. 21
      pkgs/misc/emulators/wine/wayland.nix
  5. 1
      pkgs/top-level/aliases.nix
  6. 6
      pkgs/top-level/all-packages.nix
  7. 3
      pkgs/top-level/wine-packages.nix

@ -35,7 +35,7 @@ let
};
};
variants = [ "base" "full" "minimal" "staging" "unstable" ];
variants = [ "base" "full" "minimal" "staging" "unstable" "wayland" ];
in listToAttrs (map (makeWineTest "winePackages" [ hello32 ]) variants
++ map (makeWineTest "wineWowPackages" [ hello32 hello64 ]) variants)

@ -1,7 +1,7 @@
## Configuration:
# Control you default wine config in nixpkgs-config:
# wine = {
# release = "stable"; # "stable", "unstable", "staging"
# release = "stable"; # "stable", "unstable", "staging", "wayland"
# build = "wineWow"; # "wine32", "wine64", "wineWow"
# };
# Make additional configurations on demand:
@ -67,4 +67,11 @@ in if wineRelease == "staging" then
wineUnstable = wine-build wineBuild "unstable";
}
else
wine-build wineBuild wineRelease
(if wineRelease == "wayland" then
callPackage ./wayland.nix {
wineWayland = wine-build wineBuild "wayland";
inherit vulkanSupport vkd3dSupport;
}
else
wine-build wineBuild wineRelease
)

@ -10,6 +10,8 @@ let fetchurl = args@{url, sha256, ...}:
pkgs.fetchurl { inherit url sha256; } // args;
fetchFromGitHub = args@{owner, repo, rev, sha256, ...}:
pkgs.fetchFromGitHub { inherit owner repo rev sha256; } // args;
fetchFromGitLab = args@{domain, owner, repo, rev, sha256, ...}:
pkgs.fetchFromGitLab { inherit domain owner repo rev sha256; } // args;
in rec {
stable = fetchurl rec {
@ -73,6 +75,19 @@ in rec {
disabledPatchsets = [ ];
};
wayland = fetchFromGitLab rec {
version = "7.0-rc2";
sha256 = "sha256-FU9L8cyIIfFQ+8f/AUg7IT+RxTpyNTuSfL0zBnur0SA=";
domain = "gitlab.collabora.com";
owner = "alf";
repo = "wine";
rev = "95f0154c96a4b7d81e783ee5ba2f5d9cc7cda351";
inherit (unstable) gecko32 gecko64;
inherit (unstable) mono;
};
winetricks = fetchFromGitHub rec {
# https://github.com/Winetricks/winetricks/releases
version = "20210825";

@ -0,0 +1,21 @@
{ lib, callPackage, wineWayland, vulkanSupport, vkd3dSupport }:
with callPackage ./util.nix {};
(lib.overrideDerivation wineWayland (self: {
buildInputs = (toBuildInputs wineWayland.pkgArches (pkgs: [ pkgs.wayland pkgs.libxkbcommon pkgs.wayland-protocols pkgs.wayland.dev pkgs.libxkbcommon.dev ])) ++ (lib.subtractLists (toBuildInputs wineWayland.pkgArches (pkgs: [ pkgs.xorg.libX11 pkgs.xorg.libXi pkgs.xorg.libXcursor pkgs.xorg.libXrandr pkgs.xorg.libXrender pkgs.xorg.libXxf86vm pkgs.xorg.libXcomposite pkgs.xorg.libXext ])) self.buildInputs);
name = "${self.name}-wayland";
configureFlags = self.configureFlags
++ [ "--with-wayland" ]
++ lib.optionals vulkanSupport [ "--with-vulkan" ]
++ lib.optionals vkd3dSupport [ "--with-vkd3d" ];
})) // {
meta = wineWayland.meta // {
description = "An Open Source implementation of the Windows API on top of OpenGL and Unix (with experimental Wayland support)";
platforms = (lib.remove "x86_64-darwin" wineWayland.meta.platforms);
maintainers = wineWayland.meta.maintainers ++ [ lib.maintainers.jmc-figueira ];
};
}

@ -1036,6 +1036,7 @@ mapAliases ({
weechat-matrix-bridge = weechatScripts.weechat-matrix-bridge; # added 2018-09-06
wicd = throw "wicd has been removed as it is abandoned."; # added 2021-09-11
wineStaging = wine-staging; # added 2018-01-08
wineWayland = wine-wayland;
winusb = woeusb; # added 2017-12-22
winswitch = throw "winswitch has been removed from nixpkgs."; # added 2019-12-10
wireshark-gtk = throw "wireshark-gtk is not supported anymore. Use wireshark-qt or wireshark-cli instead."; # added 2019-11-18

@ -33652,7 +33652,7 @@ with pkgs;
inherit wineBuild;
inherit (callPackage ./wine-packages.nix {})
minimal base full stable stableFull unstable unstableFull staging stagingFull fonts;
minimal base full stable stableFull unstable unstableFull staging stagingFull wayland waylandFull fonts;
});
winePackages = recurseIntoAttrs (winePackagesFor (config.wine.build or "wine32"));
@ -33666,6 +33666,10 @@ with pkgs;
wineRelease = "staging";
});
wine-wayland = lowPrio (winePackages.full.override {
wineRelease = "wayland";
});
winetricks = callPackage ../misc/emulators/wine/winetricks.nix {
inherit (gnome) zenity;
};

@ -58,4 +58,7 @@ rec {
staging = base.override { wineRelease = "staging"; };
stagingFull = full.override { wineRelease = "staging"; };
wayland = base.override { wineRelease = "wayland"; };
waylandFull = full.override { wineRelease = "wayland"; };
}

Loading…
Cancel
Save