git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #40641 from angerman/feature/darwin-wine

Enable WINE on macOS

commit974fa94fd81204645150f03543288ddb481a8b67 authorJohn Ericson <Ericson2314@yahoo.com> dateFri 18 May 2018, 17:42 (9 years ago) parente3a7d550828bc5
2 files changed+11−7
pkgs/misc/emulators/wine/base.nix+10−6 pkgs/misc/emulators/wine/packages.nix+1−1
pkgs/misc/emulators/wine/base.nix+10−6
@@ -6,8 +6,6 @@
66 buildScript ? null, configureFlags ? ""
77}:
88
9−assert stdenv.cc.cc.isGNU or false;
10−
119with import ./util.nix { inherit lib; };
1210
1311stdenv.mkDerivation ((lib.optionalAttrs (! isNull buildScript) {
@@ -54,9 +52,14 @@ stdenv.mkDerivation ((lib.optionalAttrs (! isNull buildScript) {
5452 ++ lib.optionals xmlSupport [ pkgs.libxml2 pkgs.libxslt ]
5553 ++ lib.optionals tlsSupport [ pkgs.openssl pkgs.gnutls ]
5654 ++ lib.optionals openglSupport [ pkgs.libGLU_combined pkgs.mesa_noglu.osmesa pkgs.libdrm ]
57− ++ (with pkgs.xorg; [
58− libX11 libXi libXcursor libXrandr libXrender libXxf86vm libXcomposite libXext
59− ])));
55+ ++ lib.optionals stdenv.isDarwin (with pkgs.buildPackages.darwin.apple_sdk.frameworks; [
56+ CoreServices Foundation ForceFeedback AppKit OpenGL IOKit DiskArbitration Security
57+ ApplicationServices AudioToolbox CoreAudio AudioUnit CoreMIDI OpenAL OpenCL Cocoa Carbon
58+ ])
59+ ++ lib.optionals stdenv.isLinux (with pkgs.xorg; [
60+ libXi libXcursor libXrandr libXrender libXxf86vm libXcomposite libXext
61+ ])
62+ ++ [ pkgs.xorg.libX11 ]));
6063
6164 # Wine locates a lot of libraries dynamically through dlopen(). Add
6265 # them to the RPATH so that the user doesn't have to set them in
@@ -105,7 +108,8 @@ stdenv.mkDerivation ((lib.optionalAttrs (! isNull buildScript) {
105108
106109 # https://bugs.winehq.org/show_bug.cgi?id=43530
107110 # https://github.com/NixOS/nixpkgs/issues/31989
108− hardeningDisable = [ "bindnow" ];
111+ hardeningDisable = [ "bindnow" ]
112+ ++ lib.optional (stdenv.hostPlatform.isDarwin) "fortify";
109113
110114 passthru = { inherit pkgArches; };
111115 meta = {
pkgs/misc/emulators/wine/packages.nix+1−1
@@ -20,7 +20,7 @@ in with src; {
2020 geckos = [ gecko64 ];
2121 monos = [ mono ];
2222 configureFlags = [ "--enable-win64" ];
23− platforms = [ "x86_64-linux" ];
23+ platforms = [ "x86_64-linux" "x86_64-darwin" ];
2424 };
2525 wineWow = callPackage ./base.nix {
2626 name = "wine-wow-${version}";