diff options
author | Daniel Golle <daniel@makrotopia.org> | 2021-02-03 14:41:50 +0000 |
---|---|---|
committer | Daniel Golle <daniel@makrotopia.org> | 2021-02-03 15:19:14 +0000 |
commit | 1f1d8d4f474aebbbb57937797966b7267fc70240 (patch) | |
tree | f244cbb6c0c384a9be06e1c33d1f790dd35890fb /package | |
parent | abe348168b282786208a1959d2a80794fdd82f2b (diff) | |
download | upstream-1f1d8d4f474aebbbb57937797966b7267fc70240.tar.gz upstream-1f1d8d4f474aebbbb57937797966b7267fc70240.tar.bz2 upstream-1f1d8d4f474aebbbb57937797966b7267fc70240.zip |
arm-trusted-firmware-tools: add package
Package ARM Trusted Firmware host tools separately.
(instead of building tfa-fiptool as part of tfa-layerscape)
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Diffstat (limited to 'package')
-rw-r--r-- | package/boot/arm-trusted-firmware-tools/Makefile | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/package/boot/arm-trusted-firmware-tools/Makefile b/package/boot/arm-trusted-firmware-tools/Makefile new file mode 100644 index 0000000000..af9957c3a9 --- /dev/null +++ b/package/boot/arm-trusted-firmware-tools/Makefile @@ -0,0 +1,70 @@ +# +# Copyright 2021 Daniel Golle +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=arm-trusted-firmware-tools +PKG_VERSION:=2.4 +PKG_RELEASE:=1 +PKG_HASH:=bf3eb3617a74cddd7fb0e0eacbfe38c3258ee07d4c8ed730deef7a175cc3d55b + +PKG_MAINTAINER:=Daniel Golle <daniel@makrotopia.org> +PKG_HOST_ONLY:=1 + +HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/trusted-firmware-a-$(PKG_VERSION) + +include $(INCLUDE_DIR)/trusted-firmware-a.mk +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/host-build.mk + +define Package/arm-trusted-firmware-tools + SECTION:=boot + CATEGORY:=Boot Loaders + TITLE:=ARM Trusted Firmware tools + URL:=https://www.trustedfirmware.org + BUILDONLY:=1 +endef + +HOST_CFLAGS += -Wall -Werror -pedantic -std=c99 +define Host/Compile + $(MAKE) -C \ + $(HOST_BUILD_DIR)/tools/cert_create \ + CFLAGS="$(HOST_CFLAGS)" \ + LDFLAGS="$(HOST_LDFLAGS)" + $(MAKE) -C \ + $(HOST_BUILD_DIR)/tools/encrypt_fw \ + CFLAGS="$(HOST_CFLAGS)" \ + LDFLAGS="$(HOST_LDFLAGS)" + $(MAKE) -C \ + $(HOST_BUILD_DIR)/tools/fiptool \ + CFLAGS="$(HOST_CFLAGS)" \ + LDFLAGS="$(HOST_LDFLAGS)" + $(MAKE) -C \ + $(HOST_BUILD_DIR)/tools/sptool \ + CFLAGS="$(HOST_CFLAGS)" \ + LDFLAGS="$(HOST_LDFLAGS)" +endef + +define Host/Install + $(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/ + $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/fiptool/fiptool $(STAGING_DIR_HOST)/bin/ + $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/cert_create/cert_create $(STAGING_DIR_HOST)/bin/ + $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/encrypt_fw/encrypt_fw $(STAGING_DIR_HOST)/bin/ + $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/sptool/sptool $(STAGING_DIR_HOST)/bin/ + $(INSTALL_BIN) $(HOST_BUILD_DIR)/tools/sptool/sp_mk_generator.py $(STAGING_DIR_HOST)/bin/ +endef + +define Host/Clean + rm -f $(STAGING_DIR_HOST)/bin/fiptool + rm -f $(STAGING_DIR_HOST)/bin/cert_create + rm -f $(STAGING_DIR_HOST)/bin/encrypt_fw + rm -f $(STAGING_DIR_HOST)/bin/sptool + rm -f $(STAGING_DIR_HOST)/bin/sp_mk_generator.py +endef + +$(eval $(call BuildPackage,arm-trusted-firmware-tools)) +$(eval $(call HostBuild)) |