SolidRun / imx8mp_build

IMX8M Plus buildroot build script
5 stars 7 forks source link

TA fails to build from master branch #7

Open grealish opened 2 months ago

grealish commented 2 months ago

Hi, checking out a clean build DISTRO=debian ./runme.sh or in docker: docker run -i -t -v "$PWD":/work -e DISTRO=debian -e MANUFACTURER=SRDK imx8mp_build -u $(id -u) -g $(id -g)

Error output

 INSTALL out/arm-plat-imx/export-ta_arm64/ta/023f8f1a-292a-432b-8fc4-de8471358067.ta
  INSTALL out/arm-plat-imx/export-ta_arm64/ta/f04a0fe7-1f5d-4b9b-abf7-619b85b4ce8c.ta
  INSTALL out/arm-plat-imx/export-ta_arm64/ta/80a4c275-0a47-4905-8285-1486a9771a08.ta
  LD      out/arm-plat-imx/ta/pkcs11/fd02c9da-306c-48c7-a49c-bbd827ae86ee.elf
  OBJCOPY out/arm-plat-imx/ta/pkcs11/fd02c9da-306c-48c7-a49c-bbd827ae86ee.stripped.elf
  SIGN    out/arm-plat-imx/ta/pkcs11/fd02c9da-306c-48c7-a49c-bbd827ae86ee.ta
  INSTALL out/arm-plat-imx/export-ta_arm64/ta/fd02c9da-306c-48c7-a49c-bbd827ae86ee.ta
make -C fTPM CROSS_COMPILE=aarch64-none-elf-
make[1]: Entering directory '/home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/TAs/optee_ta/fTPM'
Clearing symlink to the TPM folder: /home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/external/ms-tpm-20-ref/TPMCmd
unlink ./lib/tpm/tpm_symlink || true
( cd ../../../external; git submodule update --init ms-tpm-20-ref)
Checking symlink to the TPM folder: /home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/external/ms-tpm-20-ref/TPMCmd
Establishing symlink.
Clearing symlink to the Wolf folder: /home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/external/wolfssl
unlink ./lib/wolf/wolf_symlink || true
Checking symlink to the WolfSSL folder: /home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/external/wolfssl
Establishing symlink.
make[1]: *** No rule to make target '/work/build/imx-optee-os/out/arm-plat-imx/export-ta_arm64/include/tee_internal_api.h', needed by '../out/fTPM/fTPM.o'.  Stop.
make[1]: Leaving directory '/home/grealish/dev/proj/solid-run/imx8mp_build_pr/build/ftpm/TAs/optee_ta/fTPM'

Is it possible that the actual build scripts that build https://images.solid-run.com/ could be included in this repo please as it's important that the images can be re-created based on a tag or version

grealish commented 1 month ago

Thanks @Josua-SR for pinning the upstream repo, I couldn't build still the image directly on the host, but It worked in docker, with this command: docker run -i -t -v "$PWD":/work -e DISTRO=debian -e MANUFACTURER=SRDK imx8mp_build -u $(id -u) -g $(id -g)


=================================
*** Creating boot loader image
=================================
imx8qm clean done
imx8qx clean done
imx8dxl clean done
imx8ulp clean done
imx8ulp clean done
Compiling mkimage_imx8
PLAT=imx8mp HDMI=no
Compiling mkimage_imx8
cc -O2 -Wall -std=c99 -static ../iMX8M/mkimage_imx8.c -o mkimage_imx8  -lz
37289+0 records in
37289+0 records out
149156 bytes (149 kB, 146 KiB) copied, 0.0489273 s, 3.0 MB/s
./../scripts/dtb_check.sh imx8mp-evk.dtb evk.dtb imx8mp-solidrun.dtb
Use u-boot DTB: imx8mp-solidrun.dtb
./../scripts/pad_image.sh /work/images/tmp/optee/tee-pager_v2.bin
/work/images/tmp/optee/tee-pager_v2.bin is padded to 833248
./../scripts/pad_image.sh bl31.bin
bl31.bin is padded to 45392
./../scripts/pad_image.sh u-boot-nodtb.bin evk.dtb
BL32=/work/images/tmp/optee/tee-pager_v2.bin DEK_BLOB_LOAD_ADDR=0x40400000 TEE_LOAD_ADDR=0x56000000 ATF_LOAD_ADDR=0x00970000 ../iMX8M/mkimage_fit_atf.sh evk.dtb > u-boot.its                                    bl31.bin size:
45392
Building with TEE support, make sure bl31.bin is compiled with spd. If you do not want tee, please delete /work/images/tmp/optee/tee-pager_v2.bin                                                                /work/images/tmp/optee/tee-pager_v2.bin size:
833248
u-boot-nodtb.bin size:

still working through the issue on the runme.sh build issue