aboutsummaryrefslogtreecommitdiff
path: root/core/core.mk
diff options
context:
space:
mode:
authorJens Wiklander <jens.wiklander@linaro.org>2019-03-22 08:35:53 +0100
committerJérôme Forissier <jerome.forissier@linaro.org>2019-03-22 20:09:28 +0100
commitfa788ef9d13ae9a9b9581cf872095bb9ff3878ab (patch)
treee2bd1b8bbe3577462037a4ecf54fdf65448db23f /core/core.mk
parent18dd462bc7a7c1f2ada6fa22b51e590af64b5d78 (diff)
Only clear base-prefix for crypto libraries in core
If the crypto library selected with CFG_CRYPTOLIB_NAME and CFG_CRYPTOLIB_DIR resides under core it's OK to clear base-prefix. However, if it can be compiled for user space too we need to keep base-prefix in order to avoid output conflicts. Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Diffstat (limited to 'core/core.mk')
-rw-r--r--core/core.mk7
1 files changed, 7 insertions, 0 deletions
diff --git a/core/core.mk b/core/core.mk
index c4af96cc..08aff0b4 100644
--- a/core/core.mk
+++ b/core/core.mk
@@ -101,12 +101,19 @@ libdir = lib/libmpa
include mk/lib.mk
endif
+ifeq ($(firstword $(subst /, ,$(CFG_CRYPTOLIB_DIR))),core)
+# If a library can be compiled for both core and user space a base-prefix
+# is needed in order to avoid conflicts in the output. However, if the
+# library resides under core then it can't be compiled to user space.
base-prefix :=
+endif
libname = $(CFG_CRYPTOLIB_NAME)
libdir = $(CFG_CRYPTOLIB_DIR)
include mk/lib.mk
+base-prefix :=
+
ifeq ($(CFG_DT),y)
libname = fdt
libdir = core/lib/libfdt