mirror of
https://git.yoctoproject.org/meta-arm
synced 2026-07-27 07:27:04 +00:00
optee-os: fix build race
There's a rare build race where mk/conf.mk.tmp is written to before mk/ exists. Add an explicit mkdir so that this directory is sure to exist. Change-Id: I4e907f395679da9354d386301e7bf5da46afdbaf Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Jon Mason <jon.mason@arm.com>
This commit is contained in:
@@ -0,0 +1,31 @@
|
|||||||
|
Upstream-Status: Backport [https://github.com/OP-TEE/optee_os/pull/4000]
|
||||||
|
Signed-off-by: Ross Burton <ross.burton@arm.com>
|
||||||
|
|
||||||
|
From 79384a244d1972cdb02114f5cde6fcaf2e014c9b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Jerome Forissier <jerome@forissier.org>
|
||||||
|
Date: Tue, 28 Jul 2020 17:28:43 +0200
|
||||||
|
Subject: [PATCH] build: fix race when generating conf.mk
|
||||||
|
|
||||||
|
This patch fixes the following error triggered by a heavily parallel build:
|
||||||
|
|
||||||
|
echo sm := ta_arm64 > .../export-ta_arm64/mk/conf.mk.tmp
|
||||||
|
/bin/bash: .../export-ta_arm64/mk/conf.mk.tmp: No such file or directory
|
||||||
|
|
||||||
|
Fixes: https://github.com/OP-TEE/optee_os/issues/3999
|
||||||
|
Signed-off-by: Jerome Forissier <jerome@forissier.org>
|
||||||
|
---
|
||||||
|
ta/ta.mk | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/ta/ta.mk b/ta/ta.mk
|
||||||
|
index 59ed87f71d..ad97edaf08 100644
|
||||||
|
--- a/ta/ta.mk
|
||||||
|
+++ b/ta/ta.mk
|
||||||
|
@@ -190,6 +190,7 @@ define mk-file-export
|
||||||
|
.PHONY: $(conf-mk-file-export)
|
||||||
|
$(conf-mk-file-export):
|
||||||
|
@$$(cmd-echo-silent) ' CHK ' $$@
|
||||||
|
+ $(q)mkdir -p $$(dir $$@)
|
||||||
|
$(q)echo sm := $$(sm-$(conf-mk-file-export)) > $$@.tmp
|
||||||
|
$(q)echo sm-$$(sm-$(conf-mk-file-export)) := y >> $$@.tmp
|
||||||
|
$(q)($$(foreach v, $$(ta-mk-file-export-vars-$$(sm-$(conf-mk-file-export))), \
|
||||||
@@ -21,6 +21,7 @@ SRC_URI = " \
|
|||||||
file://0004-Cleanup-unused-comp-cflags-sm-from-libgcc-lookup-com.patch \
|
file://0004-Cleanup-unused-comp-cflags-sm-from-libgcc-lookup-com.patch \
|
||||||
file://0005-Fixup-Allow-use-of-cc-option-in-core-arch-arm-arm.mk.patch \
|
file://0005-Fixup-Allow-use-of-cc-option-in-core-arch-arm-arm.mk.patch \
|
||||||
file://0006-allow-setting-sysroot-for-libgcc-lookup.patch \
|
file://0006-allow-setting-sysroot-for-libgcc-lookup.patch \
|
||||||
|
file://missing-mkdir.patch \
|
||||||
"
|
"
|
||||||
|
|
||||||
S = "${WORKDIR}/git"
|
S = "${WORKDIR}/git"
|
||||||
|
|||||||
Reference in New Issue
Block a user