Make tests consistently use *.out output files.

This patch systematically renames miscellaneous tests so their outputs
use a *.out name (unless the test is just running some glibc program
with its conventional output file name, rather than a special program
at all, as in catgets tests generating *.cat).  In the case of the
iconv test test-iconvconfig, output is redirected where it wasn't
before.

In various places the "generated" variable is updated to reflect the
revised test names; in iconvdata/Makefile a typo (mmtrace-tst-loading)
is also fixed.  resolv/Makefile sets both "generate" (which appears
unused) and "generated".  Bitrot in the settings of these variables
could no doubt be fixed so that "make clean" after build and testing
leaves results the same as after configure (and indeed the
tests-special / xtests-special variables could be used to simplify
things, by removing those files automatically rather than listing them
manually in these variables), and "make distclean" leaves an empty
build directory, but right now it appears various files don't get
deleted.  I think they are liable to continue to bitrot in the absence
of routine testing that these targets actually work, given that
building in the source directory isn't supported and that was the main
use of such makefile targets.

Tested x86_64.

	* elf/Makefile (tests-special): Rename tests to end with .out.
	($(objpfx)noload-mem): Likewise.
	($(objpfx)tst-leaks1-mem): Likewise.
	($(objpfx)tst-leaks1-static-mem.out): Likewise.
	* iconv/Makefile (xtests-special): Change test-iconvconfig to
	$(objpfx)test-iconvconfig.out.
	(test-iconvconfig): Change to $(objpfx)test-iconvconfig.out.  Use
	set -e inside subshell and redirect output to file.
	* iconvdata/Makefile (generated): Rename tests to end with .out.
	Correct type.
	(tests-special): Rename tests to end with .out.
	($(objpfx)mtrace-tst-loading): Likewise.
	* intl/Makefile (generated): Likewise.
	(tests-special): Likewise.
	($(objpfx)mtrace-tst-gettext): Likewise.
	* misc/Makefile (generated): Likewise.
	(tests-special): Likewise.
	($(objpfx)tst-error1-mem): Likewise.
	* nptl/Makefile (tests-special): Likewise.
	($(objpfx)tst-stack3-mem): Likewise.
	(generated): Likewise.
	* posix/Makefile (generated): Likewise.
	(tests-special): Likewise.
	(xtests-special): Likewise.
	($(objpfx)tst-fnmatch-mem): Likewise.
	($(objpfx)bug-regex2-mem): Likewise.
	($(objpfx)bug-regex14-mem): Likewise.
	($(objpfx)bug-regex21-mem): Likewise.
	($(objpfx)bug-regex31-mem): Likewise.
	($(objpfx)tst-vfork3-mem): Likewise.
	($(objpfx)tst-rxspencer-no-utf8-mem): Likewise.
	($(objpfx)tst-pcre-mem): Likewise.
	($(objpfx)tst-boost-mem): Likewise.
	($(objpfx)bug-ga2-mem): Likewise.
	($(objpfx)bug-glob2-mem): Likewise.
	* resolv/Makefile (generate): Likewise.
	(tests-special): Likewise.
	(xtests-special): Likewise.
	(generated): Likewise.
	($(objpfx)mtrace-tst-leaks): Likewise.
	($(objpfx)mtrace-tst-leaks2): Likewise.

localedata:
	* Makefile (generated): Rename tests to end with .out.
	(tests-special): Likewise.
	($(objpfx)mtrace-tst-leaks): Likewise.
This commit is contained in:
Joseph Myers 2014-03-07 03:29:23 +00:00
parent 265d52abcb
commit 0b20a9e89f
11 changed files with 111 additions and 62 deletions

View File

