diff options
Diffstat (limited to 'nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix')
-rw-r--r-- | nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix | 43 |
1 files changed, 41 insertions, 2 deletions
diff --git a/nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix b/nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix index fca2cf421044..4fa16600d1d5 100644 --- a/nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix +++ b/nixpkgs/pkgs/by-name/do/dosbox-staging/package.nix @@ -7,6 +7,7 @@ , SDL2_net , alsa-lib , copyDesktopItems +, darwin , fluidsynth , glib , gtest @@ -57,6 +58,39 @@ stdenv.mkDerivation (finalAttrs: { hash = "sha256-WtTVSWWSlfXrdPVsnlDe4P5K/Fnj4QsOzx3Wo/Kusmg="; includes = [ "src/gui/meson.build" ]; }) + ] + # Pagesize detection via syscall; remove when next stable version arrives + ++ [ + (fetchpatch { + # Added as a parent commit of 7e20f6e + # Fix ppc64le backend and 64K page size support (#2828) + name = "meson-add-ppc64.patch"; + url = "https://github.com/dosbox-staging/dosbox-staging/commit/765bcc2b1d87050a4ea366bf22e1db075ad5660b.patch"; + hash = "sha256-RtkidyF7w6RrPmCKK4Bd+3FtAn/+/38xk2cl32+yzxw="; + includes = [ "meson.build" ]; + }) + (fetchpatch { + # Added as a parent commit of 7e20f6e + # Account for debian powerpc prefix (instead of ppc) + name = "meson-powerpc64le.patch"; + url = "https://github.com/dosbox-staging/dosbox-staging/commit/d44aa7441cd871ffac08974f22af7a735a839288.patch"; + hash = "sha256-oMZtfmB1CRlDWyXwEWc3XzC+XxKazXDgo+jUiNBoJDw="; + includes = [ "meson.build" ]; + }) + (fetchpatch { + # Added as a parent commit of 7e20f6e + # Restore the PowerPC dynrec core to working order + name = "meson-option-write-or-execute.patch"; + url = "https://github.com/dosbox-staging/dosbox-staging/commit/ef86642de390839afc77b2b591a6ea9ac43909b3.patch"; + hash = "sha256-htOKEaXRRy28XNMX/t6uFTBLCkTr7YPtfmI9UyIBiz4="; + includes = [ "meson_options.txt" ]; + }) + (fetchpatch { + # Use a system call to detect the page size + name = "meson-detect-pagesize-by-syscall.patch"; + url = "https://github.com/dosbox-staging/dosbox-staging/commit/7e20f6e401956a7a308f1b3462294d7ac9fa5db8.patch"; + hash = "sha256-QW9lpHWCYSlQFgTqX/UxHAAWisz4wfPrdjLqROn/wR0="; + }) ]; nativeBuildInputs = [ @@ -69,7 +103,6 @@ stdenv.mkDerivation (finalAttrs: { ]; buildInputs = [ - alsa-lib fluidsynth glib iir1 @@ -87,7 +120,13 @@ stdenv.mkDerivation (finalAttrs: { SDL2_image SDL2_net speexdsp - ]; + ] ++ lib.optionals stdenv.isLinux [ + alsa-lib + ] ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ + AudioUnit + Carbon + Cocoa + ]); desktopItems = [ (makeDesktopItem { |