wine: add MinGW-w64 support
This commit is contained in:
parent
31051812bc
commit
9f5cba0aaa
@ -1,5 +1,5 @@
|
|||||||
{ stdenv, lib, pkgArches, callPackage,
|
{ stdenv, lib, pkgArches, callPackage,
|
||||||
name, version, src, monos, geckos, platforms,
|
name, version, src, mingwGccs, monos, geckos, platforms,
|
||||||
pkgconfig, fontforge, makeWrapper, flex, bison,
|
pkgconfig, fontforge, makeWrapper, flex, bison,
|
||||||
supportFlags,
|
supportFlags,
|
||||||
buildScript ? null, configureFlags ? []
|
buildScript ? null, configureFlags ? []
|
||||||
@ -15,9 +15,13 @@ stdenv.mkDerivation ((lib.optionalAttrs (buildScript != null) {
|
|||||||
}) // rec {
|
}) // rec {
|
||||||
inherit name src configureFlags;
|
inherit name src configureFlags;
|
||||||
|
|
||||||
|
# Fixes "Compiler cannot create executables" building wineWow with mingwSupport
|
||||||
|
strictDeps = true;
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
pkgconfig fontforge makeWrapper flex bison
|
pkgconfig fontforge makeWrapper flex bison
|
||||||
];
|
]
|
||||||
|
++ lib.optionals supportFlags.mingwSupport mingwGccs;
|
||||||
|
|
||||||
buildInputs = toBuildInputs pkgArches (with supportFlags; (pkgs:
|
buildInputs = toBuildInputs pkgArches (with supportFlags; (pkgs:
|
||||||
[ pkgs.freetype ]
|
[ pkgs.freetype ]
|
||||||
@ -92,6 +96,7 @@ stdenv.mkDerivation ((lib.optionalAttrs (buildScript != null) {
|
|||||||
# drive_c/windows/system32 will only contain a few files instead of
|
# drive_c/windows/system32 will only contain a few files instead of
|
||||||
# hundreds, there will be an error about winemenubuilder and MountMgr
|
# hundreds, there will be an error about winemenubuilder and MountMgr
|
||||||
# on startup of Wine, and the Drives tab in winecfg will show an error.
|
# on startup of Wine, and the Drives tab in winecfg will show an error.
|
||||||
|
# TODO: binutils 2.34 contains a fix for this bug, re-enable stripping once available.
|
||||||
dontStrip = true;
|
dontStrip = true;
|
||||||
|
|
||||||
## FIXME
|
## FIXME
|
||||||
@ -136,7 +141,8 @@ stdenv.mkDerivation ((lib.optionalAttrs (buildScript != null) {
|
|||||||
# https://bugs.winehq.org/show_bug.cgi?id=43530
|
# https://bugs.winehq.org/show_bug.cgi?id=43530
|
||||||
# https://github.com/NixOS/nixpkgs/issues/31989
|
# https://github.com/NixOS/nixpkgs/issues/31989
|
||||||
hardeningDisable = [ "bindnow" ]
|
hardeningDisable = [ "bindnow" ]
|
||||||
++ lib.optional (stdenv.hostPlatform.isDarwin) "fortify";
|
++ lib.optional (stdenv.hostPlatform.isDarwin) "fortify"
|
||||||
|
++ lib.optional (supportFlags.mingwSupport) "format";
|
||||||
|
|
||||||
passthru = { inherit pkgArches; };
|
passthru = { inherit pkgArches; };
|
||||||
meta = {
|
meta = {
|
||||||
|
@ -44,6 +44,7 @@
|
|||||||
sdlSupport ? false,
|
sdlSupport ? false,
|
||||||
faudioSupport ? false,
|
faudioSupport ? false,
|
||||||
vkd3dSupport ? false,
|
vkd3dSupport ? false,
|
||||||
|
mingwSupport ? false,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let wine-build = build: release:
|
let wine-build = build: release:
|
||||||
@ -56,7 +57,7 @@ let wine-build = build: release:
|
|||||||
gsmSupport gphoto2Support ldapSupport fontconfigSupport alsaSupport
|
gsmSupport gphoto2Support ldapSupport fontconfigSupport alsaSupport
|
||||||
pulseaudioSupport xineramaSupport gtkSupport openclSupport xmlSupport tlsSupport
|
pulseaudioSupport xineramaSupport gtkSupport openclSupport xmlSupport tlsSupport
|
||||||
openglSupport gstreamerSupport udevSupport vulkanSupport sdlSupport faudioSupport
|
openglSupport gstreamerSupport udevSupport vulkanSupport sdlSupport faudioSupport
|
||||||
vkd3dSupport;
|
vkd3dSupport mingwSupport;
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ stdenv_32bit, lib, pkgs, pkgsi686Linux, callPackage,
|
{ stdenv_32bit, lib, pkgs, pkgsi686Linux, pkgsCross, callPackage,
|
||||||
wineRelease ? "stable",
|
wineRelease ? "stable",
|
||||||
supportFlags
|
supportFlags
|
||||||
}:
|
}:
|
||||||
@ -10,6 +10,7 @@ in with src; {
|
|||||||
inherit src version supportFlags;
|
inherit src version supportFlags;
|
||||||
pkgArches = [ pkgsi686Linux ];
|
pkgArches = [ pkgsi686Linux ];
|
||||||
geckos = [ gecko32 ];
|
geckos = [ gecko32 ];
|
||||||
|
mingwGccs = with pkgsCross; [ mingw32.buildPackages.gcc ];
|
||||||
monos = [ mono ];
|
monos = [ mono ];
|
||||||
platforms = [ "i686-linux" "x86_64-linux" ];
|
platforms = [ "i686-linux" "x86_64-linux" ];
|
||||||
};
|
};
|
||||||
@ -17,6 +18,7 @@ in with src; {
|
|||||||
name = "wine64-${version}";
|
name = "wine64-${version}";
|
||||||
inherit src version supportFlags;
|
inherit src version supportFlags;
|
||||||
pkgArches = [ pkgs ];
|
pkgArches = [ pkgs ];
|
||||||
|
mingwGccs = with pkgsCross; [ mingwW64.buildPackages.gcc ];
|
||||||
geckos = [ gecko64 ];
|
geckos = [ gecko64 ];
|
||||||
monos = [ mono ];
|
monos = [ mono ];
|
||||||
configureFlags = [ "--enable-win64" ];
|
configureFlags = [ "--enable-win64" ];
|
||||||
@ -28,6 +30,7 @@ in with src; {
|
|||||||
stdenv = stdenv_32bit;
|
stdenv = stdenv_32bit;
|
||||||
pkgArches = [ pkgs pkgsi686Linux ];
|
pkgArches = [ pkgs pkgsi686Linux ];
|
||||||
geckos = [ gecko32 gecko64 ];
|
geckos = [ gecko32 gecko64 ];
|
||||||
|
mingwGccs = with pkgsCross; [ mingw32.buildPackages.gcc mingwW64.buildPackages.gcc ];
|
||||||
monos = [ mono ];
|
monos = [ mono ];
|
||||||
buildScript = ./builder-wow.sh;
|
buildScript = ./builder-wow.sh;
|
||||||
platforms = [ "x86_64-linux" ];
|
platforms = [ "x86_64-linux" ];
|
||||||
|
Loading…
Reference in New Issue
Block a user