@ -1,5 +1,47 @@
2014-03-07 Joseph Myers <joseph@codesourcery.com> 2014-03-07 Joseph Myers <joseph@codesourcery.com>
* elf/Makefile (tests-special): Rename tests to end with .out.
($(objpfx)noload-mem): Likewise.
($(objpfx)tst-leaks1-mem): Likewise.
($(objpfx)tst-leaks1-static-mem.out): Likewise.
* iconv/Makefile (xtests-special): Change test-iconvconfig to
$(objpfx)test-iconvconfig.out.
(test-iconvconfig): Change to $(objpfx)test-iconvconfig.out. Use
set -e inside subshell and redirect output to file.
* iconvdata/Makefile (generated): Rename tests to end with .out.
Correct type.
(tests-special): Rename tests to end with .out.
($(objpfx)mtrace-tst-loading): Likewise.
* intl/Makefile (generated): Likewise.
(tests-special): Likewise.
($(objpfx)mtrace-tst-gettext): Likewise.
* misc/Makefile (generated): Likewise.
(tests-special): Likewise.
($(objpfx)tst-error1-mem): Likewise.
* nptl/Makefile (tests-special): Likewise.
($(objpfx)tst-stack3-mem): Likewise.
(generated): Likewise.
* posix/Makefile (generated): Likewise.
(tests-special): Likewise.
(xtests-special): Likewise.
($(objpfx)tst-fnmatch-mem): Likewise.
($(objpfx)bug-regex2-mem): Likewise.
($(objpfx)bug-regex14-mem): Likewise.
($(objpfx)bug-regex21-mem): Likewise.
($(objpfx)bug-regex31-mem): Likewise.
($(objpfx)tst-vfork3-mem): Likewise.
($(objpfx)tst-rxspencer-no-utf8-mem): Likewise.
($(objpfx)tst-pcre-mem): Likewise.
($(objpfx)tst-boost-mem): Likewise.
($(objpfx)bug-ga2-mem): Likewise.
($(objpfx)bug-glob2-mem): Likewise.
* resolv/Makefile (generate): Likewise.
(tests-special): Likewise.
(xtests-special): Likewise.
(generated): Likewise.
($(objpfx)mtrace-tst-leaks): Likewise.
($(objpfx)mtrace-tst-leaks2): Likewise.
* scripts/merge-test-results.sh: New file. * scripts/merge-test-results.sh: New file.
* Makefile (tests-special-notdir): New variable. * Makefile (tests-special-notdir): New variable.
(tests): Run merge-test-results.sh. (tests): Run merge-test-results.sh.

View File

