Unverified Commit 155aa5a6 authored by Aleksana's avatar Aleksana Committed by GitHub
Browse files

tome4: fix build with GCC 15 (#479487)

parents cd3c87dd 98f71ed5
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
From e0c17a8665250b3e3e7f4938f7b256ff50b78fc8 Mon Sep 17 00:00:00 2001
From fcf32218989df74e9562b0e49e0a879e3d0e7da9 Mon Sep 17 00:00:00 2001
From: Tom van Dijk <18gatenmaker6@gmail.com>
Date: Thu, 23 Oct 2025 15:01:01 +0200
Subject: [PATCH 1/3] web missing include
Subject: [PATCH 1/4] web missing include

---
 src/web.c | 1 +
@@ -20,5 +20,5 @@ index f12eebb..940aaf9 100644
 /*
  * Grab web browser methods -- availabe only here
-- 
2.51.0
2.51.2
+3 −3
Original line number Diff line number Diff line
From a14890a8a7080c73cac10ff31365833b179c0464 Mon Sep 17 00:00:00 2001
From b0d000d959a27f962f6e4bd55d601d22ff443f94 Mon Sep 17 00:00:00 2001
From: Tom van Dijk <18gatenmaker6@gmail.com>
Date: Thu, 23 Oct 2025 15:45:03 +0200
Subject: [PATCH 2/3] zlib missing include
Subject: [PATCH 2/4] zlib missing include

---
 src/zlib/gzguts.h | 1 +
@@ -20,5 +20,5 @@ index 990a4d2..7c89751 100644
 #  include <stdlib.h>
 #  include <limits.h>
-- 
2.51.0
2.51.2
+3 −3
Original line number Diff line number Diff line
From ed9f9819c3a0d6b8e92f66aafa6324eb4b310282 Mon Sep 17 00:00:00 2001
From fd35d2505821155b12f165aafa64384599a600ab Mon Sep 17 00:00:00 2001
From: Tom van Dijk <18gatenmaker6@gmail.com>
Date: Thu, 23 Oct 2025 15:53:06 +0200
Subject: [PATCH 3/3] incompatible pointer types
Subject: [PATCH 3/4] incompatible pointer types

---
 src/display_sdl.c                  | 2 +-
@@ -67,5 +67,5 @@ index e2ec026..f905033 100644
 #define glVertexPointer(nb, t, v, p) \
 { \
-- 
2.51.0
2.51.2
+27 −0
Original line number Diff line number Diff line
From 55f41ab4ff15cca5791c107d504780a09f065eb7 Mon Sep 17 00:00:00 2001
From: Tom van Dijk <18gatenmaker6@gmail.com>
Date: Mon, 12 Jan 2026 21:51:31 +0100
Subject: [PATCH 4/4] fix build with C23

---
 src/types.h | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/types.h b/src/types.h
index b5b46a0..eea255b 100644
--- a/src/types.h
+++ b/src/types.h
@@ -22,9 +22,7 @@
 #define TYPES_H
 
 #ifndef __cplusplus
-#ifndef bool
-typedef char bool;
-#endif
+#include <stdbool.h>
 #endif
 
 #define FALSE 0
-- 
2.51.2
+2 −0
Original line number Diff line number Diff line
@@ -56,6 +56,8 @@ stdenv.mkDerivation (finalAttrs: {
    # unistd required for read and close
    ./0002-zlib-missing-include.patch
    ./0003-incompatible-pointer-types.patch
    # C23 requires stdbool for an actual proper boolean type instead of `char'
    ./0004-fix-build-with-C23.patch
  ];

  nativeBuildInputs = [