Skip to content

Commit

Permalink
Fix compilation error with latest BoringSSL Commit.
Browse files Browse the repository at this point in the history
Signed-off-by: Chen Tingkai <tingkai.chen@intel.com>
  • Loading branch information
Chen Tingkai authored and Yogaraj-Alamenda committed Mar 24, 2023
1 parent 43b8868 commit d17ca98
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 0 deletions.
9 changes: 9 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,15 @@ then
fi
AC_SUBST([QAT_BORINGSSL_LIB], ["-Wl,-rpath,\$(with_openssl_install_dir)/lib -L\$(with_openssl_install_dir)/lib -ldecrepit -lcrypto -lssl"])
AC_SUBST([LIBQATNAME], "libqatengine")
CFLAGS_BACK="${CFLAGS}"
CFLAGS="-I${with_openssl_install_dir}/include/ -I${with_openssl_install_dir}/include/openssl/ ${CFLAGS}"
AC_CHECK_TYPE([struct evp_pkey_st], [], [AC_MSG_ERROR([need specified version for BoringSSL commit:15596efa5f])], [
AC_INCLUDES_DEFAULT
#include <openssl/evp.h>])
AC_CHECK_MEMBERS([struct evp_pkey_st.references, struct evp_pkey_st.type, struct evp_pkey_st.pkey.ptr, struct evp_pkey_st.pkey.rsa,
struct evp_pkey_st.pkey.dsa, struct evp_pkey_st.pkey.dh, struct evp_pkey_st.pkey.ec, struct evp_pkey_st.ameth],
[], [need specified version for BoringSSL commit:15596efa5f], [#include <openssl/evp.h>])
CFLAGS="${CFLAGS_BACK}"
if test -d "$with_openssl_install_dir/crypto"
then
AC_SUBST([cflags_boringssl], ["-DQAT_BORINGSSL -DBSSL_SOURCE"])
Expand Down
2 changes: 2 additions & 0 deletions e_qat.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,9 @@
#endif

#ifdef QAT_SW_IPSEC
#ifndef QAT_BORINGSSL
# include "qat_sw_gcm.h"
#endif /* QAT_BORINGSSL */
#endif

/* OpenSSL Includes */
Expand Down
6 changes: 6 additions & 0 deletions qat_evp.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@
#endif

#ifdef QAT_SW_IPSEC
# ifndef QAT_BORINGSSL
# include "qat_sw_gcm.h"
#endif /* QAT_BORINGSSL */
#endif

#ifdef QAT_SW
Expand All @@ -84,13 +86,17 @@
# include "qat_sw_ec.h"
# include "qat_sw_rsa.h"
# include "qat_sw_sm3.h"
# ifndef QAT_BORINGSSL
# include "qat_sw_sm4_cbc.h"
# include "qat_sw_sm4_gcm.h"
# include "qat_sw_sm4_ccm.h"
# include "crypto_mb/sm4.h"
# endif /* QAT_BORINGSSL */
# include "crypto_mb/cpu_features.h"
# ifndef QAT_BORINGSSL
# include "crypto_mb/sm4_gcm.h"
# include "crypto_mb/sm4_ccm.h"
# endif /* QAT_BORINGSSL */
#endif

#ifdef QAT_HW_INTREE
Expand Down
2 changes: 2 additions & 0 deletions qat_sw_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@
#include "qat_sw_ecx.h"
#include "qat_sw_ec.h"
#include "qat_sw_sm3.h"
#ifndef QAT_BORINGSSL
#include "qat_sw_sm4_cbc.h"
#endif /* QAT_BORINGSSL */
#include "qat_sw_request.h"
#include "qat_sw_freelist.h"
#include "qat_sw_queue.h"
Expand Down
2 changes: 2 additions & 0 deletions qat_sw_polling.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,11 @@
#include "qat_sw_ec.h"
#include "qat_utils.h"
#include "qat_sw_sm3.h"
#ifndef QAT_BORINGSSL
#include "qat_sw_sm4_cbc.h"
#include "qat_sw_sm4_gcm.h"
#include "qat_sw_sm4_ccm.h"
#endif /* QAT_BORINGSSL */

/* OpenSSL Includes */
#include <openssl/err.h>
Expand Down

0 comments on commit d17ca98

Please sign in to comment.