summaryrefslogtreecommitdiffstats
path: root/meta-networking
diff options
context:
space:
mode:
authormark.yang <mark.yang@lge.com>2025-04-02 14:56:03 +0900
committerKhem Raj <raj.khem@gmail.com>2025-04-01 23:08:15 -0700
commitf452fa2fceae0abb6a614b232f1875b89ef4dd8f (patch)
tree485fb2b5aa2a2b4d000a4d75b89b127f39d280db /meta-networking
parent41723a2a7dc2b1bcfeebdae728c19be091637edc (diff)
downloadmeta-openembedded-f452fa2fceae0abb6a614b232f1875b89ef4dd8f.tar.gz
freediameter: fix build with gcc-15.0.1
* backport fix from: https://github.com/freeDiameter/freeDiameter/issues/72 https://github.com/freeDiameter/freeDiameter/commit/a54f10082f819dadfa6931166e71edffadb565dd to fix: http://errors.yoctoproject.org/Errors/Details/850312/ TOPDIR/tmp/work/qemux86_64-oe-linux/freediameter/1.5.0+git/git/libfdcore/sctp.c:622:21: note: 'bool' is a keyword with '-std=c23' onwards TOPDIR/tmp/work/qemux86_64-oe-linux/freediameter/1.5.0+git/git/libfdcore/sctp.c:622:26: error: expected identifier or '(' before '=' token 622 | int bool = 1; | ^ Signed-off-by: mark.yang <mark.yang@lge.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-networking')
-rw-r--r--meta-networking/recipes-protocols/freediameter/files/0001-fixes-for-gcc-15.patch69
-rw-r--r--meta-networking/recipes-protocols/freediameter/freediameter_1.5.0.bb1
2 files changed, 70 insertions, 0 deletions
diff --git a/meta-networking/recipes-protocols/freediameter/files/0001-fixes-for-gcc-15.patch b/meta-networking/recipes-protocols/freediameter/files/0001-fixes-for-gcc-15.patch
new file mode 100644
index 0000000000..41aeec4ee0
--- /dev/null
+++ b/meta-networking/recipes-protocols/freediameter/files/0001-fixes-for-gcc-15.patch
@@ -0,0 +1,69 @@
1From a54f10082f819dadfa6931166e71edffadb565dd Mon Sep 17 00:00:00 2001
2From: Victor Seva <vseva@debian.org>
3Date: Sun, 23 Feb 2025 13:38:48 +0100
4Subject: [PATCH] fixes for gcc-15
5
6fixes #72
7
8Upstream-Status: Backport [https://github.com/freeDiameter/freeDiameter/commit/a54f10082f819dadfa6931166e71edffadb565dd]
9Signed-off-by: mark.yang <mark.yang@lge.com>
10---
11 libfdcore/sctp.c | 22 +++++++++++-----------
12 1 file changed, 11 insertions(+), 11 deletions(-)
13
14diff --git a/libfdcore/sctp.c b/libfdcore/sctp.c
15index 95e822e..a4a7f40 100644
16--- a/libfdcore/sctp.c
17+++ b/libfdcore/sctp.c
18@@ -532,29 +532,29 @@ static int fd_setsockopt_prebind(int sk)
19 /* SCTP_EXPLICIT_EOR: we assume implicit EOR in freeDiameter, so let's ensure this is known by the stack */
20 #ifdef SCTP_EXPLICIT_EOR
21 {
22- int bool;
23+ int _bool;
24
25 if (TRACE_BOOL(ANNOYING)) {
26 sz = sizeof(bool);
27 /* Read socket defaults */
28- CHECK_SYS( getsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &bool, &sz) );
29- if (sz != sizeof(bool))
30+ CHECK_SYS( getsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &_bool, &sz) );
31+ if (sz != sizeof(_bool))
32 {
33- TRACE_DEBUG(INFO, "Invalid size of socket option: %d / %d", sz, (socklen_t)sizeof(bool));
34+ TRACE_DEBUG(INFO, "Invalid size of socket option: %d / %d", sz, (socklen_t)sizeof(_bool));
35 return ENOTSUP;
36 }
37- fd_log_debug( "Def SCTP_EXPLICIT_EOR value : %s", bool ? "true" : "false");
38+ fd_log_debug( "Def SCTP_EXPLICIT_EOR value : %s", _bool ? "true" : "false");
39 }
40
41- bool = 0;
42+ _bool = 0;
43
44 /* Set the option to the socket */
45- CHECK_SYS( setsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &bool, sizeof(bool)) );
46+ CHECK_SYS( setsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &_bool, sizeof(_bool)) );
47
48 if (TRACE_BOOL(ANNOYING)) {
49 /* Check new values */
50- CHECK_SYS( getsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &bool, &sz) );
51- fd_log_debug( "New SCTP_EXPLICIT_EOR value : %s", bool ? "true" : "false");
52+ CHECK_SYS( getsockopt(sk, IPPROTO_SCTP, SCTP_EXPLICIT_EOR, &_bool, &sz) );
53+ fd_log_debug( "New SCTP_EXPLICIT_EOR value : %s", _bool ? "true" : "false");
54 }
55 }
56 #else /* SCTP_EXPLICIT_EOR */
57@@ -619,10 +619,10 @@ static int fd_setsockopt_prebind(int sk)
58
59 #ifdef SCTP_RECVRCVINFO /* Replaces SCTP_SNDRCV */
60 {
61- int bool = 1;
62+ int _bool = 1;
63
64 /* Set the option to the socket */
65- CHECK_SYS( setsockopt(sk, IPPROTO_SCTP, SCTP_RECVRCVINFO, &bool, sizeof(bool)) );
66+ CHECK_SYS( setsockopt(sk, IPPROTO_SCTP, SCTP_RECVRCVINFO, &_bool, sizeof(_bool)) );
67
68 }
69 #else /* SCTP_RECVRCVINFO */
diff --git a/meta-networking/recipes-protocols/freediameter/freediameter_1.5.0.bb b/meta-networking/recipes-protocols/freediameter/freediameter_1.5.0.bb
index c9756c941e..15368a9a3d 100644
--- a/meta-networking/recipes-protocols/freediameter/freediameter_1.5.0.bb
+++ b/meta-networking/recipes-protocols/freediameter/freediameter_1.5.0.bb
@@ -24,6 +24,7 @@ SRC_URI = "git://github.com/freeDiameter/freeDiameter;protocol=https;branch=mast
24 file://install_test.patch \ 24 file://install_test.patch \
25 file://0001-tests-use-EXTENSIONS_DIR.patch \ 25 file://0001-tests-use-EXTENSIONS_DIR.patch \
26 file://0001-bison-flex-Add-flags-for-carrying-user-specified-par.patch \ 26 file://0001-bison-flex-Add-flags-for-carrying-user-specified-par.patch \
27 file://0001-fixes-for-gcc-15.patch \
27 " 28 "
28 29
29S = "${WORKDIR}/git" 30S = "${WORKDIR}/git"