Skip to contentSkip to conversation

arm/optee-client: set parameter CFG_TEE_PLUGIN_LOAD_PATH as ${libdir}

PATCH In review Meng Li 2 participants 2 messages Mar 4, 2024

lore
Share & tools
lore

Meng Li

author
#0 lore raw

PATCH 1/1 arm/optee-client: set parameter CFG_TEE_PLUGIN_LOAD_PATH as ${libdir}

In optee-client package, the CFG_TEE_PLUGIN_LOAD_PATH is set as /usr/lib/tee-supplicant/plugins/. But when multilib is enabled in yocto, the ${libdir} is /usr/lib64, the optee-examples and optee-test package will install the plugins into usr/lib64. This will cause that optee feature doesn't work when it can't find out the necessary plugin. So, set parameter CFG_TEE_PLUGIN_LOAD_PATH as ${libdir} to support for multilib and non-multilib feature.

---
 meta-arm/recipes-security/optee/optee-client.inc | 1 +
 1 file changed, 1 insertion(+)
meta-arm/recipes-security/optee/optee-client.inc +1 -0
index 3b9943cc..ef03045c 100644
@@ -20,6 +20,7 @@ S = "${WORKDIR}/git"
 EXTRA_OECMAKE = " \
     -DBUILD_SHARED_LIBS=ON \
     -DCFG_TEE_FS_PARENT_PATH='${localstatedir}/lib/tee' \
+    -DCFG_TEE_PLUGIN_LOAD_PATH='${libdir}/tee-supplicant/plugins/' \
 "
 EXTRA_OECMAKE:append:toolchain-clang = " -DCFG_WERROR=0"
 
Signature · 1 line
2.34.1
Reviewed-by on v1 1/1
#1 lore raw

Hello Meng!

Quoted 9 lines · Meng Li via lists.yoctoproject.org

In optee-client package, the CFG_TEE_PLUGIN_LOAD_PATH is set as /usr/lib/tee-supplicant/plugins/. But when multilib is enabled in yocto, the ${libdir} is /usr/lib64, the optee-examples and optee-test package will install the plugins into usr/lib64. This will cause that optee feature doesn't work when it can't find out the necessary plugin. So, set parameter CFG_TEE_PLUGIN_LOAD_PATH as ${libdir} to support for multilib and non-multilib feature.

LGTM,

Quoted 15 lines

---
 meta-arm/recipes-security/optee/optee-client.inc | 1 +

 1 file changed, 1 insertion(+)
meta-arm/recipes-security/optee/optee-client.inc +1 -0
index 3b9943cc..ef03045c 100644
@@ -20,6 +20,7 @@ S = "${WORKDIR}/git"
  EXTRA_OECMAKE = " \
      -DBUILD_SHARED_LIBS=ON \
      -DCFG_TEE_FS_PARENT_PATH='${localstatedir}/lib/tee' \
+    -DCFG_TEE_PLUGIN_LOAD_PATH='${libdir}/tee-supplicant/plugins/' \

 "
 EXTRA_OECMAKE:append:toolchain-clang = " -DCFG_WERROR=0"

Signature · 3 lines
Alexander Sverdlin
Siemens AG
www.siemens.com