From: Christian Melki <christian.melki@t2data.com>
To: ptxdist@pengutronix.de
Subject: [ptxdist] [PATCH] libsndfile: Add upstream patch for gcc 15 build errors.
Date: Thu, 8 May 2025 20:30:39 +0200 [thread overview]
Message-ID: <20250508183039.1884302-1-christian.melki@t2data.com> (raw)
* Adjust slightly with offsets to apply cleanly.
Signed-off-by: Christian Melki <christian.melki@t2data.com>
---
...h-instead-of-redefining-bool-true-an.patch | 60 +++++++++++++++++++
patches/libsndfile-1.2.2/series | 4 ++
2 files changed, 64 insertions(+)
create mode 100644 patches/libsndfile-1.2.2/0001-Include-stdbool.h-instead-of-redefining-bool-true-an.patch
create mode 100644 patches/libsndfile-1.2.2/series
diff --git a/patches/libsndfile-1.2.2/0001-Include-stdbool.h-instead-of-redefining-bool-true-an.patch b/patches/libsndfile-1.2.2/0001-Include-stdbool.h-instead-of-redefining-bool-true-an.patch
new file mode 100644
index 000000000..a48e2e79d
--- /dev/null
+++ b/patches/libsndfile-1.2.2/0001-Include-stdbool.h-instead-of-redefining-bool-true-an.patch
@@ -0,0 +1,60 @@
+From: Fabian Greffrath <fabian@greffrath.com>
+Date: Tue, 17 Dec 2024 10:38:47 +0100
+Subject: [PATCH] Include <stdbool.h> instead of redefining `bool`, `true` and
+ `false` keywords
+
+Fixes #1049
+---
+ src/ALAC/alac_decoder.c | 6 +-----
+ src/ALAC/alac_encoder.c | 7 +------
+ 2 files changed, 2 insertions(+), 11 deletions(-)
+
+diff --git a/src/ALAC/alac_decoder.c b/src/ALAC/alac_decoder.c
+index 46d3330607b3..1b4a87c08912 100644
+--- a/src/ALAC/alac_decoder.c
++++ b/src/ALAC/alac_decoder.c
+@@ -26,6 +26,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <stddef.h>
++#include <stdbool.h>
+ #include <string.h>
+
+ #include "alac_codec.h"
+@@ -38,11 +39,6 @@
+ #include "ALACBitUtilities.h"
+ #include "EndianPortable.h"
+
+-typedef enum
+-{ false = 0,
+- true = 1
+-} bool ;
+-
+ // constants/data
+ const uint32_t kMaxBitDepth = 32 ; // max allowed bit depth is 32
+
+diff --git a/src/ALAC/alac_encoder.c b/src/ALAC/alac_encoder.c
+index 599399afead9..f3033110ef76 100644
+--- a/src/ALAC/alac_encoder.c
++++ b/src/ALAC/alac_encoder.c
+@@ -30,6 +30,7 @@
+ // headers
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <stdbool.h>
+ #include <string.h>
+
+ #include "sfendian.h"
+@@ -44,12 +45,6 @@
+ #include "ALACAudioTypes.h"
+ #include "EndianPortable.h"
+
+-typedef enum
+-{
+- false = 0,
+- true = 1
+-} bool ;
+-
+ static void GetConfig (ALAC_ENCODER *p, ALACSpecificConfig * config) ;
+
+ static int32_t EncodeStereo (ALAC_ENCODER *p, struct BitBuffer * bitstream, const int32_t * input, uint32_t stride, uint32_t channelIndex, uint32_t numSamples) ;
diff --git a/patches/libsndfile-1.2.2/series b/patches/libsndfile-1.2.2/series
new file mode 100644
index 000000000..ed9ff5a00
--- /dev/null
+++ b/patches/libsndfile-1.2.2/series
@@ -0,0 +1,4 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-Include-stdbool.h-instead-of-redefining-bool-true-an.patch
+# f491a1ef802e784a567bb3baa0ecc242 - git-ptx-patches magic
--
2.34.1
reply other threads:[~2025-05-08 18:31 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250508183039.1884302-1-christian.melki@t2data.com \
--to=christian.melki@t2data.com \
--cc=ptxdist@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox