diff options
| author | Martin Jansa <martin.jansa@gmail.com> | 2024-06-01 15:15:31 +0200 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2024-06-01 10:49:41 -0700 |
| commit | dc942a392f550e1f4cbb467dd4163d3735c4ae6d (patch) | |
| tree | 9b713bdb9c8afa2d8c16bf4ae6cebc4ad7f0c958 | |
| parent | 1a5807e4c77bf8a64271ef28704b5c13d2ae405a (diff) | |
| download | meta-openembedded-dc942a392f550e1f4cbb467dd4163d3735c4ae6d.tar.gz | |
libgphoto2: fix build with gcc-14
Fixes:
libgphoto2-2.5.31/camlibs/ptp2/chdk.c:1187:41: error: passing argument 3 of 'jpeg_mem_dest' from incompatible pointer type [-Wincompatible-pointer-types]
https://github.com/gphoto/libgphoto2/issues/959
https://github.com/gphoto/libgphoto2/issues/941
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
| -rw-r--r-- | meta-oe/recipes-graphics/gphoto2/libgphoto2/fix-build-with-gcc-14.patch | 36 | ||||
| -rw-r--r-- | meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.31.bb | 1 |
2 files changed, 37 insertions, 0 deletions
diff --git a/meta-oe/recipes-graphics/gphoto2/libgphoto2/fix-build-with-gcc-14.patch b/meta-oe/recipes-graphics/gphoto2/libgphoto2/fix-build-with-gcc-14.patch new file mode 100644 index 0000000000..0c2a8d4bd0 --- /dev/null +++ b/meta-oe/recipes-graphics/gphoto2/libgphoto2/fix-build-with-gcc-14.patch | |||
| @@ -0,0 +1,36 @@ | |||
| 1 | From 721f7f8c3ec8058d504607873e4c317aac0c99c5 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Marcus Meissner <marcus@jet.franken.de> | ||
| 3 | Date: Mon, 4 Dec 2023 13:26:08 +0100 | ||
| 4 | Subject: [PATCH] align outlen length with jpeg jeaders. fixes | ||
| 5 | https://github.com/gphoto/libgphoto2/issues/941 | ||
| 6 | |||
| 7 | --- | ||
| 8 | Upstream-Status: Backport [https://github.com/gphoto/libgphoto2/commit/721f7f8c3ec8058d504607873e4c317aac0c99c5] | ||
| 9 | |||
| 10 | camlibs/ptp2/chdk.c | 6 +++--- | ||
| 11 | 1 file changed, 3 insertions(+), 3 deletions(-) | ||
| 12 | |||
| 13 | diff --git a/camlibs/ptp2/chdk.c b/camlibs/ptp2/chdk.c | ||
| 14 | index e1d898f378..e775ea1d4b 100644 | ||
| 15 | --- a/camlibs/ptp2/chdk.c | ||
| 16 | +++ b/camlibs/ptp2/chdk.c | ||
| 17 | @@ -1150,7 +1150,7 @@ static void yuv_live_to_jpeg(unsigned char *p_yuv, | ||
| 18 | struct jpeg_error_mgr jerr; | ||
| 19 | JSAMPROW row_ptr[1]; | ||
| 20 | uint8_t *outbuf = NULL, *tmprowbuf = NULL; | ||
| 21 | - uint64_t outlen = 0; | ||
| 22 | + unsigned long outlen = 0; | ||
| 23 | unsigned int row_inc; | ||
| 24 | int sshift, dshift, xshift, skip; | ||
| 25 | |||
| 26 | @@ -1161,8 +1161,8 @@ static void yuv_live_to_jpeg(unsigned char *p_yuv, | ||
| 27 | sshift = 6; | ||
| 28 | dshift = (width/height > 2) ? 6 : 12; | ||
| 29 | xshift = 4; | ||
| 30 | - /* Digic 6 cameras: 8 bit per element UYVY, | ||
| 31 | - * 4 bytes used to encode 2 pixels, need 6 bytes raw YUV data for jpeg encoding */ | ||
| 32 | + /* Digic 6 cameras: 8 bit per element UYVY, | ||
| 33 | + * 4 bytes used to encode 2 pixels, need 6 bytes raw YUV data for jpeg encoding */ | ||
| 34 | } else { | ||
| 35 | row_inc = buf_width*2; | ||
| 36 | sshift = 4; | ||
diff --git a/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.31.bb b/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.31.bb index 1d0b37826d..57c9d199eb 100644 --- a/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.31.bb +++ b/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.31.bb | |||
| @@ -13,6 +13,7 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/gphoto/libgphoto2-${PV}.tar.bz2;name=libgphoto2 | |||
| 13 | file://40-libgphoto2.rules \ | 13 | file://40-libgphoto2.rules \ |
| 14 | file://0001-configure.ac-remove-AM_PO_SUBDIRS.patch \ | 14 | file://0001-configure.ac-remove-AM_PO_SUBDIRS.patch \ |
| 15 | file://0001-configure-Filter-out-buildpaths-from-CC.patch \ | 15 | file://0001-configure-Filter-out-buildpaths-from-CC.patch \ |
| 16 | file://fix-build-with-gcc-14.patch \ | ||
| 16 | " | 17 | " |
| 17 | SRC_URI[libgphoto2.sha256sum] = "4f81c34c0b812bee67afd5f144940fbcbe01a2055586a6a1fa2d0626024a545b" | 18 | SRC_URI[libgphoto2.sha256sum] = "4f81c34c0b812bee67afd5f144940fbcbe01a2055586a6a1fa2d0626024a545b" |
| 18 | 19 | ||