@ -157,8 +157,8 @@ tests-execstack-yes = tst-execstack tst-execstack-needed tst-execstack-prog
endif endif
endif endif
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
tests-special += $(objpfx)tst-leaks1-mem $(objpfx)tst-leaks1-static-mem \ tests-special += $(objpfx)tst-leaks1-mem.out \
$(objpfx)noload-mem $(objpfx)tst-leaks1-static-mem.out $(objpfx)noload-mem.out
endif endif
tlsmod17a-suffixes = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 tlsmod17a-suffixes = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
tlsmod18a-suffixes = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 tlsmod18a-suffixes = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
@ -665,7 +665,7 @@ $(objpfx)noload: $(objpfx)testobj1.so $(common-objpfx)dlfcn/libdl.so
LDFLAGS-noload = -rdynamic $(no-as-needed) LDFLAGS-noload = -rdynamic $(no-as-needed)
$(objpfx)noload.out: $(objpfx)testobj5.so $(objpfx)noload.out: $(objpfx)testobj5.so
$(objpfx)noload-mem: $(objpfx)noload.out $(objpfx)noload-mem.out: $(objpfx)noload.out
$(common-objpfx)malloc/mtrace $(objpfx)noload.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)noload.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
noload-ENV = MALLOC_TRACE=$(objpfx)noload.mtrace noload-ENV = MALLOC_TRACE=$(objpfx)noload.mtrace
@ -1047,12 +1047,12 @@ CFLAGS-tst-ptrguard1-static.c = -DPTRGUARD_LOCAL
tst-ptrguard1-static-ARGS = --command "$(objpfx)tst-ptrguard1-static --child" tst-ptrguard1-static-ARGS = --command "$(objpfx)tst-ptrguard1-static --child"
$(objpfx)tst-leaks1: $(libdl) $(objpfx)tst-leaks1: $(libdl)
$(objpfx)tst-leaks1-mem: $(objpfx)tst-leaks1.out $(objpfx)tst-leaks1-mem.out: $(objpfx)tst-leaks1.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-leaks1.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-leaks1.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
$(objpfx)tst-leaks1-static: $(common-objpfx)dlfcn/libdl.a $(objpfx)tst-leaks1-static: $(common-objpfx)dlfcn/libdl.a
$(objpfx)tst-leaks1-static-mem: $(objpfx)tst-leaks1-static.out $(objpfx)tst-leaks1-static-mem.out: $(objpfx)tst-leaks1-static.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-leaks1-static.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-leaks1-static.mtrace > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -61,7 +61,7 @@ CPPFLAGS-charmap = -DNOT_IN_libc
CPPFLAGS-charmap-dir = -DNOT_IN_libc CPPFLAGS-charmap-dir = -DNOT_IN_libc
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
xtests-special += test-iconvconfig xtests-special += $(objpfx)test-iconvconfig.out
endif endif
include ../Rules include ../Rules
@ -72,11 +72,11 @@ $(inst_bindir)/iconv: $(objpfx)iconv_prog $(+force)
$(objpfx)iconv_prog: $(iconv_prog-modules:%=$(objpfx)%.o) $(objpfx)iconv_prog: $(iconv_prog-modules:%=$(objpfx)%.o)
$(objpfx)iconvconfig: $(iconvconfig-modules:%=$(objpfx)%.o) $(objpfx)iconvconfig: $(iconvconfig-modules:%=$(objpfx)%.o)
.PHONY: test-iconvconfig $(objpfx)test-iconvconfig.out: /dev/null $(objpfx)iconvconfig
test-iconvconfig: /dev/null $(objpfx)iconvconfig (set -e; \
tmp=$(objpfx)gconv-modules.cache.$$$$; \ tmp=$(objpfx)gconv-modules.cache.$$$$; \
rm -f $$tmp; \ rm -f $$tmp; \
$(make-test-out) --output=$$tmp --nostdlib $(inst_gconvdir) && \ $(make-test-out) --output=$$tmp --nostdlib $(inst_gconvdir); \
cmp $$tmp $(inst_gconvdir)/gconv-modules.cache && \ cmp $$tmp $(inst_gconvdir)/gconv-modules.cache; \
rm -f $$tmp; \ rm -f $$tmp) > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -179,7 +179,7 @@ generated-modules := $(gen-8bit-modules) $(gen-8bit-gap-modules) \
generated += $(generated-modules:=.h) $(generated-modules:=.stmp) \ generated += $(generated-modules:=.h) $(generated-modules:=.stmp) \
iconv-test.out iconv-rules tst-loading.mtrace \ iconv-test.out iconv-rules tst-loading.mtrace \
mmtrace-tst-loading tst-tables.out iconv-test.xxx mtrace-tst-loading.out tst-tables.out iconv-test.xxx
ifdef objpfx ifdef objpfx
generated += gconv-modules generated += gconv-modules
endif endif
@ -269,7 +269,7 @@ ifeq ($(run-built-tests),yes)
ifeq (yes,$(build-shared)) ifeq (yes,$(build-shared))
tests-special += $(objpfx)iconv-test.out $(objpfx)tst-tables.out tests-special += $(objpfx)iconv-test.out $(objpfx)tst-tables.out
ifneq (no,$(PERL)) ifneq (no,$(PERL))
tests-special += $(objpfx)mtrace-tst-loading tests-special += $(objpfx)mtrace-tst-loading.out
endif endif
endif endif
endif endif
@ -277,7 +277,7 @@ endif
include ../Rules include ../Rules
tst-loading-ENV = MALLOC_TRACE=$(objpfx)tst-loading.mtrace tst-loading-ENV = MALLOC_TRACE=$(objpfx)tst-loading.mtrace
$(objpfx)mtrace-tst-loading: $(objpfx)tst-loading.out $(objpfx)mtrace-tst-loading.out: $(objpfx)tst-loading.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-loading.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-loading.mtrace > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -38,7 +38,7 @@ before-compile += $(objpfx)msgs.h
install-others = $(inst_msgcatdir)/locale.alias install-others = $(inst_msgcatdir)/locale.alias
generated += msgs.h mtrace-tst-gettext tst-gettext.mtrace generated += msgs.h mtrace-tst-gettext.out tst-gettext.mtrace
generated-dirs += domaindir localedir generated-dirs += domaindir localedir
ifneq (no,$(BISON)) ifneq (no,$(BISON))
@ -58,7 +58,7 @@ tests-special += $(objpfx)tst-gettext4.out $(objpfx)tst-gettext5.out \
$(objpfx)tst-gettext6.out $(objpfx)tst-gettext6.out
endif endif
ifneq (no,$(PERL)) ifneq (no,$(PERL))
tests-special += $(objpfx)mtrace-tst-gettext tests-special += $(objpfx)mtrace-tst-gettext.out
endif endif
endif endif
endif endif
@ -77,7 +77,7 @@ $(codeset_mo): tstcodeset.po
msgfmt -o $@T $< msgfmt -o $@T $<
mv -f $@T $@ mv -f $@T $@
$(objpfx)mtrace-tst-gettext: $(objpfx)tst-gettext.out $(objpfx)mtrace-tst-gettext.out: $(objpfx)tst-gettext.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-gettext.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-gettext.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
$(objpfx)tst-gettext.out: tst-gettext.sh $(objpfx)tst-gettext $(objpfx)tst-gettext.out: tst-gettext.sh $(objpfx)tst-gettext

