diff options
| -rw-r--r-- | meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/0001-configure.ac-fix-compatibility-with-autoconf-2.70.patch | 48 | ||||
| -rw-r--r-- | meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/fixup_hosttools.patch | 26 | ||||
| -rw-r--r-- | meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.1.0.bb (renamed from meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.0.3.bb) | 16 |
3 files changed, 38 insertions, 52 deletions
diff --git a/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/0001-configure.ac-fix-compatibility-with-autoconf-2.70.patch b/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/0001-configure.ac-fix-compatibility-with-autoconf-2.70.patch deleted file mode 100644 index cae2e76..0000000 --- a/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/0001-configure.ac-fix-compatibility-with-autoconf-2.70.patch +++ /dev/null | |||
| @@ -1,48 +0,0 @@ | |||
| 1 | From 03cca78d24d716eec792f86f5b0bc69886fad981 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Patrick McCarty <patrick.mccarty@intel.com> | ||
| 3 | Date: Fri, 18 Dec 2020 01:54:05 +0000 | ||
| 4 | Subject: [PATCH] configure.ac: fix compatibility with autoconf 2.70 | ||
| 5 | |||
| 6 | With autoconf 2.70, not quoting the second argument to one of the AS_IF | ||
| 7 | macro expansions leads to generation of invalid shell code affecting the | ||
| 8 | first nested ERROR_IF_NO_PROG expansion. | ||
| 9 | |||
| 10 | The invalid shell code leads to an error resembling: | ||
| 11 | |||
| 12 | ./configure: line 18826: syntax error near unexpected token `newline' | ||
| 13 | ./configure: line 18826: ` ''' | ||
| 14 | |||
| 15 | Fix the issue by quoting the second argument to the affected AS_IF, | ||
| 16 | similar to the quoting found elsewhere in configure.ac. | ||
| 17 | |||
| 18 | Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com> | ||
| 19 | |||
| 20 | Upstream-Status: Backport | ||
| 21 | Signed-off-by: Armin Kuster <akuster808@gmail.com> | ||
| 22 | |||
| 23 | --- | ||
| 24 | configure.ac | 4 ++-- | ||
| 25 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
| 26 | |||
| 27 | Index: tpm2-tss-3.0.3/configure.ac | ||
| 28 | =================================================================== | ||
| 29 | --- tpm2-tss-3.0.3.orig/configure.ac | ||
| 30 | +++ tpm2-tss-3.0.3/configure.ac | ||
| 31 | @@ -279,7 +279,7 @@ AC_ARG_ENABLE([integration], | ||
| 32 | [build and execute integration tests])],, | ||
| 33 | [enable_integration=no]) | ||
| 34 | AS_IF([test "x$enable_integration" = "xyes"], | ||
| 35 | - AS_IF([test "$HOSTOS" = "Linux"], | ||
| 36 | + [AS_IF([test "$HOSTOS" = "Linux"], | ||
| 37 | [ERROR_IF_NO_PROG([ss])], | ||
| 38 | [ERROR_IF_NO_PROG([sockstat])]) | ||
| 39 | ERROR_IF_NO_PROG([echo]) | ||
| 40 | @@ -328,7 +328,7 @@ AS_IF([test "x$enable_integration" = "xy | ||
| 41 | [AC_MSG_ERROR([No simulator executable found in PATH for testing TCTI.])]) | ||
| 42 | AC_SUBST([INTEGRATION_TCTI], [$integration_tcti]) | ||
| 43 | AC_SUBST([INTEGRATION_ARGS], [$integration_args]) | ||
| 44 | - AC_SUBST([ENABLE_INTEGRATION], [$enable_integration])) | ||
| 45 | + AC_SUBST([ENABLE_INTEGRATION], [$enable_integration])]) | ||
| 46 | AM_CONDITIONAL([ENABLE_INTEGRATION],[test "x$enable_integration" = "xyes"]) | ||
| 47 | # | ||
| 48 | # sanitizer compiler flags | ||
diff --git a/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/fixup_hosttools.patch b/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/fixup_hosttools.patch new file mode 100644 index 0000000..b5579e1 --- /dev/null +++ b/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss/fixup_hosttools.patch | |||
| @@ -0,0 +1,26 @@ | |||
| 1 | revert configure: add checks for all tools used by make install | ||
| 2 | |||
| 3 | Not appropriate for cross build env. | ||
| 4 | |||
| 5 | Upstream-Status: OE [inappropriate] | ||
| 6 | Signed-off-by: Armin Kuster <akuster808@gmail.com> | ||
| 7 | |||
| 8 | Index: tpm2-tss-3.1.0/configure.ac | ||
| 9 | =================================================================== | ||
| 10 | --- tpm2-tss-3.1.0.orig/configure.ac | ||
| 11 | +++ tpm2-tss-3.1.0/configure.ac | ||
| 12 | @@ -471,14 +471,6 @@ AM_CONDITIONAL(SYSD_SYSUSERS, test "x$sy | ||
| 13 | AC_CHECK_PROG(systemd_tmpfiles, systemd-tmpfiles, yes) | ||
| 14 | AM_CONDITIONAL(SYSD_TMPFILES, test "x$systemd_tmpfiles" = "xyes") | ||
| 15 | # Check all tools used by make install | ||
| 16 | -AS_IF([test "$HOSTOS" = "Linux"], | ||
| 17 | - [ERROR_IF_NO_PROG([groupadd]) | ||
| 18 | - ERROR_IF_NO_PROG([useradd]) | ||
| 19 | - ERROR_IF_NO_PROG([id]) | ||
| 20 | - ERROR_IF_NO_PROG([chown]) | ||
| 21 | - ERROR_IF_NO_PROG([chmod]) | ||
| 22 | - ERROR_IF_NO_PROG([mkdir]) | ||
| 23 | - ERROR_IF_NO_PROG([setfacl])]) | ||
| 24 | |||
| 25 | AC_SUBST([PATH]) | ||
| 26 | |||
diff --git a/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.0.3.bb b/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.1.0.bb index 1a36a5b..e0f2d09 100644 --- a/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.0.3.bb +++ b/meta-tpm/recipes-tpm2/tpm2-tss/tpm2-tss_3.1.0.bb | |||
| @@ -7,9 +7,10 @@ SECTION = "tpm" | |||
| 7 | DEPENDS = "autoconf-archive-native libgcrypt openssl" | 7 | DEPENDS = "autoconf-archive-native libgcrypt openssl" |
| 8 | 8 | ||
| 9 | SRC_URI = "https://github.com/tpm2-software/${BPN}/releases/download/${PV}/${BPN}-${PV}.tar.gz \ | 9 | SRC_URI = "https://github.com/tpm2-software/${BPN}/releases/download/${PV}/${BPN}-${PV}.tar.gz \ |
| 10 | file://0001-configure.ac-fix-compatibility-with-autoconf-2.70.patch \ | 10 | file://fixup_hosttools.patch \ |
| 11 | " | 11 | " |
| 12 | SRC_URI[sha256sum] = "78392be7309baf47f51b122f566ac915fd4d1760ea78571cba2e1484f9b5be17" | 12 | |
| 13 | SRC_URI[sha256sum] = "8900a6603f74310b749b65f23c3461cde6e2a23a5f61058b21004c25f9cf19e8" | ||
| 13 | 14 | ||
| 14 | inherit autotools pkgconfig systemd extrausers | 15 | inherit autotools pkgconfig systemd extrausers |
| 15 | 16 | ||
| @@ -18,14 +19,19 @@ PACKAGECONFIG[oxygen] = ",--disable-doxygen-doc, " | |||
| 18 | PACKAGECONFIG[fapi] = "--enable-fapi,--disable-fapi,curl json-c " | 19 | PACKAGECONFIG[fapi] = "--enable-fapi,--disable-fapi,curl json-c " |
| 19 | 20 | ||
| 20 | EXTRA_OECONF += "--enable-static --with-udevrulesdir=${nonarch_base_libdir}/udev/rules.d/" | 21 | EXTRA_OECONF += "--enable-static --with-udevrulesdir=${nonarch_base_libdir}/udev/rules.d/" |
| 22 | EXTRA_OECONF += "--runstatedir=/run" | ||
| 21 | EXTRA_OECONF:remove = " --disable-static" | 23 | EXTRA_OECONF:remove = " --disable-static" |
| 22 | 24 | ||
| 23 | |||
| 24 | EXTRA_USERS_PARAMS = "\ | 25 | EXTRA_USERS_PARAMS = "\ |
| 25 | useradd -p '' tss; \ | 26 | useradd -p '' tss; \ |
| 26 | groupadd tss; \ | 27 | groupadd tss; \ |
| 27 | " | 28 | " |
| 28 | 29 | ||
| 30 | do_install:append() { | ||
| 31 | # Remove /run as it is created on startup | ||
| 32 | rm -rf ${D}/run | ||
| 33 | } | ||
| 34 | |||
| 29 | PROVIDES = "${PACKAGES}" | 35 | PROVIDES = "${PACKAGES}" |
| 30 | PACKAGES = " \ | 36 | PACKAGES = " \ |
| 31 | ${PN} \ | 37 | ${PN} \ |
| @@ -75,6 +81,8 @@ FILES:libtss2-staticdev = "${libdir}/libtss*a" | |||
| 75 | 81 | ||
| 76 | FILES:${PN} = "\ | 82 | FILES:${PN} = "\ |
| 77 | ${libdir}/udev \ | 83 | ${libdir}/udev \ |
| 84 | /var/lib/tpm2-tss \ | ||
| 85 | /var/run \ | ||
| 78 | ${nonarch_base_libdir}/udev \ | 86 | ${nonarch_base_libdir}/udev \ |
| 79 | ${sysconfdir}/tmpfiles.d \ | 87 | ${sysconfdir}/tmpfiles.d \ |
| 80 | ${sysconfdir}/tpm2-tss \ | 88 | ${sysconfdir}/tpm2-tss \ |
