2024-07-05 09:19:04 +01:00
|
|
|
{ lib, callPackage, CoreFoundation, fetchFromGitHub, fetchpatch, pkgs, wrapCDDA, attachPkgs
|
2019-05-02 17:40:17 +01:00
|
|
|
, tiles ? true, Cocoa
|
2018-07-05 17:47:43 +01:00
|
|
|
, debug ? false
|
2020-04-09 09:16:25 +01:00
|
|
|
, useXdgDir ? false
|
2022-08-21 01:31:45 +01:00
|
|
|
, version ? "2022-08-20"
|
|
|
|
, rev ? "f65b2bc4c6dea24bd9a993b8df146e5698e7e36f"
|
|
|
|
, sha256 ? "sha256-00Tp9OmsM39PYwAJXKKRS9zmn7KsGQ9s1eVmEqghkpw="
|
2018-07-05 17:47:43 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
2020-04-08 02:46:57 +01:00
|
|
|
common = callPackage ./common.nix {
|
2020-04-09 09:16:25 +01:00
|
|
|
inherit CoreFoundation tiles Cocoa debug useXdgDir;
|
2020-04-08 02:46:57 +01:00
|
|
|
};
|
2018-07-05 17:47:43 +01:00
|
|
|
|
2020-04-08 02:46:57 +01:00
|
|
|
self = common.overrideAttrs (common: rec {
|
|
|
|
pname = common.pname + "-git";
|
2020-04-10 01:30:33 +01:00
|
|
|
inherit version;
|
2016-07-03 21:42:37 +01:00
|
|
|
|
2020-04-08 02:46:57 +01:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "CleverRaven";
|
|
|
|
repo = "Cataclysm-DDA";
|
2020-04-10 01:30:33 +01:00
|
|
|
inherit rev sha256;
|
2020-04-08 02:46:57 +01:00
|
|
|
};
|
2016-07-03 21:42:37 +01:00
|
|
|
|
2022-08-21 01:31:45 +01:00
|
|
|
patches = [
|
|
|
|
# Unconditionally look for translation files in $out/share/locale
|
2023-03-01 18:51:06 +00:00
|
|
|
./locale-path.patch
|
2024-01-20 21:11:14 +00:00
|
|
|
# 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=";
|
|
|
|
})
|
2022-08-21 01:31:45 +01:00
|
|
|
];
|
|
|
|
|
2020-04-08 02:46:57 +01:00
|
|
|
makeFlags = common.makeFlags ++ [
|
|
|
|
"VERSION=git-${version}-${lib.substring 0 8 src.rev}"
|
|
|
|
];
|
2016-07-03 21:42:37 +01:00
|
|
|
|
2020-04-09 08:11:51 +01:00
|
|
|
meta = common.meta // {
|
|
|
|
maintainers = with lib.maintainers;
|
|
|
|
common.meta.maintainers ++ [ rardiol ];
|
2020-04-08 02:46:57 +01:00
|
|
|
};
|
|
|
|
});
|
|
|
|
in
|
|
|
|
|
2020-11-12 01:48:19 +00:00
|
|
|
attachPkgs pkgs self
|