From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id C0CE01395E2 for ; Tue, 6 Dec 2016 19:46:49 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 26FEDE0D72; Tue, 6 Dec 2016 19:46:49 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DF8AEE0D72 for ; Tue, 6 Dec 2016 19:46:48 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 5E244341375 for ; Tue, 6 Dec 2016 19:46:47 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 2ECDC492 for ; Tue, 6 Dec 2016 19:46:46 +0000 (UTC) From: "Alon Bar-Lev" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Alon Bar-Lev" Message-ID: <1481010950.c36af760171e28c16a6c386b0fdebe81b68555a4.alonbl@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-crypt/tpm-tools/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-crypt/tpm-tools/files/tpm-tools-1.3.9-gold.patch X-VCS-Directories: app-crypt/tpm-tools/files/ X-VCS-Committer: alonbl X-VCS-Committer-Name: Alon Bar-Lev X-VCS-Revision: c36af760171e28c16a6c386b0fdebe81b68555a4 X-VCS-Branch: master Date: Tue, 6 Dec 2016 19:46:46 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 7e4a1ade-3a5e-4d90-85a8-f4e45d176814 X-Archives-Hash: 0bf4bd5c17f1d242fcf650f2925fa885 commit: c36af760171e28c16a6c386b0fdebe81b68555a4 Author: Alon Bar-Lev gentoo org> AuthorDate: Tue Dec 6 07:55:34 2016 +0000 Commit: Alon Bar-Lev gentoo org> CommitDate: Tue Dec 6 07:55:50 2016 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c36af760 app-crypt/tpm-tools: hopefully better gold support Bug: 601776 Package-Manager: portage-2.3.0 .../tpm-tools/files/tpm-tools-1.3.9-gold.patch | 98 +++++++++++++++++++++- 1 file changed, 96 insertions(+), 2 deletions(-) diff --git a/app-crypt/tpm-tools/files/tpm-tools-1.3.9-gold.patch b/app-crypt/tpm-tools/files/tpm-tools-1.3.9-gold.patch index 1745c69..8f999a8 100644 --- a/app-crypt/tpm-tools/files/tpm-tools-1.3.9-gold.patch +++ b/app-crypt/tpm-tools/files/tpm-tools-1.3.9-gold.patch @@ -1,5 +1,57 @@ +From 4cf41d367e3248fecee7620501d12449c374c055 Mon Sep 17 00:00:00 2001 +From: Alon Bar-Lev +Date: Tue, 6 Dec 2016 09:38:06 +0200 +Subject: [PATCH] build: -lcrypto is required for tspi + +Signed-off-by: Alon Bar-Lev +--- + configure.ac | 13 +++++++++---- + lib/Makefile.am | 2 +- + src/cmds/Makefile.am | 2 +- + src/data_mgmt/Makefile.am | 2 +- + src/tpm_mgmt/Makefile.am | 2 +- + 5 files changed, 13 insertions(+), 8 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 279954a..99f9c4b 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -90,14 +90,22 @@ AC_ARG_WITH(openssl, + AC_MSG_ERROR([$OPENSSL_INCLUDE_DIR or $OPENSSL_LIB_DIR doen't exist!]) + else + AC_MSG_RESULT([yes]) +- CFLAGS="$CFLAGS -L$OPENSSL_LIB_DIR -I$OPENSSL_INCLUDE_DIR" ++ CFLAGS="$CFLAGS -I$OPENSSL_INCLUDE_DIR" ++ LDFLAGS="$LDFLAGS -L$OPENSSL_LIB_DIR" + AC_SUBST([OPENSSL_LIB_DIR]) + fi], + [AC_MSG_RESULT([no]) + AC_SUBST([OPENSSL_LIB_DIR], []) ] ) + ++AC_CHECK_LIB(crypto, PEM_read_X509, [OPENSSL_LIB="1"], [AC_MSG_ERROR([openssl lib not found: libcrypto.so])]) ++AC_CHECK_HEADER(openssl/evp.h, [OPENSSL_INC="1"], [AC_MSG_ERROR([openssl header not found: openssl/evp.h])]) ++ ++OLD_LIBS="$LIBS" ++LIBS="$LIBS -lcrypto" + AC_CHECK_LIB(tspi, Tspi_Context_Create, [TSS_LIB="1"], [AC_MSG_ERROR([tss lib not found: libtspi.so])]) + AC_CHECK_LIB(tspi, Tspi_TPM_SetOperatorAuth, [TSS_12="1"], [TSS_12="0"]) ++AC_SUBST([TSPI_LIBS], ["-ltspi -lcrypto"]) ++LIBS="$OLD_LIBS" + if test "$TSS_12" = "1"; then + AM_CONDITIONAL(TSS_LIB_IS_12, true) + AC_MSG_NOTICE([Configuring tpm-tools for TSS 1.2]) +@@ -107,9 +115,6 @@ else + fi + AC_CHECK_HEADER(trousers/tss.h, [TSS_INC="1"], [AC_MSG_ERROR([tss header not found: trousers/tss.h])]) + +-AC_CHECK_LIB(crypto, PEM_read_X509, [OPENSSL_LIB="1"], [AC_MSG_ERROR([openssl lib not found: libcrypto.so])]) +-AC_CHECK_HEADER(openssl/evp.h, [OPENSSL_INC="1"], [AC_MSG_ERROR([openssl header not found: openssl/evp.h])]) +- + OPENCRYPTOKI="0" + AC_ARG_ENABLE(pkcs11_support, + AC_HELP_STRING([--disable-pkcs11-support], [don't build data_mgmt commands [[default=no]]]), diff --git a/lib/Makefile.am b/lib/Makefile.am -index cef6a2f..d7092a7 100644 +index c1d7009..af9bc49 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -80,4 +80,4 @@ endif @@ -7,4 +59,46 @@ index cef6a2f..d7092a7 100644 libtpm_unseal_la_SOURCES = tpm_unseal.c libtpm_unseal_la_LDFLAGS = -shared -version-info 1:0:0 -libtpm_unseal_la_LIBADD = -ltspi libtpm_tspi.la @INTLLIBS@ -+libtpm_unseal_la_LIBADD = -ltspi libtpm_tspi.la -lcrypto @INTLLIBS@ ++libtpm_unseal_la_LIBADD = libtpm_tspi.la -lcrypto @TSPI_LIBS@ @INTLLIBS@ +diff --git a/src/cmds/Makefile.am b/src/cmds/Makefile.am +index 27fc9ef..d7508bf 100644 +--- a/src/cmds/Makefile.am ++++ b/src/cmds/Makefile.am +@@ -30,7 +30,7 @@ else + AM_CPPFLAGS = -I$(top_srcdir)/include -D_LINUX + endif + +-LDADD = $(top_builddir)/lib/libtpm_tspi.la -ltspi $(top_builddir)/lib/libtpm_unseal.la -ltpm_unseal -lcrypto @INTLLIBS@ ++LDADD = $(top_builddir)/lib/libtpm_tspi.la $(top_builddir)/lib/libtpm_unseal.la -ltpm_unseal -lcrypto @TSPI_LIBS@ @INTLLIBS@ + + tpm_sealdata_SOURCES = tpm_sealdata.c + tpm_unsealdata_SOURCES = tpm_unsealdata.c +diff --git a/src/data_mgmt/Makefile.am b/src/data_mgmt/Makefile.am +index de505e4..765a2fa 100644 +--- a/src/data_mgmt/Makefile.am ++++ b/src/data_mgmt/Makefile.am +@@ -38,7 +38,7 @@ noinst_HEADERS = data_common.h \ + # Common build flags + AM_CPPFLAGS = -I$(top_srcdir)/include -D_LINUX + +-LDADD = $(top_builddir)/lib/libtpm_pkcs11.la -ltspi -ldl @INTLLIBS@ ++LDADD = $(top_builddir)/lib/libtpm_pkcs11.la @TSPI_LIBS@ -ldl @INTLLIBS@ + + + # +diff --git a/src/tpm_mgmt/Makefile.am b/src/tpm_mgmt/Makefile.am +index 7ca47c9..6205b64 100644 +--- a/src/tpm_mgmt/Makefile.am ++++ b/src/tpm_mgmt/Makefile.am +@@ -55,7 +55,7 @@ else + AM_CPPFLAGS = -I$(top_srcdir)/include -D_LINUX + endif + +-LDADD = $(top_builddir)/lib/libtpm_tspi.la -ltspi @INTLLIBS@ ++LDADD = $(top_builddir)/lib/libtpm_tspi.la @TSPI_LIBS@ @INTLLIBS@ + + tpm_startup_SOURCES = tpm_startup.c + tpm_reset_SOURCES = tpm_reset.c +-- +2.7.3 +