1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/intl/icu/source/test/Makefile.in Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,172 @@ 1.4 +## Makefile.in for ICU tests 1.5 +## Copyright (c) 1999-2013, International Business Machines Corporation and 1.6 +## others. All Rights Reserved. 1.7 + 1.8 +## Source directory information 1.9 +srcdir = @srcdir@ 1.10 +top_srcdir = @top_srcdir@ 1.11 + 1.12 +top_builddir = .. 1.13 + 1.14 +include $(top_builddir)/icudefs.mk 1.15 + 1.16 +## Build directory information 1.17 +subdir = test 1.18 + 1.19 +@ICUIO_TRUE@IOTEST = iotest 1.20 + 1.21 +# status dir 1.22 +STATUS_TMP = tmp 1.23 +STATUS_FULL = $(shell pwd)/$(STATUS_TMP) 1.24 + 1.25 +## Files to remove for 'make clean' 1.26 +CLEANFILES = *~ $(STATUS_TMP) 1.27 + 1.28 +SUBDIRS = testdata intltest $(IOTEST) cintltst 1.29 + 1.30 +## List of phony targets 1.31 +.PHONY : everything all all-local all-recursive install install-local \ 1.32 +install-recursive clean clean-local clean-recursive distclean \ 1.33 +distclean-local distclean-recursive dist dist-recursive dist-local \ 1.34 +check check-recursive check-local xcheck xcheck-recursive xcheck-local \ 1.35 +check-exhaustive check-exhaustive-recursive 1.36 + 1.37 +## Clear suffix list 1.38 +.SUFFIXES : 1.39 + 1.40 +## List of standard targets 1.41 +everything: all-recursive all-local 1.42 +all: 1.43 +ifneq ($(RECURSIVE),YES) 1.44 + @echo simply use \`make\' \(or \`make everything\'\) to do all 1.45 +endif 1.46 + 1.47 +install: install-recursive install-local 1.48 +clean: clean-recursive clean-local 1.49 +distclean : distclean-recursive distclean-local 1.50 + $(RMV) hdrtst/Makefile 1.51 + $(RMV) perf/convperf/Makefile 1.52 + $(RMV) $(STATUS_TMP) 1.53 + 1.54 +dist: dist-recursive dist-local 1.55 +check: everything check-recursive check-local 1.56 +check-recursive: all-recursive 1.57 +# the xcheck targets create a ../test-*.xml file in JUnit format. 1.58 +xcheck: everything xcheck-recursive xcheck-local 1.59 +xcheck-recursive: all-recursive 1.60 +check-exhaustive: everything check-exhaustive-recursive check-local 1.61 + 1.62 +## Recursive targets 1.63 +all-recursive install-recursive clean-recursive distclean-recursive dist-recursive: 1.64 + @dot_seen=no; \ 1.65 + target=`echo $@ | sed s/-recursive//`; \ 1.66 + list='$(SUBDIRS)'; for subdir in $$list; do \ 1.67 + echo "$(MAKE)[$(MAKELEVEL)]: Making \`$$target' in \`$$subdir'"; \ 1.68 + if test "$$subdir" = "."; then \ 1.69 + dot_seen=yes; \ 1.70 + local_target="$$target-local"; \ 1.71 + else \ 1.72 + local_target="$$target"; \ 1.73 + fi; \ 1.74 + (cd $$subdir && $(MAKE) $$local_target) || exit; \ 1.75 + done; \ 1.76 + if test "$$dot_seen" = "no"; then \ 1.77 + $(MAKE) "$$target-local" || exit; \ 1.78 + fi 1.79 + 1.80 +xcheck-recursive check-recursive check-exhaustive-recursive: 1.81 + @$(MKINSTALLDIRS) $(STATUS_TMP) 1.82 + @mystatus=$(STATUS_FULL)/status.$$$$.deleteme ; \ 1.83 + $(RMV) "$$mystatus".* ; \ 1.84 + @goods=; \ 1.85 + bads=; \ 1.86 + target=`echo $@ | sed s/-recursive//`; \ 1.87 + list='$(SUBDIRS)'; for subdir in $$list; do \ 1.88 + echo "$(MAKE)[$(MAKELEVEL)]: Making \`$$target' in \`$$subdir'"; \ 1.89 + local_target="$$target"; \ 1.90 + if (cd $$subdir && $(MAKE) $$local_target TEST_STATUS_FILE="$$mystatus.$$subdir" ); then \ 1.91 + goods="$$goods $$subdir"; \ 1.92 + else \ 1.93 + bads="$$bads $$subdir"; \ 1.94 + fi; \ 1.95 + done; \ 1.96 + for subdir in $$list; do \ 1.97 + if [ -f "$$mystatus.$$subdir" ]; then \ 1.98 + echo "-------------" ; \ 1.99 + echo "| *** FAILING TEST SUMMARY FOR: $$subdir " ; \ 1.100 + cat "$$mystatus.$$subdir" ; \ 1.101 + echo "| *** END FAILING TEST SUMMARY FOR: $$subdir" ; \ 1.102 + $(RMV) "$$mystatus.$$subdir" ; \ 1.103 + fi; \ 1.104 + done; \ 1.105 + echo "---------------"; \ 1.106 + echo "ALL TESTS SUMMARY:"; \ 1.107 + if test ! "x$$bads" = "x"; then \ 1.108 + echo "ok: $$goods"; \ 1.109 + echo "===== ERRS: $$bads"; exit 1; \ 1.110 + else \ 1.111 + echo "All tests OK: $$goods"; \ 1.112 + fi 1.113 + 1.114 +# pcheck = parallel check. We don't care about the output interleaving, 1.115 +# just run it as fast as possible. 1.116 +# todo would be to merge this code into the above non-parallel check. 1.117 +STATUS_NUM:=$(shell echo $$$$) 1.118 +MYSTATUS_R=$(STATUS_FULL)/status.$(STATUS_NUM).deleteme 1.119 +STATUS_FILES=$(SUBDIRS:%=$(MYSTATUS_R).%) 1.120 + 1.121 +pcheck_setup: testdata 1.122 + @$(MKINSTALLDIRS) $(STATUS_TMP) 1.123 + $(RMV) "$(MYSTATUS_R)".* 1.124 + @echo Beginning parallel make. Output may be interleaved! 1.125 + 1.126 +$(STATUS_FULL)/status.$(STATUS_NUM).deleteme.%: pcheck_setup 1.127 + @$(MAKE) -C $* TEST_STATUS_FILE=$@ check || ( echo "FAILED: $* (other tests may still be running..)" ; touch $@.FAIL ; false ) 1.128 + -@touch $@.PASS 1.129 + -@echo "PASSED: $* (other tests may still be running..)" 1.130 + 1.131 +# print out status 1.132 +pcheck: $(STATUS_FILES) 1.133 + @goods= ; \ 1.134 + bads= ; \ 1.135 + echo "---------------"; \ 1.136 + for subdir in $(SUBDIRS); do \ 1.137 + if [ -f "$(MYSTATUS_R).$$subdir.FAIL" ]; \ 1.138 + then \ 1.139 + bads="$$bads $$subdir" ; \ 1.140 + elif [ -f "$(MYSTATUS_R).$$subdir.PASS" ]; \ 1.141 + then \ 1.142 + goods="$$goods $$subdir" ; \ 1.143 + else \ 1.144 + echo "*** subtest did not complete - $$subdir" ; \ 1.145 + bads="$$bads $$subdir" ; \ 1.146 + fi ; \ 1.147 + done ; \ 1.148 + echo "ALL TESTS SUMMARY:"; \ 1.149 + if test ! "x$$bads" = "x"; then \ 1.150 + echo "(to get non-interleaved err output, use \"$(MAKE) check\" instead.)" ; \ 1.151 + echo "ok: $$goods"; \ 1.152 + echo "===== ERRS: $$bads"; exit 1; \ 1.153 + else \ 1.154 + echo "All tests OK: $$goods"; \ 1.155 + fi 1.156 + -@$(RMV) "$(MYSTATUS_R)".* 1.157 + 1.158 +all-local: 1.159 + 1.160 +install-local: 1.161 + 1.162 +dist-local: 1.163 + 1.164 +clean-local: 1.165 + test -z "$(CLEANFILES)" || $(RMV) $(CLEANFILES) 1.166 + 1.167 +distclean-local: clean-local 1.168 + $(RMV) Makefile 1.169 + 1.170 +xcheck-local check-local: all-local 1.171 + 1.172 +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status 1.173 + cd $(top_builddir) \ 1.174 + && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status 1.175 +