1
2include $(top_srcdir)/Makefile.tool-tests.am
3
4SUBDIRS = .
5
6# Arch-specific tests.
7if VGCONF_ARCHS_INCLUDE_X86
8SUBDIRS += x86
9endif
10if VGCONF_ARCHS_INCLUDE_AMD64
11SUBDIRS += amd64
12endif
13if VGCONF_ARCHS_INCLUDE_PPC32
14SUBDIRS += ppc32
15endif
16if VGCONF_ARCHS_INCLUDE_PPC64
17SUBDIRS += ppc64
18endif
19if VGCONF_ARCHS_INCLUDE_S390X
20SUBDIRS += s390x
21endif
22
23# OS-specific tests
24if VGCONF_OS_IS_LINUX
25SUBDIRS += linux
26endif
27if VGCONF_OS_IS_DARWIN
28SUBDIRS += darwin
29endif
30
31# Platform-specific tests
32if VGCONF_PLATFORMS_INCLUDE_X86_LINUX
33SUBDIRS += x86-linux
34endif
35if VGCONF_PLATFORMS_INCLUDE_AMD64_LINUX
36SUBDIRS += amd64-linux
37endif
38
39DIST_SUBDIRS = x86 amd64 ppc32 ppc64 s390x linux \
40		darwin x86-linux amd64-linux common .
41
42dist_noinst_SCRIPTS = \
43	filter_addressable \
44	filter_allocs \
45	filter_dw4 \
46	filter_leak_cases_possible \
47	filter_stderr filter_xml \
48	filter_strchr \
49	filter_varinfo3 \
50	filter_memcheck
51
52noinst_HEADERS = leak.h
53
54EXTRA_DIST = \
55	accounting.stderr.exp accounting.vgtest \
56	addressable.stderr.exp addressable.stdout.exp addressable.vgtest \
57	atomic_incs.stderr.exp atomic_incs.vgtest \
58	atomic_incs.stdout.exp-32bit atomic_incs.stdout.exp-64bit \
59	badaddrvalue.stderr.exp \
60	badaddrvalue.stdout.exp badaddrvalue.vgtest \
61	badfree-2trace.stderr.exp badfree-2trace.vgtest \
62	badfree.stderr.exp badfree.vgtest \
63	badfree3.stderr.exp badfree3.vgtest \
64	badjump.stderr.exp badjump.vgtest \
65	badjump2.stderr.exp badjump2.vgtest \
66	badjump.stderr.exp-kfail \
67	badjump2.stderr.exp-kfail \
68	badloop.stderr.exp badloop.vgtest \
69	badpoll.stderr.exp badpoll.vgtest \
70	badrw.stderr.exp badrw.vgtest badrw.stderr.exp-s390x-mvc \
71	big_blocks_freed_list.stderr.exp big_blocks_freed_list.vgtest \
72	brk2.stderr.exp brk2.vgtest \
73	buflen_check.stderr.exp buflen_check.vgtest \
74		buflen_check.stderr.exp-kfail \
75	bug287260.stderr.exp bug287260.vgtest \
76	calloc-overflow.stderr.exp calloc-overflow.vgtest\
77	client-msg.stderr.exp client-msg.vgtest \
78	client-msg-as-xml.stderr.exp client-msg-as-xml.vgtest \
79	clientperm.stderr.exp \
80	clientperm.stdout.exp clientperm.vgtest \
81	clireq_nofill.stderr.exp \
82	clireq_nofill.stdout.exp clireq_nofill.vgtest \
83	clo_redzone_default.vgtest clo_redzone_128.vgtest \
84	clo_redzone_default.stderr.exp clo_redzone_128.stderr.exp \
85	cond_ld.vgtest cond_ld.stdout.exp cond_ld.stderr.exp-arm \
86		cond_ld.stderr.exp-64bit-non-arm \
87		cond_ld.stderr.exp-32bit-non-arm \
88	cond_st.vgtest cond_st.stdout.exp cond_st.stderr.exp-arm \
89		cond_st.stderr.exp-64bit-non-arm \
90		cond_st.stderr.exp-32bit-non-arm \
91	leak_cpp_interior.stderr.exp leak_cpp_interior.stderr.exp-64bit leak_cpp_interior.vgtest \
92	custom_alloc.stderr.exp custom_alloc.vgtest \
93		custom_alloc.stderr.exp-s390x-mvc \
94	custom-overlap.stderr.exp custom-overlap.vgtest \
95	deep-backtrace.vgtest deep-backtrace.stderr.exp \
96	deep_templates.vgtest \
97	deep_templates.stdout.exp deep_templates.stderr.exp \
98	describe-block.stderr.exp describe-block.vgtest \
99	doublefree.stderr.exp doublefree.vgtest \
100	dw4.vgtest dw4.stderr.exp dw4.stdout.exp \
101	err_disable1.vgtest err_disable1.stderr.exp \
102	err_disable2.vgtest err_disable2.stderr.exp \
103	err_disable3.vgtest err_disable3.stderr.exp \
104	err_disable4.vgtest err_disable4.stderr.exp \
105	err_disable_arange1.vgtest err_disable_arange1.stderr.exp \
106	erringfds.stderr.exp erringfds.stdout.exp erringfds.vgtest \
107	error_counts.stderr.exp error_counts.vgtest \
108	errs1.stderr.exp errs1.vgtest \
109	exitprog.stderr.exp exitprog.vgtest \
110	execve1.stderr.exp execve1.vgtest execve1.stderr.exp-kfail \
111	execve2.stderr.exp execve2.vgtest execve2.stderr.exp-kfail \
112	file_locking.stderr.exp file_locking.vgtest \
113	fprw.stderr.exp fprw.stderr.exp-mips32-be fprw.stderr.exp-mips32-le \
114		fprw.vgtest \
115	fwrite.stderr.exp fwrite.vgtest fwrite.stderr.exp-kfail \
116	holey_buffer_too_small.vgtest holey_buffer_too_small.stdout.exp \
117	holey_buffer_too_small.stderr.exp \
118	inits.stderr.exp inits.vgtest \
119	inline.stderr.exp inline.stdout.exp inline.vgtest \
120	leak-0.vgtest leak-0.stderr.exp \
121	leak-cases-full.vgtest leak-cases-full.stderr.exp \
122	leak-cases-possible.vgtest leak-cases-possible.stderr.exp \
123	leak-cases-summary.vgtest leak-cases-summary.stderr.exp \
124	leak-cycle.vgtest leak-cycle.stderr.exp \
125	leak-delta.vgtest leak-delta.stderr.exp \
126	leak-pool-0.vgtest leak-pool-0.stderr.exp \
127	leak-pool-1.vgtest leak-pool-1.stderr.exp \
128	leak-pool-2.vgtest leak-pool-2.stderr.exp \
129	leak-pool-3.vgtest leak-pool-3.stderr.exp \
130	leak-pool-4.vgtest leak-pool-4.stderr.exp \
131	leak-pool-5.vgtest leak-pool-5.stderr.exp \
132	leak-tree.vgtest leak-tree.stderr.exp \
133	leak-segv-jmp.vgtest leak-segv-jmp.stderr.exp \
134	lks.vgtest lks.stdout.exp lks.supp lks.stderr.exp \
135	long_namespace_xml.vgtest long_namespace_xml.stdout.exp \
136	long_namespace_xml.stderr.exp \
137	long-supps.vgtest long-supps.stderr.exp long-supps.supp \
138	mallinfo.stderr.exp mallinfo.vgtest \
139	malloc_free_fill.vgtest \
140	malloc_free_fill.stderr.exp \
141	malloc_usable.stderr.exp malloc_usable.vgtest \
142	malloc1.stderr.exp malloc1.vgtest \
143	malloc1_ks_none.stderr.exp malloc1_ks_none.vgtest \
144	malloc1_ks_alloc.stderr.exp malloc1_ks_alloc.vgtest \
145	malloc1_ks_free.stderr.exp malloc1_ks_free.vgtest \
146	malloc1_ks_alloc_and_free.stderr.exp malloc1_ks_alloc_and_free.vgtest \
147	malloc2.stderr.exp malloc2.vgtest \
148	malloc3.stderr.exp malloc3.stdout.exp malloc3.vgtest \
149	manuel1.stderr.exp manuel1.stdout.exp manuel1.vgtest \
150	manuel2.stderr.exp manuel2.stderr.exp64 manuel2.stdout.exp \
151		manuel2.vgtest \
152	manuel3.stderr.exp manuel3.vgtest \
153	match-overrun.stderr.exp match-overrun.vgtest match-overrun.supp \
154	memalign_test.stderr.exp memalign_test.vgtest \
155	memalign2.stderr.exp memalign2.vgtest \
156	memcmptest.stderr.exp memcmptest.stderr.exp2 \
157	memcmptest.stdout.exp memcmptest.vgtest \
158	mempool.stderr.exp mempool.vgtest \
159	mempool2.stderr.exp mempool2.vgtest \
160	metadata.stderr.exp metadata.stdout.exp metadata.vgtest \
161	mismatches.stderr.exp mismatches.vgtest \
162	mmaptest.stderr.exp mmaptest.vgtest \
163	nanoleak_supp.stderr.exp nanoleak_supp.vgtest nanoleak.supp \
164	nanoleak2.stderr.exp nanoleak2.vgtest \
165	new_nothrow.stderr.exp new_nothrow.vgtest \
166	new_override.stderr.exp new_override.stdout.exp new_override.vgtest \
167	noisy_child.vgtest noisy_child.stderr.exp noisy_child.stdout.exp \
168	null_socket.stderr.exp null_socket.vgtest \
169	origin1-yes.vgtest origin1-yes.stdout.exp origin1-yes.stderr.exp \
170	origin2-not-quite.vgtest origin2-not-quite.stdout.exp \
171	origin2-not-quite.stderr.exp \
172	origin3-no.vgtest origin3-no.stdout.exp \
173	origin3-no.stderr.exp \
174	origin4-many.vgtest origin4-many.stdout.exp \
175	origin4-many.stderr.exp \
176	origin5-bz2.vgtest origin5-bz2.stdout.exp \
177	origin5-bz2.stderr.exp-glibc25-x86 \
178	origin5-bz2.stderr.exp-glibc25-amd64 \
179	origin5-bz2.stderr.exp-glibc25-amd64-b \
180	origin5-bz2.stderr.exp-glibc27-ppc64 \
181	origin5-bz2.stderr.exp-glibc212-s390x \
182	origin5-bz2.stderr.exp-glibc234-s390x \
183	origin5-bz2.stderr.exp-glibc218-mips32 \
184	origin6-fp.vgtest origin6-fp.stdout.exp \
185	origin6-fp.stderr.exp-glibc25-amd64 \
186	origin6-fp.stderr.exp-glibc27-ppc64 \
187	overlap.stderr.exp overlap.stdout.exp overlap.vgtest \
188	partiallydefinedeq.vgtest partiallydefinedeq.stderr.exp \
189	partiallydefinedeq.stderr.exp4 \
190	partiallydefinedeq.stderr.exp3 \
191	partiallydefinedeq.stderr.exp2 \
192	partiallydefinedeq.stdout.exp \
193	partial_load_ok.vgtest partial_load_ok.stderr.exp \
194		partial_load_ok.stderr.exp64 \
195	partial_load_dflt.vgtest partial_load_dflt.stderr.exp \
196		partial_load_dflt.stderr.exp64 \
197	partial_load_dflt.stderr.expr-s390x-mvc \
198	pdb-realloc.stderr.exp pdb-realloc.vgtest \
199	pdb-realloc2.stderr.exp pdb-realloc2.stdout.exp pdb-realloc2.vgtest \
200	pipe.stderr.exp pipe.vgtest \
201	pointer-trace.vgtest \
202	pointer-trace.stderr.exp \
203	post-syscall.stderr.exp post-syscall.vgtest \
204	reach_thread_register.stderr.exp reach_thread_register.vgtest \
205		reach_thread_register.stderr.exp-mips32 \
206		reach_thread_register.stderr.exp-mips64 \
207	realloc1.stderr.exp realloc1.vgtest \
208	realloc2.stderr.exp realloc2.vgtest \
209	realloc3.stderr.exp realloc3.vgtest \
210	recursive-merge.stderr.exp recursive-merge.vgtest \
211	sbfragment.stdout.exp sbfragment.stderr.exp sbfragment.vgtest \
212	sem.stderr.exp sem.vgtest \
213	sendmsg.stderr.exp sendmsg.vgtest \
214	sh-mem.stderr.exp sh-mem.vgtest \
215	sh-mem-random.stderr.exp sh-mem-random.stdout.exp64 \
216	sh-mem-random.stdout.exp sh-mem-random.vgtest \
217	sigaltstack.stderr.exp sigaltstack.vgtest \
218	sigkill.stderr.exp sigkill.stderr.exp-darwin sigkill.stderr.exp-mips32 \
219	sigkill.vgtest \
220	signal2.stderr.exp signal2.stdout.exp signal2.vgtest \
221	sigprocmask.stderr.exp sigprocmask.stderr.exp2 sigprocmask.vgtest \
222	static_malloc.stderr.exp static_malloc.vgtest \
223	stpncpy.vgtest stpncpy.stderr.exp stpncpy.stdout.exp \
224	strchr.stderr.exp strchr.stderr.exp2 strchr.stderr.exp3 strchr.vgtest \
225	str_tester.stderr.exp str_tester.vgtest \
226	supp-dir.vgtest supp-dir.stderr.exp \
227	supp_unknown.stderr.exp supp_unknown.vgtest supp_unknown.supp \
228	supp_unknown.stderr.exp-kfail \
229	supp1.stderr.exp supp1.vgtest \
230	supp2.stderr.exp supp2.vgtest \
231	supp.supp \
232	suppfree.stderr.exp suppfree.supp suppfree.vgtest \
233	suppfreecollision.stderr.exp suppfreecollision.supp suppfreecollision.vgtest \
234	test-plo-no.vgtest test-plo-no.stdout.exp \
235	    test-plo-no.stderr.exp-le64 test-plo-no.stderr.exp-le32 \
236	test-plo-yes.vgtest test-plo-yes.stdout.exp \
237	    test-plo-yes.stderr.exp-le64 test-plo-yes.stderr.exp-le32 \
238	    test-plo-no.stderr.exp-s390x-mvc \
239	thread_alloca.stderr.exp thread_alloca.vgtest \
240	trivialleak.stderr.exp trivialleak.vgtest trivialleak.stderr.exp2 \
241	undef_malloc_args.stderr.exp undef_malloc_args.vgtest \
242	unit_libcbase.stderr.exp unit_libcbase.vgtest \
243	unit_oset.stderr.exp unit_oset.stdout.exp unit_oset.vgtest \
244	varinfo1.vgtest varinfo1.stdout.exp varinfo1.stderr.exp \
245		varinfo1.stderr.exp-ppc64 \
246	varinfo2.vgtest varinfo2.stdout.exp varinfo2.stderr.exp \
247		varinfo2.stderr.exp-ppc64 \
248	varinfo3.vgtest varinfo3.stdout.exp varinfo3.stderr.exp \
249		varinfo3.stderr.exp-ppc64 \
250	varinfo4.vgtest varinfo4.stdout.exp varinfo4.stderr.exp \
251		varinfo4.stderr.exp-ppc64 \
252	varinfo5.vgtest varinfo5.stdout.exp varinfo5.stderr.exp \
253		varinfo5.stderr.exp-ppc64 \
254	varinfo6.vgtest varinfo6.stdout.exp varinfo6.stderr.exp \
255		varinfo6.stderr.exp-ppc64 \
256	vcpu_bz2.stdout.exp vcpu_bz2.stderr.exp vcpu_bz2.vgtest \
257	vcpu_fbench.stdout.exp vcpu_fbench.stderr.exp vcpu_fbench.vgtest \
258	vcpu_fnfns.stdout.exp vcpu_fnfns.stdout.exp-glibc28-amd64 \
259	vcpu_fnfns.stdout.exp-darwin vcpu_fnfns.stderr.exp vcpu_fnfns.vgtest \
260	wcs.vgtest wcs.stderr.exp wcs.stdout.exp \
261	wrap1.vgtest wrap1.stdout.exp wrap1.stderr.exp \
262	wrap2.vgtest wrap2.stdout.exp wrap2.stderr.exp \
263	wrap3.vgtest wrap3.stdout.exp wrap3.stderr.exp \
264	wrap4.vgtest wrap4.stdout.exp wrap4.stderr.exp \
265	wrap5.vgtest wrap5.stdout.exp wrap5.stderr.exp \
266	wrap6.vgtest wrap6.stdout.exp wrap6.stderr.exp \
267	wrap7.vgtest wrap7.stdout.exp wrap7.stderr.exp \
268	wrap8.vgtest wrap8.stdout.exp wrap8.stderr.exp \
269	wrap8.stdout.exp2 wrap8.stderr.exp2 \
270	writev1.stderr.exp writev1.vgtest \
271	xml1.stderr.exp xml1.stdout.exp xml1.vgtest xml1.stderr.exp-s390x-mvc \
272	threadname.vgtest threadname.stderr.exp \
273	threadname_xml.vgtest threadname_xml.stderr.exp
274
275check_PROGRAMS = \
276	accounting \
277	addressable \
278	atomic_incs \
279	badaddrvalue badfree badjump badjump2 \
280	badloop \
281	badpoll \
282	badrw \
283	big_blocks_freed_list \
284	brk2 \
285	buflen_check \
286	bug287260 \
287	calloc-overflow \
288	client-msg \
289	clientperm \
290	clireq_nofill \
291	clo_redzone \
292	cond_ld_st \
293	leak_cpp_interior \
294	custom_alloc \
295	custom-overlap \
296	deep-backtrace \
297	describe-block \
298	doublefree error_counts errs1 exitprog execve1 execve2 erringfds \
299	err_disable1 err_disable2 err_disable3 err_disable4 \
300	err_disable_arange1 \
301	file_locking \
302	fprw fwrite inits inline \
303	holey_buffer_too_small \
304	leak-0 \
305	leak-cases \
306	leak-cycle \
307	leak-delta \
308	leak-pool \
309	leak-tree \
310	leak-segv-jmp \
311	long_namespace_xml \
312	long-supps \
313	mallinfo \
314	malloc_free_fill \
315	malloc_usable malloc1 malloc2 malloc3 manuel1 manuel2 manuel3 \
316	match-overrun \
317	memalign_test memalign2 memcmptest mempool mempool2 mmaptest \
318	mismatches new_override metadata \
319	nanoleak_supp nanoleak2 new_nothrow \
320	noisy_child \
321	null_socket \
322	origin1-yes origin2-not-quite origin3-no \
323	origin4-many origin5-bz2 origin6-fp \
324	overlap \
325	partiallydefinedeq \
326	partial_load pdb-realloc pdb-realloc2 \
327	pipe pointer-trace \
328	post-syscall \
329	realloc1 realloc2 realloc3 \
330	recursive-merge \
331	sbfragment \
332	sendmsg \
333	sh-mem sh-mem-random \
334	sigaltstack signal2 sigprocmask static_malloc sigkill \
335	strchr \
336	str_tester \
337	supp_unknown supp1 supp2 suppfree \
338	test-plo \
339	trivialleak \
340	thread_alloca \
341	undef_malloc_args \
342	unit_libcbase unit_oset \
343	varinfo1 varinfo2 varinfo3 varinfo4 \
344	varinfo5 varinfo5so.so varinfo6 \
345	vcpu_fbench vcpu_fnfns \
346	wcs \
347	xml1 \
348	wrap1 wrap2 wrap3 wrap4 wrap5 wrap6 wrap7 wrap7so.so wrap8 \
349	writev1
350
351if DWARF4
352check_PROGRAMS += dw4
353endif
354
355if HAVE_GNU_STPNCPY
356check_PROGRAMS += stpncpy
357endif
358
359if HAVE_PTHREAD_SETNAME_NP
360check_PROGRAMS += threadname 
361endif
362
363if HAVE_PTHREAD_BARRIER
364check_PROGRAMS += reach_thread_register
365endif
366
367if HAVE_GSTABS
368check_PROGRAMS += deep_templates
369endif
370
371AM_CFLAGS   += $(AM_FLAG_M3264_PRI)
372AM_CXXFLAGS += $(AM_FLAG_M3264_PRI)
373
374if VGCONF_PLATFORMS_INCLUDE_ARM_LINUX
375#AM_CFLAGS   += -mfloat-abi=softfp
376#AM_CXXFLAGS += -mfloat-abi=softfp
377endif
378
379if VGCONF_OS_IS_DARWIN
380atomic_incs_CFLAGS = $(AM_CFLAGS) -mdynamic-no-pic
381else
382atomic_incs_CFLAGS = $(AM_CFLAGS)
383endif
384
385leak_cpp_interior_SOURCES	= leak_cpp_interior.cpp
386
387deep_templates_SOURCES	= deep_templates.cpp
388deep_templates_CXXFLAGS	= $(AM_CFLAGS) -O -gstabs
389
390dw4_CFLAGS		= $(AM_CFLAGS) -gdwarf-4 -fdebug-types-section
391
392err_disable3_LDADD 	= -lpthread
393err_disable4_LDADD 	= -lpthread
394reach_thread_register_CFLAGS	= $(AM_CFLAGS) -O2
395reach_thread_register_LDADD     = -lpthread
396thread_alloca_LDADD     = -lpthread
397threadname_LDADD 	= -lpthread
398
399error_counts_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
400
401execve1_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
402
403execve2_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
404
405fprw_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
406
407inits_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
408
409long_namespace_xml_SOURCES = long_namespace_xml.cpp
410
411manuel1_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
412
413memcmptest_CFLAGS	= $(AM_CFLAGS) -fno-builtin-memcmp
414
415mismatches_SOURCES	= mismatches.cpp
416
417new_nothrow_SOURCES 	= new_nothrow.cpp
418new_override_SOURCES 	= new_override.cpp
419
420origin1_yes_CFLAGS      = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
421
422origin2_not_quite_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
423
424origin3_no_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
425
426# This requires optimisation in order to get just one resulting error.
427origin4_many_CFLAGS	= $(AM_CFLAGS) -O
428
429# Apply -O so as to run in reasonable time.
430origin5_bz2_CFLAGS	= $(AM_CFLAGS) -O -Wno-inline
431origin6_fp_CFLAGS	= $(AM_CFLAGS) -O
432
433# Don't allow GCC to inline memcpy() and strcpy(),
434# because then we can't intercept it
435overlap_CFLAGS		= $(AM_CFLAGS) -fno-builtin-memcpy -fno-builtin-strcpy
436
437str_tester_CFLAGS	= $(AM_CFLAGS) -Wno-shadow
438
439supp_CFLAGS             = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
440
441supp_unknown_SOURCES	= badjump.c
442supp_unknown_CFLAGS     = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
443
444supp1_SOURCES		= supp.c
445supp1_CFLAGS            = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
446
447supp2_SOURCES		= supp.c
448supp2_CFLAGS            = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
449
450vcpu_bz2_CFLAGS		= $(AM_CFLAGS) -O2
451vcpu_fbench_CFLAGS	= $(AM_CFLAGS) -O2
452vcpu_fnfns_CFLAGS	= $(AM_CFLAGS) -O2
453vcpu_fnfns_LDADD	= -lm
454wrap6_CFLAGS		= $(AM_CFLAGS) -O2
455
456# To make it a bit more realistic, have some optimisation enabled
457# for the varinfo tests.  We still expect sane results.
458varinfo1_CFLAGS		= $(AM_CFLAGS) -O
459varinfo2_CFLAGS		= $(AM_CFLAGS) -O -Wno-shadow
460varinfo3_CFLAGS		= $(AM_CFLAGS) -O
461varinfo4_CFLAGS		= $(AM_CFLAGS) -O
462varinfo5_CFLAGS		= $(AM_CFLAGS) -O
463varinfo6_CFLAGS		= $(AM_CFLAGS) -O
464
465# Build shared object for varinfo5
466varinfo5_SOURCES        = varinfo5.c
467varinfo5_DEPENDENCIES   = varinfo5so.so
468if VGCONF_OS_IS_DARWIN
469 varinfo5_LDADD         = `pwd`/varinfo5so.so
470 varinfo5_LDFLAGS       = $(AM_FLAG_M3264_PRI)
471else
472 varinfo5_LDADD         = varinfo5so.so
473 varinfo5_LDFLAGS       = $(AM_FLAG_M3264_PRI) \
474				-Wl,-rpath,$(top_builddir)/memcheck/tests
475endif
476
477varinfo5so_so_SOURCES   = varinfo5so.c
478varinfo5so_so_CFLAGS    = $(AM_CFLAGS) -fpic -O -Wno-shadow
479if VGCONF_OS_IS_DARWIN
480 varinfo5so_so_LDFLAGS  = -fpic $(AM_FLAG_M3264_PRI) -dynamic \
481				-dynamiclib -all_load
482else
483 varinfo5so_so_LDFLAGS  = -fpic $(AM_FLAG_M3264_PRI) -shared \
484				-Wl,-soname -Wl,varinfo5so.so
485endif
486
487# Build shared object for wrap7
488wrap7_SOURCES           = wrap7.c
489wrap7_DEPENDENCIES      = wrap7so.so
490if VGCONF_OS_IS_DARWIN
491 wrap7_LDADD            = `pwd`/wrap7so.so
492 wrap7_LDFLAGS          = $(AM_FLAG_M3264_PRI)
493else
494 wrap7_LDADD            = wrap7so.so
495 wrap7_LDFLAGS          = $(AM_FLAG_M3264_PRI) \
496				-Wl,-rpath,$(top_builddir)/memcheck/tests
497endif
498
499wrap7so_so_SOURCES      = wrap7so.c
500wrap7so_so_CFLAGS       = $(AM_CFLAGS) -fpic
501if VGCONF_OS_IS_DARWIN
502 wrap7so_so_LDFLAGS     = -fpic $(AM_FLAG_M3264_PRI) -dynamic \
503				-dynamiclib -all_load
504else
505 wrap7so_so_LDFLAGS     = -fpic $(AM_FLAG_M3264_PRI) -shared \
506				-Wl,-soname -Wl,wrap7so.so
507endif
508
509