From 83851c6b244444d7ce4fc855ccbe5d2300095ba1 Mon Sep 17 00:00:00 2001 From: caryoscelus Date: Sun, 28 Jul 2024 17:29:08 +0000 Subject: [PATCH] cataclysm-dda-git: remove incompatible patches, bump git. --- pkgs/games/cataclysm-dda/git.nix | 21 ++++--------------- .../games/cataclysm-dda/locale-path-git.patch | 17 +++++++++++++++ 2 files changed, 21 insertions(+), 17 deletions(-) create mode 100644 pkgs/games/cataclysm-dda/locale-path-git.patch diff --git a/pkgs/games/cataclysm-dda/git.nix b/pkgs/games/cataclysm-dda/git.nix index e577d1aa710f..495d5f97fb09 100644 --- a/pkgs/games/cataclysm-dda/git.nix +++ b/pkgs/games/cataclysm-dda/git.nix @@ -2,9 +2,9 @@ , tiles ? true, Cocoa , debug ? false , useXdgDir ? false -, version ? "2022-08-20" -, rev ? "f65b2bc4c6dea24bd9a993b8df146e5698e7e36f" -, sha256 ? "sha256-00Tp9OmsM39PYwAJXKKRS9zmn7KsGQ9s1eVmEqghkpw=" +, version ? "2024-07-28" +, rev ? "bfeb1fffc4179fed242a042f24b1c97f6cfaff3d" +, sha256 ? "sha256-IodXEA+pWfDdR9huRXieP3+J3WZJO19C8PUPT18dFBw=" }: let @@ -24,20 +24,7 @@ let patches = [ # Unconditionally look for translation files in $out/share/locale - ./locale-path.patch - # Fixes for failing build with GCC 13, remove on updating next release after 0.G - (fetchpatch { - url = "https://sources.debian.org/data/main/c/cataclysm-dda/0.G-4/debian/patches/gcc13-dangling-reference-warning.patch"; - hash = "sha256-9nPbyz49IYBOVHqr7jzCIyS8z/SQgpK4EjEz1fruIPE="; - }) - (fetchpatch { - url = "https://sources.debian.org/data/main/c/cataclysm-dda/0.G-4/debian/patches/gcc13-cstdint.patch"; - hash = "sha256-8IBW2OzAHVgEJZoViQ490n37sl31hA55ePuqDL/lil0="; - }) - (fetchpatch { - url = "https://sources.debian.org/data/main/c/cataclysm-dda/0.G-4/debian/patches/gcc13-keyword-requires.patch"; - hash = "sha256-8yvHh0YKC7AC/qzia7AZAfMewMC0RiSepMXpOkMXRd8="; - }) + ./locale-path-git.patch ]; makeFlags = common.makeFlags ++ [ diff --git a/pkgs/games/cataclysm-dda/locale-path-git.patch b/pkgs/games/cataclysm-dda/locale-path-git.patch new file mode 100644 index 000000000000..8f18b0ffb71e --- /dev/null +++ b/pkgs/games/cataclysm-dda/locale-path-git.patch @@ -0,0 +1,17 @@ +diff --git a/src/translations.cpp b/src/translations.cpp +--- a/src/translations.cpp ++++ b/src/translations.cpp +@@ -52,13 +52,11 @@ std::string locale_dir() + #define CATA_IS_ON_BSD + #endif + +-#if !defined(__ANDROID__) && ((defined(__linux__) || defined(CATA_IS_ON_BSD) || (defined(MACOSX) && !defined(TILES)))) + if( !PATH_INFO::base_path().empty() ) { + loc_dir = PATH_INFO::base_path() + "share/locale"; + } else { + loc_dir = PATH_INFO::langdir(); + } +-#endif + #endif // LOCALIZE + return loc_dir; + }