View File

@ -1,3 +1,9 @@
2014-03-07 Joseph Myers <joseph@codesourcery.com>
* Makefile (generated): Rename tests to end with .out.
(tests-special): Likewise.
($(objpfx)mtrace-tst-leaks): Likewise.
2014-03-06 Joseph Myers <joseph@codesourcery.com> 2014-03-06 Joseph Myers <joseph@codesourcery.com>
* Makefile (tests): Change dependencies to .... * Makefile (tests): Change dependencies to ....

View File

@ -52,7 +52,7 @@ fmon-tests = n01y12 n02n40 n10y31 n11y41 n12y11 n20n32 n30y20 n41n00 \
y01y10 y02n22 y22n42 y30y21 y32n31 y40y00 y42n21 y01y10 y02n22 y22n42 y30y21 y32n31 y40y00 y42n21
generated += $(test-input) $(test-output) sort-test.out tst-locale.out \ generated += $(test-input) $(test-output) sort-test.out tst-locale.out \
tst-mbswcs.out tst-leaks.mtrace mtrace-tst-leaks tst-mbswcs.out tst-leaks.mtrace mtrace-tst-leaks.out
generated-dirs += $(ld-test-names) tt_TT de_DE.437 \ generated-dirs += $(ld-test-names) tt_TT de_DE.437 \
$(addprefix tstfmon_,$(fmon-tests)) \ $(addprefix tstfmon_,$(fmon-tests)) \
@ -79,7 +79,7 @@ tests-static = bug-setlocale1-static
tests += $(tests-static) tests += $(tests-static)
ifeq (yes,$(build-shared)) ifeq (yes,$(build-shared))
ifneq (no,$(PERL)) ifneq (no,$(PERL))
tests-special += $(objpfx)mtrace-tst-leaks tests-special += $(objpfx)mtrace-tst-leaks.out
endif endif
endif endif
endif endif
@ -292,7 +292,7 @@ tst-sscanf-ENV = LOCPATH=$(common-objpfx)localedata
tst-leaks-ENV = MALLOC_TRACE=$(objpfx)tst-leaks.mtrace \ tst-leaks-ENV = MALLOC_TRACE=$(objpfx)tst-leaks.mtrace \
LOCPATH=$(common-objpfx)localedata LOCPATH=$(common-objpfx)localedata
$(objpfx)mtrace-tst-leaks: $(objpfx)tst-leaks.out $(objpfx)mtrace-tst-leaks.out: $(objpfx)tst-leaks.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-leaks.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-leaks.mtrace > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -69,7 +69,7 @@ routines := brk sbrk sstk ioctl \
listxattr lgetxattr llistxattr lremovexattr lsetxattr \ listxattr lgetxattr llistxattr lremovexattr lsetxattr \
removexattr setxattr getauxval ifunc-impl-list removexattr setxattr getauxval ifunc-impl-list
generated += tst-error1.mtrace tst-error1-mem generated += tst-error1.mtrace tst-error1-mem.out
aux := init-misc aux := init-misc
install-lib := libg.a install-lib := libg.a
@ -78,7 +78,7 @@ gpl2lgpl := error.c error.h
tests := tst-dirname tst-tsearch tst-fdset tst-efgcvt tst-mntent tst-hsearch \ tests := tst-dirname tst-tsearch tst-fdset tst-efgcvt tst-mntent tst-hsearch \
tst-error1 tst-pselect tst-insremque tst-mntent2 bug-hsearch1 tst-error1 tst-pselect tst-insremque tst-mntent2 bug-hsearch1
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
tests-special += $(objpfx)tst-error1-mem tests-special += $(objpfx)tst-error1-mem.out
endif endif
CFLAGS-select.c = -fexceptions -fasynchronous-unwind-tables CFLAGS-select.c = -fexceptions -fasynchronous-unwind-tables
@ -110,6 +110,6 @@ endif
tst-error1-ENV = MALLOC_TRACE=$(objpfx)tst-error1.mtrace tst-error1-ENV = MALLOC_TRACE=$(objpfx)tst-error1.mtrace
tst-error1-ARGS = $(objpfx)tst-error1.out tst-error1-ARGS = $(objpfx)tst-error1.out
$(objpfx)tst-error1-mem: $(objpfx)tst-error1.out $(objpfx)tst-error1-mem.out: $(objpfx)tst-error1.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-error1.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-error1.mtrace > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -368,7 +368,7 @@ xtests-static += tst-setuid1-static
tests-reverse += tst-cancel5 tst-cancel23 tst-vfork1x tst-vfork2x tests-reverse += tst-cancel5 tst-cancel23 tst-vfork1x tst-vfork2x
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
tests-special += $(objpfx)tst-stack3-mem $(objpfx)tst-oddstacklimit.out tests-special += $(objpfx)tst-stack3-mem.out $(objpfx)tst-oddstacklimit.out
ifeq ($(build-shared),yes) ifeq ($(build-shared),yes)
tests-special += $(objpfx)tst-tls6.out $(objpfx)tst-cleanup0-cmp.out \ tests-special += $(objpfx)tst-tls6.out $(objpfx)tst-cleanup0-cmp.out \
$(objpfx)tst-cancel-wrappers.out $(objpfx)tst-cancel-wrappers.out
@ -466,10 +466,10 @@ tst-atfork2-ENV = MALLOC_TRACE=$(objpfx)tst-atfork2.mtrace
$(objpfx)tst-atfork2mod.so: $(shared-thread-library) $(objpfx)tst-atfork2mod.so: $(shared-thread-library)
tst-stack3-ENV = MALLOC_TRACE=$(objpfx)tst-stack3.mtrace tst-stack3-ENV = MALLOC_TRACE=$(objpfx)tst-stack3.mtrace
$(objpfx)tst-stack3-mem: $(objpfx)tst-stack3.out $(objpfx)tst-stack3-mem.out: $(objpfx)tst-stack3.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-stack3.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-stack3.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
generated += tst-stack3-mem tst-stack3.mtrace generated += tst-stack3-mem.out tst-stack3.mtrace
$(objpfx)tst-cleanup4: $(objpfx)tst-cleanup4aux.o $(shared-thread-library) $(objpfx)tst-cleanup4: $(objpfx)tst-cleanup4aux.o $(shared-thread-library)
$(objpfx)tst-cleanupx4: $(objpfx)tst-cleanup4aux.o $(shared-thread-library) $(objpfx)tst-cleanupx4: $(objpfx)tst-cleanup4aux.o $(shared-thread-library)

