Skip to content

Commit

Permalink
optee_rust_examples_ext: add missing dependency on optee_client_ext
Browse files Browse the repository at this point in the history
The Rust examples need the OP-TEE client libray so add the proper
dependency to
br-ext/package/optee_rust_examples_ext/optee_rust_examples_ext.mk.
Fixes the following error:

 $ make -j$(nproc) OPTEE_RUST_ENABLE=y buildroot
 ...
 error: linking with `aarch64-linux-gnu-gcc` failed: exit status: 1
   |
   = note: "aarch64-linux-gnu-gcc" "/root/optee_repo_qemu_v8/out-br/build/optee_rust_examples_ext-1.0/examples/acipher-rs/host/target/aarch64-unknown-linux-gnu/release/deps/acipher_rs-81173f6bf08a244c.acipher_rs.a4de9379-cgu.1.rcgu.o" "-Wl,--as-needed" "-L" "/root/optee_repo_qemu_v8/out-br/build/optee_rust_examples_ext-1.0/examples/acipher-rs/host/target/aarch64-unknown-linux-gnu/release/deps" "-L" "/root/optee_repo_qemu_v8/out-br/build/optee_rust_examples_ext-1.0/examples/acipher-rs/host/target/release/deps" "-L" "/root/optee_repo_qemu_v8/out-br/build/optee_rust_examples_ext-1.0/../../../out-br/build/optee_client_ext-1.0/libteec" "-L" "/root/.rustup/toolchains/nightly-2021-09-20-x86_64-unknown-linux-gnu/lib/rustlib/aarch64-unknown-linux-gnu/lib" "-Wl,--start-group" "-Wl,--end-group" "-Wl,-Bstatic" "/root/.rustup/toolchains/nightly-2021-09-20-x86_64-unknown-linux-gnu/lib/rustlib/aarch64-unknown-linux-gnu/lib/libcompiler_builtins-7aa4e75c33b75c4b.rlib" "-Wl,-Bdynamic" "-lteec" "-lgcc_s" "-lutil" "-lrt" "-lpthread" "-lm" "-ldl" "-lc" "-Wl,--eh-frame-hdr" "-Wl,-znoexecstack" "-L" "/root/.rustup/toolchains/nightly-2021-09-20-x86_64-unknown-linux-gnu/lib/rustlib/aarch64-unknown-linux-gnu/lib" "-o" "/root/optee_repo_qemu_v8/out-br/build/optee_rust_examples_ext-1.0/examples/acipher-rs/host/target/aarch64-unknown-linux-gnu/release/deps/acipher_rs-81173f6bf08a244c" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs"
   = note: /root/optee_repo_qemu_v8/toolchains/aarch64/bin/../lib/gcc/aarch64-none-linux-gnu/11.3.1/../../../../aarch64-none-linux-gnu/bin/ld: cannot find -lteec: No such file or directory
 collect2: error: ld returned 1 exit status

Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
  • Loading branch information
jforissier committed Oct 10, 2023
1 parent 076b93f commit dfc1f8f
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ OPTEE_RUST_EXAMPLES_EXT_SOURCE = local
OPTEE_RUST_EXAMPLES_EXT_SITE = $(BR2_PACKAGE_OPTEE_RUST_EXAMPLES_EXT_SITE)
OPTEE_RUST_EXAMPLES_EXT_SITE_METHOD = local
OPTEE_RUST_EXAMPLES_EXT_INSTALL_STAGING = YES
OPTEE_RUST_EXAMPLES_EXT_DEPENDENCIES = optee_client_ext

ifneq (,$(BR2_PACKAGE_OPTEE_RUST_EXAMPLES_TC_PATH_ENV))
OPTEE_RUST_EXAMPLES_TC_PATH_ENV = PATH=$(BR2_PACKAGE_OPTEE_RUST_EXAMPLES_TC_PATH_ENV)
Expand Down

0 comments on commit dfc1f8f

Please sign in to comment.