libtpmtss: Use pkconfig to configure TSS 2.0 includes and libraries
This commit is contained in:
parent
60d0f52fd6
commit
0274163674
|
@ -977,10 +977,11 @@ if test x$tss_trousers = xtrue; then
|
|||
fi
|
||||
|
||||
if test x$tss_tss2 = xtrue; then
|
||||
AC_CHECK_LIB([tss2],[main],[LIBS="$LIBS"],[AC_MSG_ERROR([TTS 2.0 library libtss2 not found])],[])
|
||||
AC_CHECK_HEADER([tss2/tpm20.h],,[AC_MSG_ERROR([TSS 2.0 header tss2/tpm20.h not found!])])
|
||||
AC_DEFINE([TSS_TSS2], [], [use TSS 2.0 library libtss2])
|
||||
PKG_CHECK_MODULES(tss2, [tcti-socket], [AC_DEFINE([TSS_TSS2], [], [use TSS 2.0 libraries])])
|
||||
AC_SUBST(tss2_CFLAGS)
|
||||
AC_SUBST(tss2_LIBS)
|
||||
fi
|
||||
|
||||
if test x$imv_swid = xtrue; then
|
||||
PKG_CHECK_MODULES(json, [json-c], [],
|
||||
[PKG_CHECK_MODULES(json, [json])])
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
AM_CPPFLAGS = \
|
||||
-I$(top_srcdir)/src/libstrongswan
|
||||
|
||||
AM_CFLAGS = \
|
||||
$(tss2_CFLAGS)
|
||||
|
||||
AM_LDFLAGS = \
|
||||
-no-undefined
|
||||
|
||||
|
@ -16,7 +19,7 @@ libtpmtss_la_LIBADD = \
|
|||
$(top_builddir)/src/libstrongswan/libstrongswan.la
|
||||
|
||||
if USE_TSS2
|
||||
libtpmtss_la_LIBADD += -ltctisocket -ltss2
|
||||
libtpmtss_la_LIBADD += $(tss2_LIBS)
|
||||
endif
|
||||
|
||||
if USE_TROUSERS
|
||||
|
|
|
@ -22,8 +22,8 @@
|
|||
#include <asn1/oid.h>
|
||||
#include <bio/bio_reader.h>
|
||||
|
||||
#include <tss2/tpm20.h>
|
||||
#include <tcti/tcti_socket.h>
|
||||
#include <tpm20.h>
|
||||
#include <tcti_socket.h>
|
||||
|
||||
#define LABEL "TPM 2.0 -"
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
|
||||
#ifdef TSS_TSS2
|
||||
|
||||
#include <tss2/tpm20.h>
|
||||
#include <tpm20.h>
|
||||
|
||||
#ifndef TPM_ALG_ECMQV
|
||||
#define TPM_ALG_ECMQV (TPM_ALG_ID)0x001D
|
||||
|
|
Loading…
Reference in New Issue