commit 2ced70c

Michael Forney  ·  2025-04-28 20:15:20 +0000 UTC
parent 202dfa5
transmission: Fix build with gcc 15.1.0

Use -isystem for the third-party includes. We want our libutp to
come first.

Add patch to fix utp_on_overhead type to match our libutp branch
(C99 bool).
3 files changed,  +39, -4
+3, -3
 1@@ -36,15 +36,15 @@ cflags{
 2 	'-D __TRANSMISSION__',
 3 	'-I $dir',
 4 	'-I $srcdir',
 5-	'-I $srcdir/third-party',
 6-	'-I $srcdir/third-party/libb64/include',
 7-	'-I $srcdir/third-party/libnatpmp',
 8 	'-isystem $builddir/pkg/bearssl/include',
 9 	'-isystem $builddir/pkg/curl/include',
10 	'-isystem $builddir/pkg/libevent/include',
11 	'-isystem $builddir/pkg/libutp/include',
12 	'-isystem $builddir/pkg/zlib/include',
13 	'-isystem $builddir/pkg/openbsd/include',
14+	'-isystem $srcdir/third-party',
15+	'-isystem $srcdir/third-party/libb64/include',
16+	'-isystem $srcdir/third-party/libnatpmp',
17 	'-include config.h',
18 }
19 
+35, -0
 1@@ -0,0 +1,35 @@
 2+From 6a142118edf4a31922568bf7696615e63c71c49e Mon Sep 17 00:00:00 2001
 3+From: Michael Forney <mforney@mforney.org>
 4+Date: Mon, 28 Apr 2025 13:14:22 -0700
 5+Subject: [PATCH] Fix type signature of utp_on_overhead
 6+
 7+Our branch of libutp uses standard C99 types.
 8+---
 9+ libtransmission/peer-io.c | 4 ++--
10+ 1 file changed, 2 insertions(+), 2 deletions(-)
11+
12+diff --git a/libtransmission/peer-io.c b/libtransmission/peer-io.c
13+index cbdc85a2f..49e7e313d 100644
14+--- a/libtransmission/peer-io.c
15++++ b/libtransmission/peer-io.c
16+@@ -554,7 +554,7 @@ static void utp_on_error(void* closure, int errcode)
17+     }
18+ }
19+ 
20+-static void utp_on_overhead(void* closure, uint8_t /* bool */ send, size_t count, int type UNUSED)
21++static void utp_on_overhead(void* closure, bool send, size_t count, int type UNUSED)
22+ {
23+     tr_peerIo* io = closure;
24+ 
25+@@ -606,7 +606,7 @@ static void dummy_on_error(void* closure UNUSED, int errcode UNUSED)
26+ {
27+ }
28+ 
29+-static void dummy_on_overhead(void* closure UNUSED, uint8_t /* bool */ send UNUSED, size_t count UNUSED, int type UNUSED)
30++static void dummy_on_overhead(void* closure UNUSED, bool send UNUSED, size_t count UNUSED, int type UNUSED)
31+ {
32+ }
33+ 
34+-- 
35+2.45.2
36+
+1, -1
1@@ -1 +1 @@
2-3.00 r2
3+3.00 r3