diff --git a/library/bn_mul.h b/library/bn_mul.h index 51c0a31482..936810e4e6 100644 --- a/library/bn_mul.h +++ b/library/bn_mul.h @@ -673,13 +673,13 @@ #if defined(__thumb__) && !defined(__thumb2__) // Thumb 1 (not Thumb 2) ISA // Only supported by gcc, when optimisation is enabled; only Thumb 1 codepath works - #if defined(__OPTIMIZE__) && !defined(__ARMCC_VERSION) + #if defined(__OPTIMIZE__) && defined(__GNUC__) #define ARM_THUMB_1 #endif #elif defined(__thumb2__) // Thumb 2 ISA - #if !defined(__ARMCC_VERSION) && !defined(__OPTIMIZE__) + #if defined(__GNUC__) && !defined(__OPTIMIZE__) // gcc -O0: only V6+DSP codepath builds #if (__ARM_ARCH >= 6) && defined (__ARM_FEATURE_DSP) && (__ARM_FEATURE_DSP == 1) #define ARM_V6_DSP