Skip to contentSkip to conversation

arm/optee-test: don't attempt to build with musl

PATCH Applied Ross Burton 2 participants 2 messages Nov 2, 2020 – Nov 3, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm/optee-test: don't attempt to build with musl

optee-test doesn't build on musl (or bionic) because libstdc++.a under musl depends on libc providing the pthread functions, but TAs are built without a libc.

Until this is fixed upstream (see https://github.com/OP-TEE/optee_test/issues/458)
simply refuse to build optee-test with musl.

Change-Id If73fd43683e19e2943bf54f4027806786fb1dc7d
---
 meta-arm/recipes-security/optee/optee-test.inc | 4 ++++
 1 file changed, 4 insertions(+)
meta-arm/recipes-security/optee/optee-test.inc +4 -0
index 467e687..eb11a12 100644
@@ -8,6 +8,10 @@ LIC_FILES_CHKSUM = "file://${S}/LICENSE.md;md5=daa2bcccc666345ab8940aab1315a4fa"
 inherit python3native
 require optee.inc
 
+# Linking fails on musl due to C++/threads
+# https://github.com/OP-TEE/optee_test/issues/458#issuecomment-720540834
+COMPATIBLE_HOST_libc-musl = 'null'
+
 DEPENDS = "optee-client optee-os python3-pycryptodomex-native"
 
 SRC_URI = "git://github.com/OP-TEE/optee_test.git \
Signature · 1 line
2.25.1
Applied
#1 lore raw
Quoted 9 lines · Ross Burton

optee-test doesn't build on musl (or bionic) because libstdc++.a under musl depends on libc providing the pthread functions, but TAs are built without a libc.

Until this is fixed upstream (see https://github.com/OP-TEE/optee_test/issues/458)
simply refuse to build optee-test with musl.

Change-Id If73fd43683e19e2943bf54f4027806786fb1dc7d

Applied to master.

Thanks,
Jon

Quoted 26 lines
---
 meta-arm/recipes-security/optee/optee-test.inc | 4 ++++
 1 file changed, 4 insertions(+)
meta-arm/recipes-security/optee/optee-test.inc +4 -0
index 467e687..eb11a12 100644
@@ -8,6 +8,10 @@ LIC_FILES_CHKSUM = "file://${S}/LICENSE.md;md5=daa2bcccc666345ab8940aab1315a4fa"
 inherit python3native
 require optee.inc
 
+# Linking fails on musl due to C++/threads
+# https://github.com/OP-TEE/optee_test/issues/458#issuecomment-720540834
+COMPATIBLE_HOST_libc-musl = 'null'
+
 DEPENDS = "optee-client optee-os python3-pycryptodomex-native"
 
 SRC_URI = "git://github.com/OP-TEE/optee_test.git \
Signature · 1 line
2.25.1