aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-23 13:25:59 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-23 13:25:59 +0100
commitf52e8c65413233069a71112606ce2f131249ca83 (patch)
tree014663193b6284071fcd03ed0aac58d261aa7fdd /src
parentc5e769ec0ce3d7347276809d79d7dcb81aae8324 (diff)
downloadrspamd-f52e8c65413233069a71112606ce2f131249ca83.tar.gz
rspamd-f52e8c65413233069a71112606ce2f131249ca83.zip
Fix architecture detection.
Diffstat (limited to 'src')
-rw-r--r--src/libcryptobox/curve25519/curve25519.c2
-rw-r--r--src/libcryptobox/platform_config.h.in3
2 files changed, 3 insertions, 2 deletions
diff --git a/src/libcryptobox/curve25519/curve25519.c b/src/libcryptobox/curve25519/curve25519.c
index 1d04b973b..34a361d60 100644
--- a/src/libcryptobox/curve25519/curve25519.c
+++ b/src/libcryptobox/curve25519/curve25519.c
@@ -55,7 +55,7 @@ CURVE25519_DECLARE(avx);
CURVE25519_DECLARE(ref);
#define CURVE25519_REF CURVE25519_IMPL(0, "ref", ref)
-#if (ARCH == x86_64) || (ARCH == i386)
+#if defined(CMAKE_ARCH_x86_64) || defined(CMAKE_ARCH_i386)
CURVE25519_DECLARE(donna);
#define CURVE25519_GENERIC CURVE25519_IMPL(0, "donna", donna)
#else
diff --git a/src/libcryptobox/platform_config.h.in b/src/libcryptobox/platform_config.h.in
index b71306e99..577e8528b 100644
--- a/src/libcryptobox/platform_config.h.in
+++ b/src/libcryptobox/platform_config.h.in
@@ -1,7 +1,8 @@
#ifndef PLATFORM_H_CONFIG
#define PLATFORM_H_CONFIG
-#define ARCH ${ARCH}
+#define ARCH "${ARCH}"
+#define CMAKE_ARCH_${ARCH} 1
#cmakedefine HAVE_AVX2 1
#cmakedefine HAVE_AVX 1
#cmakedefine HAVE_SSE2 1