summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2015-01-27 10:09:57 -0800
committerAlan Mishchenko <alanmi@berkeley.edu>2015-01-27 10:09:57 -0800
commitc58dd062591f47a79eee6b838b267e51534bbdd5 (patch)
tree981581468ad5f4ae7a7b9b1887edc647db1db4d2 /Makefile
parent0f22046bcb71ba096fedfc6a75b6bc7fd4090e70 (diff)
downloadabc-c58dd062591f47a79eee6b838b267e51534bbdd5.tar.gz
abc-c58dd062591f47a79eee6b838b267e51534bbdd5.tar.bz2
abc-c58dd062591f47a79eee6b838b267e51534bbdd5.zip
Fixing reported memory alignment issue.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 532639d2..f7810619 100644
--- a/Makefile
+++ b/Makefile
@@ -44,7 +44,10 @@ arch_flags : arch_flags.c
ARCHFLAGS ?= $(shell $(CC) arch_flags.c -o arch_flags && ./arch_flags)
OPTFLAGS ?= -g -O #-DABC_NAMESPACE=xxx
-CFLAGS += -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare $(OPTFLAGS) $(ARCHFLAGS) -Isrc
+CFLAGS += -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare $(OPTFLAGS) $(ARCHFLAGS) -Isrc
+ifneq ($(findstring arm,$(shell uname -m)),)
+ CFLAGS += -DABC_MEMALIGN=4
+endif
# Set -Wno-unused-bug-set-variable for GCC 4.6.0 and greater only
ifneq ($(or $(findstring gcc,$(CC)),$(findstring g++,$(CC))),)