]> git.ipfire.org Git - thirdparty/gcc.git/blame - libsanitizer/asan/Makefile.am
libsanitizer: use gnu++14
[thirdparty/gcc.git] / libsanitizer / asan / Makefile.am
CommitLineData
f35db108
WM
1AM_CPPFLAGS = -I $(top_srcdir)/include -I $(top_srcdir)
2
f64bcb29 3# May be used by toolexeclibdir.
73aa401e 4gcc_version := $(shell @get_gcc_base_ver@ $(top_srcdir)/../gcc/BASE-VER)
f64bcb29 5
9553f0d2 6DEFS = -D_GNU_SOURCE -D_DEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -DASAN_HAS_EXCEPTIONS=1 -DASAN_NEEDS_SEGV=1 -DCAN_SANITIZE_UB=0 -DASAN_HAS_CXA_RETHROW_PRIMARY_EXCEPTION=0
8c4d267c
KS
7if USING_MAC_INTERPOSE
8DEFS += -DMAC_INTERPOSE_FUNCTIONS -DMISSING_BLOCKS_SUPPORT
9endif
d13fc1ed 10AM_CXXFLAGS = -Wall -W -Wno-unused-parameter -Wwrite-strings -pedantic -Wno-long-long -fPIC -fno-builtin -fno-exceptions -fno-rtti -fomit-frame-pointer -funwind-tables -fvisibility=hidden -Wno-variadic-macros -fno-ipa-icf
d10a2df2 11AM_CXXFLAGS += $(LIBSTDCXX_RAW_CXX_CXXFLAGS)
942a384e 12AM_CXXFLAGS += -std=gnu++14
9069eb28 13AM_CXXFLAGS += $(EXTRA_CXXFLAGS)
f64bcb29 14ACLOCAL_AMFLAGS = -I $(top_srcdir) -I $(top_srcdir)/config
f35db108
WM
15
16toolexeclib_LTLIBRARIES = libasan.la
7d613735 17nodist_toolexeclib_HEADERS = libasan_preinit.o
f35db108
WM
18
19asan_files = \
b667dd70
ML
20 asan_activation.cpp \
21 asan_allocator.cpp \
22 asan_debugging.cpp \
23 asan_descriptions.cpp \
24 asan_errors.cpp \
25 asan_fake_stack.cpp \
26 asan_flags.cpp \
27 asan_globals.cpp \
28 asan_interceptors.cpp \
29 asan_interceptors_memintrinsics.cpp \
30 asan_linux.cpp \
31 asan_mac.cpp \
32 asan_malloc_linux.cpp \
33 asan_malloc_mac.cpp \
34 asan_malloc_win.cpp \
35 asan_memory_profile.cpp \
36 asan_new_delete.cpp \
37 asan_poisoning.cpp \
38 asan_posix.cpp \
39 asan_premap_shadow.cpp \
40 asan_report.cpp \
41 asan_rtems.cpp \
42 asan_rtl.cpp \
43 asan_shadow_setup.cpp \
44 asan_stack.cpp \
45 asan_stats.cpp \
46 asan_suppressions.cpp \
47 asan_thread.cpp \
48 asan_win.cpp \
49 asan_win_dll_thunk.cpp \
50 asan_win_dynamic_runtime_thunk.cpp \
51 asan_interceptors_vfork.S
f35db108 52
8c4d267c 53libasan_la_SOURCES = $(asan_files)
bdfc619e 54libasan_la_LIBADD = $(top_builddir)/sanitizer_common/libsanitizer_common.la $(top_builddir)/lsan/libsanitizer_lsan.la
c915a581
JJ
55if !USING_MAC_INTERPOSE
56libasan_la_LIBADD += $(top_builddir)/interception/libinterception.la
57endif
58if LIBBACKTRACE_SUPPORTED
59libasan_la_LIBADD += $(top_builddir)/libbacktrace/libsanitizer_libbacktrace.la
8c4d267c 60endif
7f7162cf 61libasan_la_LIBADD += $(LIBSTDCXX_RAW_CXX_LDFLAGS)
8c4d267c 62
35814b03 63libasan_la_LDFLAGS = -version-info `grep -v '^\#' $(srcdir)/libtool-version` $(link_libasan)
f35db108 64
7d613735
JJ
65libasan_preinit.o: asan_preinit.o
66 cp $< $@
67
b488a2c7
L
68# Work around what appears to be a GNU make bug handling MAKEFLAGS
69# values defined in terms of make variables, as is the case for CC and
70# friends when we are called from the top level Makefile.
71AM_MAKEFLAGS = \
72 "AR_FLAGS=$(AR_FLAGS)" \
73 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
74 "CFLAGS=$(CFLAGS)" \
75 "CXXFLAGS=$(CXXFLAGS)" \
76 "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
77 "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
78 "INSTALL=$(INSTALL)" \
79 "INSTALL_DATA=$(INSTALL_DATA)" \
80 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
81 "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
82 "JC1FLAGS=$(JC1FLAGS)" \
83 "LDFLAGS=$(LDFLAGS)" \
84 "LIBCFLAGS=$(LIBCFLAGS)" \
85 "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
86 "MAKE=$(MAKE)" \
87 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
88 "PICFLAG=$(PICFLAG)" \
89 "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
90 "SHELL=$(SHELL)" \
91 "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
92 "exec_prefix=$(exec_prefix)" \
93 "infodir=$(infodir)" \
94 "libdir=$(libdir)" \
95 "prefix=$(prefix)" \
96 "includedir=$(includedir)" \
97 "AR=$(AR)" \
98 "AS=$(AS)" \
99 "LD=$(LD)" \
100 "LIBCFLAGS=$(LIBCFLAGS)" \
101 "NM=$(NM)" \
102 "PICFLAG=$(PICFLAG)" \
103 "RANLIB=$(RANLIB)" \
104 "DESTDIR=$(DESTDIR)"
105
e8adb21b
L
106MAKEOVERRIDES=
107
f35db108
WM
108## ################################################################
109