瀏覽代碼

package/tpm2-tools: add option for enabling FAPI tools

Signed-off-by: Erik Larsson <who+buildroot@cnackers.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Erik Larsson 3 年之前
父節點
當前提交
b5c8dde84c
共有 2 個文件被更改,包括 18 次插入0 次删除
  1. 12 0
      package/tpm2-tools/Config.in
  2. 6 0
      package/tpm2-tools/tpm2-tools.mk

+ 12 - 0
package/tpm2-tools/Config.in

@@ -21,6 +21,18 @@ config BR2_PACKAGE_TPM2_TOOLS
 
 	  https://github.com/tpm2-software/tpm2-tools
 
+if BR2_PACKAGE_TPM2_TOOLS
+
+config BR2_PACKAGE_TPM2_TOOLS_FAPI
+	bool "fapi tools"
+	depends on BR2_TOOLCHAIN_HAS_SYNC_4
+	select BR2_PACKAGE_TPM2_TSS_FAPI
+	help
+	  This option enables Feature API (FAPI) support in
+	  tpm2-tools. The FAPI tools are prefixed with tss2_.
+
+endif
+
 comment "tpm2-tools needs a glibc or musl toolchain w/ dynamic library, wchar"
 	depends on BR2_STATIC_LIBS || !BR2_USE_WCHAR || \
 		!(BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL)

+ 6 - 0
package/tpm2-tools/tpm2-tools.mk

@@ -20,4 +20,10 @@ TPM2_TOOLS_CONF_OPTS = --disable-hardening
 # do not build man pages
 TPM2_TOOLS_CONF_ENV += ac_cv_prog_PANDOC=''
 
+ifeq ($(BR2_PACKAGE_TPM2_TOOLS_FAPI),y)
+TPM2_TOOLS_CONF_OPTS += --enable-fapi
+else
+TPM2_TOOLS_CONF_OPTS += --disable-fapi
+endif
+
 $(eval $(autotools-package))