From 4577311727f2c75fb69550ffdd289f3292dd3c88 Mon Sep 17 00:00:00 2001 From: Jeffrey Walton Date: Sat, 26 Dec 2020 00:42:09 -0500 Subject: Fix compile on AIX POWER7 with IBM XLC Let's see what this breaks later because of Clang's stupid tricks... --- ppc_simd.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'ppc_simd.h') diff --git a/ppc_simd.h b/ppc_simd.h index 52056053..65008066 100644 --- a/ppc_simd.h +++ b/ppc_simd.h @@ -121,16 +121,20 @@ // provide an option to set it. We have to set it // for the code below. This define must stay in // sync with the define in test_ppc_power7.cxx. -#if defined(_AIX) && defined(_ARCH_PWR7) && defined(__xlC__) -# define __VSX__ 1 +#ifndef CRYPTOPP_DISABLE_POWER7 +# if defined(_AIX) && defined(_ARCH_PWR7) && defined(__xlC__) +# define __VSX__ 1 +# endif #endif // XL C++ on AIX does not define CRYPTO and does not // provide an option to set it. We have to set it // for the code below. This define must stay in // sync with the define in test_ppc_power8.cxx -#if defined(_AIX) && defined(_ARCH_PWR8) && defined(__xlC__) -# define __CRYPTO__ 1 +#ifndef CRYPTOPP_DISABLE_POWER8 +# if defined(_AIX) && defined(_ARCH_PWR8) && defined(__xlC__) +# define __CRYPTO__ 1 +# endif #endif /// \brief Cast array to vector pointer -- cgit v1.2.1