View File

@ -102,16 +102,17 @@ before-compile := testcases.h ptestcases.h
# So they get cleaned up. # So they get cleaned up.
generated += $(addprefix wordexp-test-result, 1 2 3 4 5 6 7 8 9 10) \ generated += $(addprefix wordexp-test-result, 1 2 3 4 5 6 7 8 9 10) \
annexc annexc.out wordexp-tst.out bug-regex2-mem \ annexc annexc.out wordexp-tst.out bug-regex2-mem.out \
bug-regex2.mtrace bug-regex14-mem bug-regex14.mtrace \ bug-regex2.mtrace bug-regex14-mem.out bug-regex14.mtrace \
bug-regex21-mem bug-regex21.mtrace \ bug-regex21-mem.out bug-regex21.mtrace \
bug-regex31-mem bug-regex31.mtrace \ bug-regex31-mem.out bug-regex31.mtrace \
tst-rxspencer-no-utf8-mem tst-rxspencer-no-utf8.mtrace \ tst-rxspencer-no-utf8-mem.out tst-rxspencer-no-utf8.mtrace \
tst-getconf.out \ tst-getconf.out \
tst-pcre-mem tst-pcre.mtrace tst-boost-mem tst-boost.mtrace \ tst-pcre-mem.out tst-pcre.mtrace tst-boost-mem.out \
bug-ga2.mtrace bug-ga2-mem bug-glob2.mtrace bug-glob2-mem \ tst-boost.mtrace bug-ga2.mtrace bug-ga2-mem.out \
tst-vfork3-mem tst-vfork3.mtrace getconf.speclist \ bug-glob2.mtrace bug-glob2-mem.out tst-vfork3-mem.out \
tst-fnmatch-mem tst-fnmatch.mtrace tst-vfork3.mtrace getconf.speclist tst-fnmatch-mem.out \
tst-fnmatch.mtrace
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
ifeq (yes,$(build-shared)) ifeq (yes,$(build-shared))
@ -123,13 +124,13 @@ endif
# XXX Please note that for now we ignore the result of this test. # XXX Please note that for now we ignore the result of this test.
tests-special += $(objpfx)annexc.out tests-special += $(objpfx)annexc.out
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
tests-special += $(objpfx)bug-regex2-mem $(objpfx)bug-regex14-mem \ tests-special += $(objpfx)bug-regex2-mem.out $(objpfx)bug-regex14-mem.out \
$(objpfx)bug-regex21-mem $(objpfx)bug-regex31-mem \ $(objpfx)bug-regex21-mem.out $(objpfx)bug-regex31-mem.out \
$(objpfx)tst-rxspencer-no-utf8-mem $(objpfx)tst-pcre-mem \ $(objpfx)tst-rxspencer-no-utf8-mem.out $(objpfx)tst-pcre-mem.out \
$(objpfx)tst-boost-mem $(objpfx)tst-getconf.out \ $(objpfx)tst-boost-mem.out $(objpfx)tst-getconf.out \
$(objpfx)bug-glob2-mem $(objpfx)tst-vfork3-mem \ $(objpfx)bug-glob2-mem.out $(objpfx)tst-vfork3-mem.out \
$(objpfx)tst-fnmatch-mem $(objpfx)tst-fnmatch-mem.out
xtests-special += $(objpfx)bug-ga2-mem xtests-special += $(objpfx)bug-ga2-mem.out
endif endif
include ../Rules include ../Rules
@ -251,37 +252,37 @@ $(objpfx)annexc: annexc.c
tst-fnmatch-ENV += MALLOC_TRACE=$(objpfx)tst-fnmatch.mtrace tst-fnmatch-ENV += MALLOC_TRACE=$(objpfx)tst-fnmatch.mtrace
$(objpfx)tst-fnmatch-mem: $(objpfx)tst-fnmatch.out $(objpfx)tst-fnmatch-mem.out: $(objpfx)tst-fnmatch.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-fnmatch.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-fnmatch.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
bug-regex2-ENV = MALLOC_TRACE=$(objpfx)bug-regex2.mtrace bug-regex2-ENV = MALLOC_TRACE=$(objpfx)bug-regex2.mtrace
$(objpfx)bug-regex2-mem: $(objpfx)bug-regex2.out $(objpfx)bug-regex2-mem.out: $(objpfx)bug-regex2.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-regex2.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-regex2.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
bug-regex14-ENV = MALLOC_TRACE=$(objpfx)bug-regex14.mtrace bug-regex14-ENV = MALLOC_TRACE=$(objpfx)bug-regex14.mtrace
$(objpfx)bug-regex14-mem: $(objpfx)bug-regex14.out $(objpfx)bug-regex14-mem.out: $(objpfx)bug-regex14.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-regex14.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-regex14.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
bug-regex21-ENV = MALLOC_TRACE=$(objpfx)bug-regex21.mtrace bug-regex21-ENV = MALLOC_TRACE=$(objpfx)bug-regex21.mtrace
$(objpfx)bug-regex21-mem: $(objpfx)bug-regex21.out $(objpfx)bug-regex21-mem.out: $(objpfx)bug-regex21.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-regex21.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-regex21.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
bug-regex31-ENV = MALLOC_TRACE=$(objpfx)bug-regex31.mtrace bug-regex31-ENV = MALLOC_TRACE=$(objpfx)bug-regex31.mtrace
$(objpfx)bug-regex31-mem: $(objpfx)bug-regex31.out $(objpfx)bug-regex31-mem.out: $(objpfx)bug-regex31.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-regex31.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-regex31.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
tst-vfork3-ENV = MALLOC_TRACE=$(objpfx)tst-vfork3.mtrace tst-vfork3-ENV = MALLOC_TRACE=$(objpfx)tst-vfork3.mtrace
$(objpfx)tst-vfork3-mem: $(objpfx)tst-vfork3.out $(objpfx)tst-vfork3-mem.out: $(objpfx)tst-vfork3.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-vfork3.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-vfork3.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
@ -289,18 +290,18 @@ $(objpfx)tst-vfork3-mem: $(objpfx)tst-vfork3.out
# tst-rxspencer-no-utf8.mtrace, since otherwise the file has almost # tst-rxspencer-no-utf8.mtrace, since otherwise the file has almost
# 100M and takes very long time to process. # 100M and takes very long time to process.
tst-rxspencer-no-utf8-ENV += MALLOC_TRACE=$(objpfx)tst-rxspencer-no-utf8.mtrace tst-rxspencer-no-utf8-ENV += MALLOC_TRACE=$(objpfx)tst-rxspencer-no-utf8.mtrace
$(objpfx)tst-rxspencer-no-utf8-mem: $(objpfx)tst-rxspencer-no-utf8.out $(objpfx)tst-rxspencer-no-utf8-mem.out: $(objpfx)tst-rxspencer-no-utf8.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-rxspencer-no-utf8.mtrace \ $(common-objpfx)malloc/mtrace $(objpfx)tst-rxspencer-no-utf8.mtrace \
> $@; \ > $@; \
$(evaluate-test) $(evaluate-test)
tst-pcre-ENV = MALLOC_TRACE=$(objpfx)tst-pcre.mtrace tst-pcre-ENV = MALLOC_TRACE=$(objpfx)tst-pcre.mtrace
$(objpfx)tst-pcre-mem: $(objpfx)tst-pcre.out $(objpfx)tst-pcre-mem.out: $(objpfx)tst-pcre.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-pcre.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-pcre.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
tst-boost-ENV = MALLOC_TRACE=$(objpfx)tst-boost.mtrace tst-boost-ENV = MALLOC_TRACE=$(objpfx)tst-boost.mtrace
$(objpfx)tst-boost-mem: $(objpfx)tst-boost.out $(objpfx)tst-boost-mem.out: $(objpfx)tst-boost.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-boost.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-boost.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
@ -308,7 +309,7 @@ $(objpfx)tst-getconf.out: tst-getconf.sh $(objpfx)getconf
$(SHELL) $< $(common-objpfx) '$(built-program-cmd)'; \ $(SHELL) $< $(common-objpfx) '$(built-program-cmd)'; \
$(evaluate-test) $(evaluate-test)
$(objpfx)bug-ga2-mem: $(objpfx)bug-ga2.out $(objpfx)bug-ga2-mem.out: $(objpfx)bug-ga2.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-ga2.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-ga2.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
@ -316,7 +317,7 @@ bug-ga2-ENV = MALLOC_TRACE=$(objpfx)bug-ga2.mtrace
bug-glob2-ENV = MALLOC_TRACE=$(objpfx)bug-glob2.mtrace bug-glob2-ENV = MALLOC_TRACE=$(objpfx)bug-glob2.mtrace
$(objpfx)bug-glob2-mem: $(objpfx)bug-glob2.out $(objpfx)bug-glob2-mem.out: $(objpfx)bug-glob2.out
$(common-objpfx)malloc/mtrace $(objpfx)bug-glob2.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)bug-glob2.mtrace > $@; \
$(evaluate-test) $(evaluate-test)

