diff options
author | mark.yang <mark.yang@lge.com> | 2025-04-07 17:51:21 +0900 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2025-04-07 07:39:10 -0700 |
commit | 0f221af63e3a86764250354e2fe2d4a0e294ff48 (patch) | |
tree | 2f92cecf81882f7b758bcee0a67f7d9bc3b3fdae | |
parent | 5cf1a1040501f467d9cd228c1a57a28f0e7ea926 (diff) | |
download | meta-openembedded-0f221af63e3a86764250354e2fe2d4a0e294ff48.tar.gz |
srecord: fix build failure with gcc-15
srecord/input/file/hp64k.h:82:21: error: ‘uint16_t’ has not been declared
82 | bool read_u16be(uint16_t *dest);
| ^~~~~~~~
/home/abuild/rpmbuild/BUILD/srecord-1.65.0-build/srecord-1.65.0-Source/./srecord/input/file/hp64k.h:1:1: note: ‘uint16_t’ is defined in header ‘<cstdint>’; this is probably fixable by adding ‘#include <cstdint>’
+++ |+#include <cstdint>
1 | //
make[2]: *** [srecord/CMakeFiles/lib_srecord.dir/build.make:222: srecord/CMakeFiles/lib_srecord.dir/arglex/tool/input.cc.o] Error 1
* From gcc 13, cstdint header must be explicitly included for uint_X data types.
* See also: https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes
Signed-off-by: mark.yang <mark.yang@lge.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-oe/recipes-support/srecord/files/0001-fix-build-failure-with-gcc-15-by-adding-cstdint-head.patch | 36 | ||||
-rw-r--r-- | meta-oe/recipes-support/srecord/srecord_1.65.0.bb | 4 |
2 files changed, 39 insertions, 1 deletions
diff --git a/meta-oe/recipes-support/srecord/files/0001-fix-build-failure-with-gcc-15-by-adding-cstdint-head.patch b/meta-oe/recipes-support/srecord/files/0001-fix-build-failure-with-gcc-15-by-adding-cstdint-head.patch new file mode 100644 index 0000000000..fe55fc5c87 --- /dev/null +++ b/meta-oe/recipes-support/srecord/files/0001-fix-build-failure-with-gcc-15-by-adding-cstdint-head.patch | |||
@@ -0,0 +1,36 @@ | |||
1 | From 69290e4d727492a63a2a4424368a476b86ef8183 Mon Sep 17 00:00:00 2001 | ||
2 | From: "mark.yang" <mark.yang@lge.com> | ||
3 | Date: Mon, 7 Apr 2025 17:18:34 +0900 | ||
4 | Subject: [PATCH] fix build failure with gcc 15 by adding cstdint header | ||
5 | |||
6 | Fixes #79 | ||
7 | |||
8 | srecord/input/file/hp64k.h:82:21: error: ‘uint16_t’ has not been declared | ||
9 | 82 | bool read_u16be(uint16_t *dest); | ||
10 | | ^~~~~~~~ | ||
11 | /home/abuild/rpmbuild/BUILD/srecord-1.65.0-build/srecord-1.65.0-Source/./srecord/input/file/hp64k.h:1:1: note: ‘uint16_t’ is defined in header ‘<cstdint>’; this is probably fixable by adding ‘#include <cstdint>’ | ||
12 | +++ |+#include <cstdint> | ||
13 | 1 | // | ||
14 | make[2]: *** [srecord/CMakeFiles/lib_srecord.dir/build.make:222: srecord/CMakeFiles/lib_srecord.dir/arglex/tool/input.cc.o] Error 1 | ||
15 | |||
16 | * From gcc 13, cstdint header must be explicitly included for uint_X data types. | ||
17 | * See also: https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes | ||
18 | |||
19 | Upstream-Status: Submitted [https://github.com/sierrafoxtrot/srecord/pull/80] | ||
20 | Signed-off-by: mark.yang <mark.yang@lge.com> | ||
21 | --- | ||
22 | srecord/input/file/hp64k.h | 1 + | ||
23 | 1 file changed, 1 insertion(+) | ||
24 | |||
25 | diff --git a/srecord/input/file/hp64k.h b/srecord/input/file/hp64k.h | ||
26 | index a3f8a6d..205e1e4 100644 | ||
27 | --- a/srecord/input/file/hp64k.h | ||
28 | +++ b/srecord/input/file/hp64k.h | ||
29 | @@ -21,6 +21,7 @@ | ||
30 | #define LIB_INPUT_FILE_HP64K | ||
31 | |||
32 | #include <srecord/input/file.h> | ||
33 | +#include <cstdint> | ||
34 | |||
35 | namespace srecord { | ||
36 | |||
diff --git a/meta-oe/recipes-support/srecord/srecord_1.65.0.bb b/meta-oe/recipes-support/srecord/srecord_1.65.0.bb index 3e8a87d07f..b4294975bd 100644 --- a/meta-oe/recipes-support/srecord/srecord_1.65.0.bb +++ b/meta-oe/recipes-support/srecord/srecord_1.65.0.bb | |||
@@ -7,7 +7,9 @@ SRC_URI = " \ | |||
7 | https://sourceforge.net/projects/${BPN}/files/srecord/${@oe.utils.trim_version('${PV}', 2)}/${BP}-Source.tar.gz \ | 7 | https://sourceforge.net/projects/${BPN}/files/srecord/${@oe.utils.trim_version('${PV}', 2)}/${BP}-Source.tar.gz \ |
8 | file://0001-Disable-doxygen.patch \ | 8 | file://0001-Disable-doxygen.patch \ |
9 | file://0001-cmake-Do-not-try-to-compute-library-dependencies-dur.patch \ | 9 | file://0001-cmake-Do-not-try-to-compute-library-dependencies-dur.patch \ |
10 | file://0001-cmake-respect-explicit-install-prefix.patch" | 10 | file://0001-cmake-respect-explicit-install-prefix.patch \ |
11 | file://0001-fix-build-failure-with-gcc-15-by-adding-cstdint-head.patch \ | ||
12 | " | ||
11 | SRC_URI[sha256sum] = "81c3d07cf15ce50441f43a82cefd0ac32767c535b5291bcc41bd2311d1337644" | 13 | SRC_URI[sha256sum] = "81c3d07cf15ce50441f43a82cefd0ac32767c535b5291bcc41bd2311d1337644" |
12 | S = "${WORKDIR}/${BP}-Source" | 14 | S = "${WORKDIR}/${BP}-Source" |
13 | 15 | ||