diff options
author | Sergei Trofimovich <slyich@gmail.com> | 2024-02-08 08:29:56 +0000 |
---|---|---|
committer | Sergei Trofimovich <slyich@gmail.com> | 2024-02-08 08:29:56 +0000 |
commit | 8b21717c1cf2d35a097c90072ab298b2d96a6360 (patch) | |
tree | 5ca9816340633c535a04366a50173f4a22d8a252 /pkgs/games | |
parent | cd5c10f69676a36ae44254b8cfd58f528a062f65 (diff) | |
download | nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar.gz nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar.bz2 nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar.lz nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar.xz nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.tar.zst nixlib-8b21717c1cf2d35a097c90072ab298b2d96a6360.zip |
gimx: fix build against `gcc-13`
Without the change the build in `master` fails as https://hydra.nixos.org/build/247555199: gimx.c:195:6: error: implicit declaration of function 'getenv' [-Werror=implicit-function-declaration] 195 | if(getenv("GIMXCONF")) { snprintf(file_path, sizeof(file_path), "%s", gimx_params.config_file); } | ^~~~~~
Diffstat (limited to 'pkgs/games')
-rw-r--r-- | pkgs/games/gimx/default.nix | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/pkgs/games/gimx/default.nix b/pkgs/games/gimx/default.nix index 9c2b260f1dbf..4173ac0cc2d6 100644 --- a/pkgs/games/gimx/default.nix +++ b/pkgs/games/gimx/default.nix @@ -1,4 +1,5 @@ -{ stdenv, lib, fetchFromGitHub, makeWrapper, curl, libusb1, xorg, libxml2 +{ stdenv, lib, fetchFromGitHub, fetchpatch +, makeWrapper, curl, libusb1, xorg, libxml2 , ncurses5, bluez, libmhash, gimxPdpGamepad ? false }: let @@ -21,7 +22,23 @@ in stdenv.mkDerivation rec { sha256 = "05kdv2qqr311c2p76hdlgvrq7b04vcpps5c80zn8b8l7p831ilgz"; }; - patches = [ ./conf.patch ]; + patches = [ + ./conf.patch + + # gcc-13 build fixes: + # https://github.com/matlo/GIMX/pull/705 + (fetchpatch { + name = "gcc-13-headers.patch"; + url = "https://github.com/matlo/GIMX/commit/4525dff4d9af672116d8c6c182707f2ad6295b2d.patch"; + hash = "sha256-LkswnFsxqADooa09yO7Yf0AbxTrGfjBObyv/6FQJvRs="; + }) + (fetchpatch { + name = "gcc-13-protos.patch"; + url = "https://github.com/matlo/GIMX/commit/f11855fcb8bd9d0cb9c94871b4111ddfd5b610df.patch"; + hash = "sha256-JL67UUsEyPcOuaimJtMviiGLGghuq9665Lg1QuiaWUU="; + }) + ]; + nativeBuildInputs = [ makeWrapper ]; buildInputs = [ curl libusb1 bluez libxml2 ncurses5 libmhash |