Wine: Difference between revisions

From NixOS Wiki
imported>Fadenb
m Syntaxhighlight
Klinger (talk | contribs)
No edit summary
 
(10 intermediate revisions by 7 users not shown)
Line 1: Line 1:
== Both 32bit and 64bit Support ==
Wine is an application to run Windows applications and games.
== 32-bit and 64-bit Support ==


The default wine package only supports 32bit apps, to make it work with 64bit as well you have to override the wineBuild option like this:
On x86_64-linux, the wine package supports by default both 32- and 64-bit applications. On '''every other platform''', the wine package supports by default '''only 32-bit''' applications.
 
These defaults can however be overwritten like this:


<syntaxhighlight lang="nix">{
<syntaxhighlight lang="nix">{
   environment.systemPackages = with pkgs; [
   environment.systemPackages = with pkgs; [
      #...
    # ...
      (wine.override { wineBuild = "wineWow"; })
 
    # support both 32- and 64-bit applications
    wineWowPackages.stable
 
    # support 32-bit only
    wine
 
    # support 64-bit only
    (wine.override { wineBuild = "wine64"; })
 
    # support 64-bit only
    wine64
 
    # wine-staging (version with experimental features)
    wineWowPackages.staging


      # use the following variant to get a 64bit only wine
    # winetricks (all versions)
      #(wine.override { wineBuild = "wine64"; })
    winetricks
      # wineStaging also accepts the wineBuild argument
 
      #(wineStaging.override { wineBuild = "wineWow"; })
    # native wayland support (unstable)
      #...
    wineWowPackages.waylandFull
   ];
   ];
}</syntaxhighlight>
}</syntaxhighlight>
If you get the error <code>wine: '/path/to/your/wineprefix' is a 64-bit installation, it cannot be used with a 32-bit wineserver.</code>, then you need a 64-bit build like <code>wineWowPackages</code>.
The <code>override</code> method is mentioned in [https://nixos.org/nixos/manual/index.html#sec-customising-packages the manual].
The <code>override</code> method is mentioned in [https://nixos.org/nixos/manual/index.html#sec-customising-packages the manual].
[[Category:Applications]]
[[Category:Gaming]]

Latest revision as of 17:23, 19 April 2024

Wine is an application to run Windows applications and games.

32-bit and 64-bit Support

On x86_64-linux, the wine package supports by default both 32- and 64-bit applications. On every other platform, the wine package supports by default only 32-bit applications.

These defaults can however be overwritten like this:

{
  environment.systemPackages = with pkgs; [
    # ...

    # support both 32- and 64-bit applications
    wineWowPackages.stable

    # support 32-bit only
    wine

    # support 64-bit only
    (wine.override { wineBuild = "wine64"; })

    # support 64-bit only
    wine64

    # wine-staging (version with experimental features)
    wineWowPackages.staging

    # winetricks (all versions)
    winetricks

    # native wayland support (unstable)
    wineWowPackages.waylandFull
  ];
}

If you get the error wine: '/path/to/your/wineprefix' is a 64-bit installation, it cannot be used with a 32-bit wineserver., then you need a 64-bit build like wineWowPackages.

The override method is mentioned in the manual.