summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>2020-08-28 08:11:50 +0000
committerOtavio Salvador <otavio@ossystems.com.br>2020-08-28 08:40:39 -0300
commita6bf5c7b5c463caf96e8045b8d2dec5b66fe2bc1 (patch)
treecca1f57e9b64cd663e63d014b4e855720a13301a
parentcc9b020bcb5ece255d4c09f3cefd12b1e511d7fd (diff)
downloadmeta-freescale-a6bf5c7b5c463caf96e8045b8d2dec5b66fe2bc1.tar.gz
imx-vpu-hantro: fix compilation issues with -fcommon
GCC 10.2 is recently configured to include -fcommon per default, which results in compilation error with multiple definitions of enum names. Intoduce a patch which corrects double-defined enum names and resolves compilation of the component. Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com> Cc: Tom Hochstein <tom.hochstein@nxp.com>
-rw-r--r--recipes-bsp/imx-vpu-hantro/imx-vpu-hantro/0001-decoder_sw-resolve-compilation-error-with-fcommon.patch54
-rw-r--r--recipes-bsp/imx-vpu-hantro/imx-vpu-hantro_1.18.0.bb1
2 files changed, 55 insertions, 0 deletions
diff --git a/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro/0001-decoder_sw-resolve-compilation-error-with-fcommon.patch b/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro/0001-decoder_sw-resolve-compilation-error-with-fcommon.patch
new file mode 100644
index 00000000..8d9610d5
--- /dev/null
+++ b/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro/0001-decoder_sw-resolve-compilation-error-with-fcommon.patch
@@ -0,0 +1,54 @@
1From 5bfb24738c47003fd04a86bfd5a49f8c6354ed23 Mon Sep 17 00:00:00 2001
2From: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
3Date: Fri, 28 Aug 2020 07:46:35 +0000
4Subject: [PATCH] decoder_sw: resolve compilation error with -fcommon
5
6-fcommon is enabled by default in gcc10 compiler, which results in
7following build errors:
8
9decoder_sw/software/source/inc/decapicommon.h:272: multiple definition
10of `DecPicCodingType'; decoder_sw/software/linux/dwl/dwl_linux.o:
11decoder_sw/software/source/inc/decapicommon.h:272: first defined here
12
13decoder_sw/software/source/inc/dwl.h:94: multiple definition of
14`DWLInitParam'; decoder_sw/software/linux/dwl/dwl_linux.o:
15decoder_sw/software/source/inc/dwl.h:94: first defined here
16
17Drop multiple enum name definitions, which solves above compilation
18issues.
19
20Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
21---
22 decoder_sw/software/source/inc/decapicommon.h | 2 +-
23 decoder_sw/software/source/inc/dwl.h | 2 +-
24 2 files changed, 2 insertions(+), 2 deletions(-)
25
26diff --git a/decoder_sw/software/source/inc/decapicommon.h b/decoder_sw/software/source/inc/decapicommon.h
27index 0f02092..fc8cccf 100755
28--- a/decoder_sw/software/source/inc/decapicommon.h
29+++ b/decoder_sw/software/source/inc/decapicommon.h
30@@ -269,7 +269,7 @@ enum DecPicCodingType {
31 DEC_PIC_TYPE_D = 3,
32 DEC_PIC_TYPE_FI = 4,
33 DEC_PIC_TYPE_BI = 5
34-} DecPicCodingType;
35+};
36
37 /* Output picture pixel format types for raster scan or down scale output */
38 enum DecPicturePixelFormat {
39diff --git a/decoder_sw/software/source/inc/dwl.h b/decoder_sw/software/source/inc/dwl.h
40index 6991f03..fd357b3 100755
41--- a/decoder_sw/software/source/inc/dwl.h
42+++ b/decoder_sw/software/source/inc/dwl.h
43@@ -91,7 +91,7 @@ struct DWLLinearMem {
44 /* DWLInitParam is used to pass parameters when initializing the DWL */
45 struct DWLInitParam {
46 u32 client_type;
47-} DWLInitParam;
48+};
49
50 /* Hardware configuration description, same as in top API */
51 typedef struct DecHwConfig DWLHwConfig;
52--
532.17.1
54
diff --git a/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro_1.18.0.bb b/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro_1.18.0.bb
index 93206263..a950f548 100644
--- a/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro_1.18.0.bb
+++ b/recipes-bsp/imx-vpu-hantro/imx-vpu-hantro_1.18.0.bb
@@ -8,6 +8,7 @@ PROVIDES = "virtual/imxvpu"
8 8
9SRC_URI = " \ 9SRC_URI = " \
10 ${FSL_MIRROR}/${BPN}-${PV}.bin;fsl-eula=true \ 10 ${FSL_MIRROR}/${BPN}-${PV}.bin;fsl-eula=true \
11 file://0001-decoder_sw-resolve-compilation-error-with-fcommon.patch \
11" 12"
12SRC_URI[md5sum] = "78034de7ed74363eb793d29894bba5e3" 13SRC_URI[md5sum] = "78034de7ed74363eb793d29894bba5e3"
13SRC_URI[sha256sum] = "bebd82649d00d6dd8236b77b8677b1cc6ac46dc474200502df7797a75dc8f568" 14SRC_URI[sha256sum] = "bebd82649d00d6dd8236b77b8677b1cc6ac46dc474200502df7797a75dc8f568"