ref: e1772654b51f410ad6f6457f750e6740035a9dc6
parent: 6b8fc490777700f00cd198585a8759b3d1f5f351
author: EKR <[email protected]>
date: Thu Jan 9 05:25:15 EST 2014
Add ASan support
--- a/Makefile
+++ b/Makefile
@@ -5,6 +5,7 @@
ROOTDIR=$(PWD)
+
ifeq (,$(wildcard ./gtest))
HAVE_GTEST=No
else
@@ -18,6 +19,11 @@
else
CFLAGS = -g
USE_ASM = No
+endif
+
+ifeq ($(USE_ASAN), Yes)
+CFLAGS += -fsanitize=address
+LDFLAGS += -fsanitize=address
endif
ifeq ($(ENABLE64BIT), Yes)