summaryrefslogtreecommitdiffstats
path: root/recipes-bsp
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2017-02-11 09:56:08 +0000
committerKhem Raj <raj.khem@gmail.com>2017-02-11 09:56:08 +0000
commita96a442813d9990406cee5213db5e2b8b1a69bed (patch)
treef413e2d25d09bd59ee327f0ec922eb9df923290f /recipes-bsp
parent69ee819e00f5c879d6c95d294fa6ec88ab871005 (diff)
downloadmeta-clang-a96a442813d9990406cee5213db5e2b8b1a69bed.tar.gz
systemd-boot: Dont use -O0 with clang
Clang has a bug where it emits "memset" into code even when we use -ffreestanding. As a workaround compile with -O1 when using clang Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'recipes-bsp')
-rw-r--r--recipes-bsp/systemd-boot/systemd-boot_%.bbappend8
1 files changed, 8 insertions, 0 deletions
diff --git a/recipes-bsp/systemd-boot/systemd-boot_%.bbappend b/recipes-bsp/systemd-boot/systemd-boot_%.bbappend
new file mode 100644
index 0000000..d73f64c
--- /dev/null
+++ b/recipes-bsp/systemd-boot/systemd-boot_%.bbappend
@@ -0,0 +1,8 @@
1do_configure_append_toolchain-clang() {
2 export NM="${HOST_PREFIX}nm"
3 export AR="${HOST_PREFIX}ar"
4 export RANLIB="${HOST_PREFIX}ranlib"
5 export EFI_CC="${CC}"
6 sed -i -e "s#O0#O#g" ${S}/Makefile.am
7}
8