View File

@ -33,7 +33,7 @@ routines := herror inet_addr inet_ntop inet_pton nsap_addr res_init \
tests = tst-aton tst-leaks tst-inet_ntop tests = tst-aton tst-leaks tst-inet_ntop
xtests = tst-leaks2 xtests = tst-leaks2
generate := mtrace-tst-leaks tst-leaks.mtrace tst-leaks2.mtrace generate := mtrace-tst-leaks.out tst-leaks.mtrace tst-leaks2.mtrace
extra-libs := libresolv libnss_dns extra-libs := libresolv libnss_dns
ifeq ($(have-thread-library),yes) ifeq ($(have-thread-library),yes)
@ -66,13 +66,13 @@ endif
ifeq ($(run-built-tests),yes) ifeq ($(run-built-tests),yes)
ifneq (no,$(PERL)) ifneq (no,$(PERL))
tests-special += $(objpfx)mtrace-tst-leaks tests-special += $(objpfx)mtrace-tst-leaks.out
xtests-special += $(objpfx)mtrace-tst-leaks2 xtests-special += $(objpfx)mtrace-tst-leaks2.out
endif endif
endif endif
generated += mtrace-tst-leaks tst-leaks.mtrace \ generated += mtrace-tst-leaks.out tst-leaks.mtrace \
mtrace-tst-leaks2 tst-leaks2.mtrace mtrace-tst-leaks2.out tst-leaks2.mtrace
include ../Rules include ../Rules
@ -100,11 +100,11 @@ $(objpfx)ga_test: $(objpfx)libanl.so $(shared-thread-library)
$(objpfx)tst-leaks: $(objpfx)libresolv.so $(objpfx)tst-leaks: $(objpfx)libresolv.so
tst-leaks-ENV = MALLOC_TRACE=$(objpfx)tst-leaks.mtrace tst-leaks-ENV = MALLOC_TRACE=$(objpfx)tst-leaks.mtrace
$(objpfx)mtrace-tst-leaks: $(objpfx)tst-leaks.out $(objpfx)mtrace-tst-leaks.out: $(objpfx)tst-leaks.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-leaks.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-leaks.mtrace > $@; \
$(evaluate-test) $(evaluate-test)
tst-leaks2-ENV = MALLOC_TRACE=$(objpfx)tst-leaks2.mtrace tst-leaks2-ENV = MALLOC_TRACE=$(objpfx)tst-leaks2.mtrace
$(objpfx)mtrace-tst-leaks2: $(objpfx)tst-leaks2.out $(objpfx)mtrace-tst-leaks2.out: $(objpfx)tst-leaks2.out
$(common-objpfx)malloc/mtrace $(objpfx)tst-leaks2.mtrace > $@; \ $(common-objpfx)malloc/mtrace $(objpfx)tst-leaks2.mtrace > $@; \
$(evaluate-test) $(evaluate-test)