Char/HChar fixups for m_debuginfo and m_gdbserver.
[ambi/valgrind.git] / Makefile.am
1
2 AUTOMAKE_OPTIONS = foreign 1.10 dist-bzip2
3
4 include $(top_srcdir)/Makefile.all.am 
5
6 TOOLS =         memcheck \
7                 cachegrind \
8                 callgrind \
9                 massif \
10                 lackey \
11                 none \
12                 helgrind \
13                 drd
14
15 EXP_TOOLS =     exp-sgcheck \
16                 exp-bbv \
17                 exp-dhat
18
19 # Put docs last because building the HTML is slow and we want to get
20 # everything else working before we try it.
21 SUBDIRS = \
22         include \
23         VEX \
24         coregrind \
25         . \
26         $(TOOLS) \
27         $(EXP_TOOLS) \
28         tests \
29         perf \
30         gdbserver_tests \
31         memcheck/tests/vbit-test \
32         auxprogs \
33         mpi \
34         docs
35 DIST_SUBDIRS  = $(SUBDIRS)
36
37 SUPP_FILES = \
38         glibc-2.2.supp glibc-2.3.supp glibc-2.4.supp glibc-2.5.supp \
39         glibc-2.6.supp glibc-2.7.supp glibc-2.X.supp.in \
40         xfree-3.supp xfree-4.supp \
41         glibc-2.34567-NPTL-helgrind.supp \
42         glibc-2.2-LinuxThreads-helgrind.supp \
43         glibc-2.X-drd.supp \
44         exp-sgcheck.supp \
45         darwin9.supp darwin9-drd.supp \
46         darwin10.supp darwin10-drd.supp \
47         darwin11.supp darwin12.supp \
48         bionic.supp
49 DEFAULT_SUPP_FILES = @DEFAULT_SUPP@
50
51 # We include all the base .supp files in the distribution, but not
52 # default.supp, as it is built from the base .supp files at compile-time.
53 dist_noinst_DATA = $(SUPP_FILES)
54
55 vglibdir = $(pkglibdir)
56 vglib_DATA = default.supp
57
58 pkgconfigdir = $(libdir)/pkgconfig
59 pkgconfig_DATA = valgrind.pc
60
61 BUILT_SOURCES  = default.supp valgrind.pc
62 CLEANFILES     = default.supp
63
64 default.supp: $(DEFAULT_SUPP_FILES)
65         echo "# This is a generated file, composed of the following suppression rules:" > default.supp
66         echo "# " $(DEFAULT_SUPP_FILES) >> default.supp
67         cat $(DEFAULT_SUPP_FILES) >> default.supp
68
69 ## Preprend @PERL@ because tests/vg_regtest isn't executable
70 ## Ensure make exits with error if PERL fails or check_makefile_consistency fails.
71 regtest: check
72         gdbserver_tests/make_local_links $(GDB)
73         if @PERL@ tests/vg_regtest gdbserver_tests $(TOOLS) $(EXP_TOOLS) ; then \
74            tests/check_makefile_consistency gdbserver_tests $(TOOLS) $(EXP_TOOLS); \
75         else \
76            tests/check_makefile_consistency gdbserver_tests $(TOOLS) $(EXP_TOOLS); \
77            false; \
78         fi
79 nonexp-regtest: check
80         @PERL@ tests/vg_regtest $(TOOLS)
81 exp-regtest: check
82         @PERL@ tests/vg_regtest gdbserver_tests $(EXP_TOOLS)
83 # Nb: gdbserver_tests are put in exp-regtest rather than nonexp-regtest
84 # because they are tested with various valgrind tools, so might be using
85 # an experimental tool.
86
87 ## Preprend @PERL@ because tests/vg_perf isn't executable
88 perf: check
89         @PERL@ perf/vg_perf perf
90
91 # Nb: no need to include any Makefile.am files here, or files included from
92 # them, as automake includes them automatically.  Also not COPYING, README
93 # or NEWS.
94 # We include valgrind.spec as well as valgrind.spec.in to save packagers
95 # from having to run configure (bug 188560).
96 EXTRA_DIST = \
97         COPYING.DOCS \
98         README_DEVELOPERS \
99         README_PACKAGERS \
100         README_MISSING_SYSCALL_OR_IOCTL \
101         README.s390 \
102         README.android \
103         README.android_emulator \
104         README.mips \
105         NEWS.old \
106         valgrind.pc.in \
107         valgrind.spec.in \
108         valgrind.spec \
109         autogen.sh
110
111 dist_noinst_SCRIPTS = \
112         vg-in-place
113
114 all-local: default.supp
115         mkdir -p $(inplacedir)
116         rm -f $(inplacedir)/default.supp
117         ln -s ../default.supp $(inplacedir)
118
119 clean-local:
120         rm -rf $(inplacedir)
121
122 # Need config.h in the installed tree, since some files depend on it
123 pkginclude_HEADERS = config.h