summaryrefslogtreecommitdiff
path: root/compiler.h
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2008-06-08 20:53:29 -0700
committerH. Peter Anvin <hpa@zytor.com>2008-06-08 20:53:29 -0700
commit2f0f9ea286e2e37681608e7d4b4ebd4253848478 (patch)
tree0c17efacf930fb52603471979881318d3b8d6b01 /compiler.h
parentcb38f505e48e47fda39fb1956b71ea571b9ea5a8 (diff)
downloadnasm-2f0f9ea286e2e37681608e7d4b4ebd4253848478.tar.gz
Use autoconf to detect WORDS_LITTLEENDIAN
Use autoconf to detect littleendian word order, and use WORDS_LITTLEENDIAN instead of X86_MEMORY when we don't require unaligned memory accesses to be permitted.
Diffstat (limited to 'compiler.h')
-rw-r--r--compiler.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler.h b/compiler.h
index ced029c9..01e11277 100644
--- a/compiler.h
+++ b/compiler.h
@@ -103,6 +103,9 @@ char *strsep(char **, const char *);
*/
#if defined(__386__) || defined(__i386__) || defined(__x86_64__)
# define X86_MEMORY 1
+# ifndef WORDS_LITTLEENDIAN
+# define WORDS_LITTLEENDIAN 1
+# endif
#else
# define X86_MEMORY 0
#endif