nethercote | 4388a40 | 2004-09-01 23:20:49 +0000 | [diff] [blame] | 1 | include $(top_srcdir)/Makefile.tool.am |
njn25 | e49d8e7 | 2002-09-23 09:36:25 +0000 | [diff] [blame] | 2 | |
nethercote | 4388a40 | 2004-09-01 23:20:49 +0000 | [diff] [blame] | 3 | ## Build Memcheck at a higher optimisation level |
4 | AM_CFLAGS += -O2 | ||||
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 5 | |
njn | 063c540 | 2004-11-22 16:58:05 +0000 | [diff] [blame] | 6 | val_PROGRAMS = vgtool_memcheck.so vgpreload_memcheck.so |
fitzhardinge | 98abfc7 | 2003-12-16 02:05:15 +0000 | [diff] [blame] | 7 | |
8 | vgpreload_memcheck_so_SOURCES = \ | ||||
9 | mac_replace_strmem.c | ||||
njn | 717cde5 | 2005-05-10 02:47:21 +0000 | [diff] [blame] | 10 | vgpreload_memcheck_so_DEPENDENCIES = \ |
11 | $(LIBREPLACEMALLOC) | ||||
nethercote | 799fb80 | 2004-10-20 18:40:40 +0000 | [diff] [blame] | 12 | vgpreload_memcheck_so_LDFLAGS = -shared -Wl,-z,interpose,-z,initfirst \ |
13 | -Wl,--whole-archive \ | ||||
njn | 717cde5 | 2005-05-10 02:47:21 +0000 | [diff] [blame] | 14 | $(LIBREPLACEMALLOC) \ |
nethercote | 799fb80 | 2004-10-20 18:40:40 +0000 | [diff] [blame] | 15 | -Wl,--no-whole-archive |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 16 | |
njn | 063c540 | 2004-11-22 16:58:05 +0000 | [diff] [blame] | 17 | vgtool_memcheck_so_SOURCES = \ |
njn | 43c799e | 2003-04-08 00:08:52 +0000 | [diff] [blame] | 18 | mac_leakcheck.c \ |
njn | 3e88418 | 2003-04-15 13:03:23 +0000 | [diff] [blame] | 19 | mac_malloc_wrappers.c \ |
njn | 86f12dc | 2005-03-14 01:16:05 +0000 | [diff] [blame] | 20 | mc_main.c \ |
njn | 00cae24 | 2005-05-09 01:13:44 +0000 | [diff] [blame] | 21 | mac_shared.c \ |
njn | 39b4f01 | 2004-11-26 10:35:44 +0000 | [diff] [blame] | 22 | mc_translate.c |
njn | 063c540 | 2004-11-22 16:58:05 +0000 | [diff] [blame] | 23 | vgtool_memcheck_so_LDFLAGS = -shared |
njn25 | e49d8e7 | 2002-09-23 09:36:25 +0000 | [diff] [blame] | 24 | |
njn | 683c6ee | 2002-11-12 10:53:31 +0000 | [diff] [blame] | 25 | mcincludedir = $(includedir)/valgrind |
26 | |||||
27 | mcinclude_HEADERS = \ | ||||
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 28 | memcheck.h |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 29 | |
sewardj | b4db402 | 2002-12-08 22:19:04 +0000 | [diff] [blame] | 30 | noinst_HEADERS = \ |
njn | 43c799e | 2003-04-08 00:08:52 +0000 | [diff] [blame] | 31 | mac_shared.h \ |
njn | 683c6ee | 2002-11-12 10:53:31 +0000 | [diff] [blame] | 32 | mc_include.h |
33 | |||||
njn | 66fe05a | 2003-07-22 09:12:33 +0000 | [diff] [blame] | 34 | mac_replace_strmem.o: CFLAGS += -fno-omit-frame-pointer |
njn | 3e88418 | 2003-04-15 13:03:23 +0000 | [diff] [blame] | 35 | |
sewardj | 23eb2fd | 2005-04-22 16:29:19 +0000 | [diff] [blame] | 36 | mc_main.o: CFLAGS += -fomit-frame-pointer |