mirror of
https://github.com/CHN-beta/nixpkgs.git
synced 2026-01-11 18:32:23 +08:00
winePackages: add pinned wine variant for yabridge
This commit is contained in:
@@ -286,8 +286,8 @@ stdenv.mkDerivation (
|
||||
|
||||
passthru = {
|
||||
inherit pkgArches;
|
||||
inherit (src) updateScript;
|
||||
tests = { inherit (nixosTests) wine; };
|
||||
updateScript = src.updateScript or null;
|
||||
};
|
||||
meta = {
|
||||
inherit version;
|
||||
|
||||
@@ -90,10 +90,18 @@ let
|
||||
}
|
||||
);
|
||||
|
||||
baseRelease =
|
||||
{
|
||||
staging = "unstable";
|
||||
yabridge = "yabridge";
|
||||
}
|
||||
.${wineRelease} or null;
|
||||
in
|
||||
if wineRelease == "staging" then
|
||||
if baseRelease != null then
|
||||
callPackage ./staging.nix {
|
||||
wineUnstable = wine-build wineBuild "unstable";
|
||||
wineUnstable = (wine-build wineBuild baseRelease).override {
|
||||
inherit wineRelease;
|
||||
};
|
||||
}
|
||||
else
|
||||
wine-build wineBuild wineRelease
|
||||
|
||||
@@ -120,6 +120,18 @@ rec {
|
||||
hash = "sha256-wDbsHvR2dHdKX5lFgwIuni62j+j8GLOox55oWzvsibw=";
|
||||
inherit (stable) patches;
|
||||
|
||||
# see https://gitlab.winehq.org/wine/wine-staging
|
||||
staging = fetchFromGitLab {
|
||||
inherit version;
|
||||
hash = "sha256-rXA/55rwQSJR247E4H7cQdTtXRmjomRbls7THV3jfcE=";
|
||||
domain = "gitlab.winehq.org";
|
||||
owner = "wine";
|
||||
repo = "wine-staging";
|
||||
rev = "v${version}";
|
||||
|
||||
disabledPatchsets = [ ];
|
||||
};
|
||||
|
||||
## see http://wiki.winehq.org/Gecko
|
||||
gecko32 = fetchurl rec {
|
||||
version = "2.47.4";
|
||||
@@ -147,8 +159,8 @@ rec {
|
||||
latest_mono=$(get_latest_lib_version wine-mono)
|
||||
|
||||
update_staging() {
|
||||
staging_url=$(get_source_attr staging.url)
|
||||
set_source_attr staging hash "\"$(to_sri "$(nix-prefetch-url --unpack "''${staging_url//$1/$2}")")\""
|
||||
staging_url=$(get_source_attr unstable.staging.url)
|
||||
set_source_attr unstable.staging hash "\"$(to_sri "$(nix-prefetch-url --unpack "''${staging_url//$1/$2}")")\""
|
||||
}
|
||||
|
||||
autobump unstable "$latest_unstable" "" update_staging
|
||||
@@ -160,16 +172,43 @@ rec {
|
||||
'';
|
||||
};
|
||||
|
||||
staging = fetchFromGitLab rec {
|
||||
# https://gitlab.winehq.org/wine/wine-staging
|
||||
inherit (unstable) version;
|
||||
hash = "sha256-rXA/55rwQSJR247E4H7cQdTtXRmjomRbls7THV3jfcE=";
|
||||
domain = "gitlab.winehq.org";
|
||||
owner = "wine";
|
||||
repo = "wine-staging";
|
||||
rev = "v${version}";
|
||||
yabridge = fetchurl rec {
|
||||
# NOTE: This is a pinned version with staging patches; don't forget to update them as well
|
||||
version = "9.21";
|
||||
url = "https://dl.winehq.org/wine/source/9.x/wine-${version}.tar.xz";
|
||||
hash = "sha256-REK0f/2bLqRXEA427V/U5vTYKdnbeaJeYFF1qYjKL/8=";
|
||||
inherit (stable) patches;
|
||||
|
||||
disabledPatchsets = [ ];
|
||||
# see https://gitlab.winehq.org/wine/wine-staging
|
||||
staging = fetchFromGitLab {
|
||||
inherit version;
|
||||
hash = "sha256-FDNszRUvM1ewE9Ij4EkuihaX0Hf0eTb5r7KQHMdCX3U=";
|
||||
domain = "gitlab.winehq.org";
|
||||
owner = "wine";
|
||||
repo = "wine-staging";
|
||||
rev = "v${version}";
|
||||
|
||||
disabledPatchsets = [ ];
|
||||
};
|
||||
|
||||
## see http://wiki.winehq.org/Gecko
|
||||
gecko32 = fetchurl rec {
|
||||
version = "2.47.4";
|
||||
url = "https://dl.winehq.org/wine/wine-gecko/${version}/wine-gecko-${version}-x86.msi";
|
||||
hash = "sha256-Js7MR3BrCRkI9/gUvdsHTGG+uAYzGOnvxaf3iYV3k9Y=";
|
||||
};
|
||||
gecko64 = fetchurl rec {
|
||||
version = "2.47.4";
|
||||
url = "https://dl.winehq.org/wine/wine-gecko/${version}/wine-gecko-${version}-x86_64.msi";
|
||||
hash = "sha256-5ZC32YijLWqkzx2Ko6o9M3Zv3Uz0yJwtzCCV7LKNBm8=";
|
||||
};
|
||||
|
||||
## see http://wiki.winehq.org/Mono
|
||||
mono = fetchurl rec {
|
||||
version = "9.3.0";
|
||||
url = "https://dl.winehq.org/wine/wine-mono/${version}/wine-mono-${version}-x86.msi";
|
||||
hash = "sha256-bKLArtCW/57CD69et2xrfX3oLZqIdax92fB5O/nD/TA=";
|
||||
};
|
||||
};
|
||||
|
||||
wayland = pkgs.lib.warnOnInstantiate "building wine with `wineRelease = \"wayland\"` is deprecated. Wine now builds with the wayland driver by default." stable; # added 2025-01-23
|
||||
|
||||
@@ -13,12 +13,12 @@
|
||||
with callPackage ./util.nix { };
|
||||
|
||||
let
|
||||
patch = (callPackage ./sources.nix { }).staging;
|
||||
patch = wineUnstable.src.staging;
|
||||
build-inputs = pkgNames: extra: (mkBuildInputs wineUnstable.pkgArches pkgNames) ++ extra;
|
||||
in
|
||||
assert lib.versions.majorMinor wineUnstable.version == lib.versions.majorMinor patch.version;
|
||||
|
||||
(wineUnstable.override { wineRelease = "staging"; }).overrideAttrs (self: {
|
||||
wineUnstable.overrideAttrs (self: {
|
||||
buildInputs = build-inputs (
|
||||
[
|
||||
"perl"
|
||||
|
||||
@@ -1248,11 +1248,11 @@ with pkgs;
|
||||
};
|
||||
|
||||
yabridge = callPackage ../tools/audio/yabridge {
|
||||
wine = wineWowPackages.staging;
|
||||
wine = wineWowPackages.yabridge;
|
||||
};
|
||||
|
||||
yabridgectl = callPackage ../tools/audio/yabridgectl {
|
||||
wine = wineWowPackages.staging;
|
||||
wine = wineWowPackages.yabridge;
|
||||
};
|
||||
|
||||
yafetch = callPackage ../tools/misc/yafetch {
|
||||
@@ -19287,6 +19287,7 @@ with pkgs;
|
||||
stagingFull
|
||||
wayland
|
||||
waylandFull
|
||||
yabridge
|
||||
fonts
|
||||
;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
config,
|
||||
callPackage,
|
||||
@@ -63,4 +64,10 @@ rec {
|
||||
waylandFull = full.override {
|
||||
x11Support = false;
|
||||
};
|
||||
|
||||
yabridge =
|
||||
let
|
||||
yabridge = base.override { wineRelease = "yabridge"; };
|
||||
in
|
||||
if wineBuild == "wineWow" then yabridge else lib.dontDistribute yabridge;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user