1 include $(top_srcdir)/Makefile.tool.am
3 EXTRA_DIST = docs/dh-manual.xml dh_view.html dh_view.css dh_view.js
5 #----------------------------------------------------------------------------
7 #----------------------------------------------------------------------------
12 # Ensure the viewer components get copied into the install tree.
13 dhatdir = $(pkglibexecdir)
14 dhat_DATA = dh_view.html dh_view.css dh_view.js
16 #----------------------------------------------------------------------------
18 #----------------------------------------------------------------------------
20 noinst_PROGRAMS = dhat-@VGCONF_ARCH_PRI@-@VGCONF_OS@
21 if VGCONF_HAVE_PLATFORM_SEC
22 noinst_PROGRAMS += dhat-@VGCONF_ARCH_SEC@-@VGCONF_OS@
25 DHAT_SOURCES_COMMON = dh_main.c
27 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_SOURCES = \
28 $(DHAT_SOURCES_COMMON)
29 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_CPPFLAGS = \
30 $(AM_CPPFLAGS_@VGCONF_PLATFORM_PRI_CAPS@)
31 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_CFLAGS = $(LTO_CFLAGS) \
32 -DDHAT_VIEW_DIR=\"$(dhatdir)\" \
33 $(AM_CFLAGS_@VGCONF_PLATFORM_PRI_CAPS@)
34 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_DEPENDENCIES = \
35 $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_PRI_CAPS@)
36 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_LDADD = \
37 $(TOOL_LDADD_@VGCONF_PLATFORM_PRI_CAPS@)
38 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_LDFLAGS = \
39 $(TOOL_LDFLAGS_@VGCONF_PLATFORM_PRI_CAPS@)
40 dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_LINK = \
41 $(top_builddir)/coregrind/link_tool_exe_@VGCONF_OS@ \
42 @VALT_LOAD_ADDRESS_PRI@ \
44 $(dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_CFLAGS) \
45 $(dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_LDFLAGS)
47 if VGCONF_HAVE_PLATFORM_SEC
48 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_SOURCES = \
49 $(DHAT_SOURCES_COMMON)
50 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_CPPFLAGS = \
51 $(AM_CPPFLAGS_@VGCONF_PLATFORM_SEC_CAPS@)
52 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_CFLAGS = $(LTO_CFLAGS) \
53 -DDHAT_VIEW_DIR=\"$(dhatdir)\" \
54 $(AM_CFLAGS_@VGCONF_PLATFORM_SEC_CAPS@)
55 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_DEPENDENCIES = \
56 $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_SEC_CAPS@)
57 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_LDADD = \
58 $(TOOL_LDADD_@VGCONF_PLATFORM_SEC_CAPS@)
59 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_LDFLAGS = \
60 $(TOOL_LDFLAGS_@VGCONF_PLATFORM_SEC_CAPS@)
61 dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_LINK = \
62 $(top_builddir)/coregrind/link_tool_exe_@VGCONF_OS@ \
63 @VALT_LOAD_ADDRESS_SEC@ \
65 $(dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_CFLAGS) \
66 $(dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_LDFLAGS)
69 #----------------------------------------------------------------------------
70 # vgpreload_dhat-<platform>.so
71 #----------------------------------------------------------------------------
73 noinst_PROGRAMS += vgpreload_dhat-@VGCONF_ARCH_PRI@-@VGCONF_OS@.so
74 if VGCONF_HAVE_PLATFORM_SEC
75 noinst_PROGRAMS += vgpreload_dhat-@VGCONF_ARCH_SEC@-@VGCONF_OS@.so
78 if VGCONF_OS_IS_DARWIN
79 noinst_DSYMS = $(noinst_PROGRAMS)
82 # dh_replace_strmem.c runs on the simulated CPU, and is built with
83 # AM_CFLAGS_PSO_* (see $(top_srcdir)/Makefile.all.am).
84 VGPRELOAD_DHAT_SOURCES_COMMON = dh_replace_strmem.c
86 vgpreload_dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_so_SOURCES = \
87 $(VGPRELOAD_DHAT_SOURCES_COMMON)
88 vgpreload_dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_so_CPPFLAGS = \
89 $(AM_CPPFLAGS_@VGCONF_PLATFORM_PRI_CAPS@)
90 vgpreload_dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_so_CFLAGS = \
91 $(AM_CFLAGS_PSO_@VGCONF_PLATFORM_PRI_CAPS@) -O2
92 vgpreload_dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_so_DEPENDENCIES = \
93 $(LIBREPLACEMALLOC_@VGCONF_PLATFORM_PRI_CAPS@)
94 vgpreload_dhat_@VGCONF_ARCH_PRI@_@VGCONF_OS@_so_LDFLAGS = \
95 $(PRELOAD_LDFLAGS_@VGCONF_PLATFORM_PRI_CAPS@) \
96 $(LIBREPLACEMALLOC_LDFLAGS_@VGCONF_PLATFORM_PRI_CAPS@)
98 if VGCONF_HAVE_PLATFORM_SEC
99 vgpreload_dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_so_SOURCES = \
100 $(VGPRELOAD_DHAT_SOURCES_COMMON)
101 vgpreload_dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_so_CPPFLAGS = \
102 $(AM_CPPFLAGS_@VGCONF_PLATFORM_SEC_CAPS@)
103 vgpreload_dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_so_CFLAGS = \
104 $(AM_CFLAGS_PSO_@VGCONF_PLATFORM_SEC_CAPS@) -O2
105 vgpreload_dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_so_DEPENDENCIES = \
106 $(LIBREPLACEMALLOC_@VGCONF_PLATFORM_SEC_CAPS@)
107 vgpreload_dhat_@VGCONF_ARCH_SEC@_@VGCONF_OS@_so_LDFLAGS = \
108 $(PRELOAD_LDFLAGS_@VGCONF_PLATFORM_SEC_CAPS@) \
109 $(LIBREPLACEMALLOC_LDFLAGS_@VGCONF_PLATFORM_SEC_CAPS@)