summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Makefile.mk1
-rw-r--r--lib/asan/Makefile.mk13
-rw-r--r--lib/asan/mach_override/Makefile.mk21
-rw-r--r--lib/asan/sysinfo/Makefile.mk21
4 files changed, 55 insertions, 1 deletions
diff --git a/lib/Makefile.mk b/lib/Makefile.mk
index b0bb7228b..4a0c98a82 100644
--- a/lib/Makefile.mk
+++ b/lib/Makefile.mk
@@ -13,6 +13,7 @@ SubDirs :=
SubDirs += i386 ppc x86_64 arm
# Add other submodules.
+SubDirs += asan
SubDirs += profile
# Define the variables for this specific directory.
diff --git a/lib/asan/Makefile.mk b/lib/asan/Makefile.mk
index 0263ab302..3f61d4e6e 100644
--- a/lib/asan/Makefile.mk
+++ b/lib/asan/Makefile.mk
@@ -7,4 +7,15 @@
#
#===------------------------------------------------------------------------===#
-# See README.txt
+SubDirs := mach_override sysinfo
+
+Sources := $(foreach file,$(wildcard $(Dir)/*.cc),$(notdir $(file)))
+ObjNames := $(Sources:%.cc=%.o)
+
+Implementation := Generic
+
+# FIXME: use automatic dependencies?
+Dependencies := $(wildcard $(Dir)/*.h)
+
+# Define a convenience variable for all the asan functions.
+AsanFunctions := $(Sources:%.cc=%)
diff --git a/lib/asan/mach_override/Makefile.mk b/lib/asan/mach_override/Makefile.mk
new file mode 100644
index 000000000..c99267dca
--- /dev/null
+++ b/lib/asan/mach_override/Makefile.mk
@@ -0,0 +1,21 @@
+#===- lib/asan/mach_override/Makefile.mk -------------------*- Makefile -*--===#
+#
+# The LLVM Compiler Infrastructure
+#
+# This file is distributed under the University of Illinois Open Source
+# License. See LICENSE.TXT for details.
+#
+#===------------------------------------------------------------------------===#
+
+SubDirs :=
+
+Sources := $(foreach file,$(wildcard $(Dir)/*.c),$(notdir $(file)))
+ObjNames := $(Sources:%.c=%.o)
+
+Implementation := Generic
+
+# FIXME: use automatic dependencies?
+Dependencies := $(wildcard $(Dir)/*.h)
+
+# Define a convenience variable for all the asan functions.
+AsanFunctions += $(Sources:%.c=%)
diff --git a/lib/asan/sysinfo/Makefile.mk b/lib/asan/sysinfo/Makefile.mk
new file mode 100644
index 000000000..082ae7b17
--- /dev/null
+++ b/lib/asan/sysinfo/Makefile.mk
@@ -0,0 +1,21 @@
+#===- lib/asan/sysinfo/Makefile.mk -------------------------*- Makefile -*--===#
+#
+# The LLVM Compiler Infrastructure
+#
+# This file is distributed under the University of Illinois Open Source
+# License. See LICENSE.TXT for details.
+#
+#===------------------------------------------------------------------------===#
+
+SubDirs :=
+
+Sources := $(foreach file,$(wildcard $(Dir)/*.cc),$(notdir $(file)))
+ObjNames := $(Sources:%.c=%.o)
+
+Implementation := Generic
+
+# FIXME: use automatic dependencies?
+Dependencies := $(wildcard $(Dir)/*.h)
+
+# Define a convenience variable for all the asan functions.
+AsanFunctions += $(Sources:%.cc=%)