summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRonan Le Martret <ronan.lemartret@iot.bzh>2021-02-15 09:46:36 +0100
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2021-03-22 17:40:55 +0000
commit2ed2109420656bebffdc8294555072755b0278aa (patch)
tree95885884e199987b6b0f68c3d0ea3c695e7a0a74
parent4d989ef3ad5d75453b4710bc06cefeba0d79fa32 (diff)
[RCAR] u-boot: move redundant-yyloc-global patch to u-boot-common.inc
gcc10 build issue occurs in both u-boot and u-boot-tools (From OE-Core rev: 2e128a775a3d51dc1856a35e2f5135d3c156d10e) Bug-AGL: SPEC-3850 Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh> Change-Id: I8da0a4664486c302da56a1c74947f1475193d017 Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/26187 Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> Tested-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
-rw-r--r--meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/files/remove-redundant-yyloc-global.patch27
-rw-r--r--meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/u-boot_2020.01.bbappend3
2 files changed, 30 insertions, 0 deletions
diff --git a/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/files/remove-redundant-yyloc-global.patch b/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/files/remove-redundant-yyloc-global.patch
new file mode 100644
index 000000000..2a184e57e
--- /dev/null
+++ b/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/files/remove-redundant-yyloc-global.patch
@@ -0,0 +1,27 @@
+From 018921ee79d3f30893614b3b2b63b588d8544f73 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Thu, 30 Jan 2020 09:37:15 +0000
+Subject: [PATCH] Remove redundant YYLOC global declaration
+
+Same as the upstream fix for building dtc with gcc 10.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+---
+ scripts/dtc/dtc-lexer.l | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
+index fd825ebba6..24af549977 100644
+--- a/scripts/dtc/dtc-lexer.l
++++ b/scripts/dtc/dtc-lexer.l
+@@ -38,7 +38,6 @@ LINECOMMENT "//".*\n
+ #include "srcpos.h"
+ #include "dtc-parser.tab.h"
+
+-YYLTYPE yylloc;
+ extern bool treesource_error;
+
+ /* CAUTION: this will stop working if we ever use yyless() or yyunput() */
+--
+2.26.2
+
diff --git a/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/u-boot_2020.01.bbappend b/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/u-boot_2020.01.bbappend
new file mode 100644
index 000000000..b8b5cbea5
--- /dev/null
+++ b/meta-agl-bsp/meta-rcar-gen3/recipes-bsp/u-boot/u-boot_2020.01.bbappend
@@ -0,0 +1,3 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
+
+SRC_URI_append = " file://remove-redundant-yyloc-global.patch "
ord.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
require ../../include/rcar-gen2-modules-common.inc

LICENSE = "GPLv2&MIT"
LIC_FILES_CHKSUM = "file://uvcs/include/GPL-COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
    file://uvcs/include/MIT-COPYING;md5=fea016ce2bdf2ec10080f69e9381d378 \
"
DEPENDS = "linux-renesas"
PN = "uvcs-kernel-module"
PR = "r0"
SRC_URI = "file://uvcs-kernel.tar.bz2"
S = "${WORKDIR}"

export UVCS_DRV_SRC_DIR = "${S}/uvcs/source/uvcs_lkm"
export UVCS_CMN_SRC_DIR = "${S}/uvcs/source/uvcs_cmn"
export UVCS_CMN_INC_DIR = "${S}/uvcs/include"
export DRV_CORE_SRC_DIR = "${S}/uvcs/source/driver_core"

do_compile() {
    cd ${S}/uvcs/source/makefile/linaro_4_7_3/
    make clean ARCH=arm
    make all ARCH=arm
}

do_install() {
    # Create destination folder
    mkdir -p ${D}/lib/modules/${KERNEL_VERSION}/extra/ ${D}/usr/src/kernel/include

    # Copy kernel module
    cp -f ${S}/uvcs/source/makefile/linaro_4_7_3/uvcs_cmn.ko ${D}/lib/modules/${KERNEL_VERSION}/extra/uvcs_cmn.ko

    # Copy shared header files
    cp -f ${S}/uvcs/include/uvcs_cmn.h  ${D}/usr/src/kernel/include
    cp -f ${S}/uvcs/include/uvcs_types.h  ${D}/usr/src/kernel/include
    cp -f ${S}/uvcs/source/makefile/linaro_4_7_3/Module.symvers  ${D}/usr/src/kernel/include/uvcs.symvers

    cp -f ${S}/uvcs/include/uvcs_cmn.h  ${KERNELSRC}/include/
    cp -f ${S}/uvcs/include/uvcs_types.h  ${KERNELSRC}/include/
    cp -f ${S}/uvcs/source/makefile/linaro_4_7_3/Module.symvers  ${KERNELSRC}/include/uvcs.symvers
}

# Append function to clean extract source
do_cleansstate_prepend() {
        bb.build.exec_func('do_clean_source', d)
}

do_clean_source() {
	rm -f ${KERNELSRC}/include/uvcs_cmn.h ${KERNELSRC}/include/uvcs_types.h
	rm -f ${KERNELSRC}/include/uvcs.symvers
}

PACKAGES = "\
    ${PN} \
    ${PN}-dev \
"

FILES_${PN} = " \
    /lib/modules/${KERNEL_VERSION}/extra/uvcs_cmn.ko \
"
FILES_${PN}-dev = " \
    /usr/src/kernel/include \
    /usr/src/kernel/include/*.h \
    /usr/src/kernel/include/uvcs.symvers \
"

RPROVIDES_${PN} += "uvcs-kernel-module"
INHIBIT_PACKAGE_DEBUG_SPLIT = "1"

python do_package_ipk_prepend () {
    d.setVar('ALLOW_EMPTY', '1')
}