1 | ## $Id: Makefile.am 2986 2013-02-18 08:07:44Z peter $ |
---|
2 | |
---|
3 | # Copyright (C) 2003 Daniel Dalevi, Jari Häkkinen |
---|
4 | # Copyright (C) 2004 Jari Häkkinen, Peter Johansson, Cecilia Ritz |
---|
5 | # Copyright (C) 2005 Jari Häkkinen, Peter Johansson |
---|
6 | # Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson, Markus Ringnér |
---|
7 | # Copyright (C) 2009, 2010, 2011, 2012, 2013 Peter Johansson |
---|
8 | # |
---|
9 | # This file is part of the yat library, http://dev.thep.lu.se/yat |
---|
10 | # |
---|
11 | # The yat library is free software; you can redistribute it |
---|
12 | # and/or modify it under the terms of the GNU General Public License as |
---|
13 | # published by the Free Software Foundation; either version 3 of the |
---|
14 | # License, or (at your option) any later version. |
---|
15 | # |
---|
16 | # The yat library is distributed in the hope that it will be useful, |
---|
17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
19 | # General Public License for more details. |
---|
20 | # |
---|
21 | # You should have received a copy of the GNU General Public License |
---|
22 | # along with yat. If not, see <http://www.gnu.org/licenses/>. |
---|
23 | |
---|
24 | ## we use suffix .cc for all source |
---|
25 | AM_DEFAULT_SOURCE_EXT = .cc |
---|
26 | |
---|
27 | noinst_HEADERS = test/Suite.h |
---|
28 | |
---|
29 | check_LTLIBRARIES = test/libyattest.la |
---|
30 | |
---|
31 | check_SCRIPTS = test/common_defs.sh |
---|
32 | |
---|
33 | EXTRA_PROGRAMS = test/alignment.test \ |
---|
34 | test/alignment2.test \ |
---|
35 | test/averager.test \ |
---|
36 | test/averager1.test \ |
---|
37 | test/averager3.test \ |
---|
38 | test/averager4.test \ |
---|
39 | test/bam.test \ |
---|
40 | test/bam_pair_analyse.test \ |
---|
41 | test/bam_iterator.test \ |
---|
42 | test/bam_region_iterator.test \ |
---|
43 | test/bam_header.test \ |
---|
44 | test/codon.test test/commandline.test \ |
---|
45 | test/concept.test \ |
---|
46 | test/consensus_inputranker.test test/data_lookup_1d.test \ |
---|
47 | test/data_weight.test test/data_weight_proxy.test \ |
---|
48 | test/deleter.test \ |
---|
49 | test/distance.test \ |
---|
50 | test/dna.test test/ensemble.test test/feature_selection.test \ |
---|
51 | test/fileutil.test \ |
---|
52 | test/fisher.test test/genomic_position.test test/getline_iterator.test \ |
---|
53 | test/gff.test test/help.test test/histogram.test \ |
---|
54 | test/igp.test test/index.test test/inputranker.test test/interpolation.test \ |
---|
55 | test/iterator.test test/kendall.test test/kernel_lookup.test \ |
---|
56 | test/kernel_pca.test test/kernel.test \ |
---|
57 | test/knn.test test/kolmogorov_smirnov.test test/large_file.test \ |
---|
58 | test/matrix_lookup.test \ |
---|
59 | test/matrix_lookup_weighted.test test/matrix.test \ |
---|
60 | test/matrix_weighted.test test/merge.test test/nbc.test \ |
---|
61 | test/ncc.test test/nni.test test/normalization.test test/pca.test \ |
---|
62 | test/range.test test/regression.test test/rnd.test \ |
---|
63 | test/rng-mt.test \ |
---|
64 | test/roc.test \ |
---|
65 | test/score.test test/segment.test test/smart_ptr.test \ |
---|
66 | test/smoother.test test/spearman.test \ |
---|
67 | test/split.test test/statistics.test test/stream_redirect.test \ |
---|
68 | test/subset_generator.test test/svd.test test/svm.test \ |
---|
69 | test/svm_multi_class.test test/target.test \ |
---|
70 | test/ttest.test test/tukey.test \ |
---|
71 | test/utility.test test/vector.test test/version.test test/view.test |
---|
72 | |
---|
73 | TESTS = $(EXTRA_PROGRAMS) |
---|
74 | CLEANFILES += $(EXTRA_PROGRAMS) |
---|
75 | |
---|
76 | # tests not passing through yet |
---|
77 | XFAIL_TESTS = |
---|
78 | |
---|
79 | DISTRIBUTED_TESTS = \ |
---|
80 | test/cmd_test.sh \ |
---|
81 | test/doxygen_test.sh \ |
---|
82 | test/help_test.sh \ |
---|
83 | test/static_test.sh \ |
---|
84 | test/yat_config_test.sh \ |
---|
85 | test/yat_config_cblas_test.sh \ |
---|
86 | test/yat_cpp_add_flag_test.sh \ |
---|
87 | test/yat_cxx_add_flag_test.sh \ |
---|
88 | test/yat_ld_add_flag_test.sh \ |
---|
89 | test/yat_have_svn_wc_test.sh \ |
---|
90 | test/yat_lt_link_ifelse_test.sh \ |
---|
91 | test/yat_msg_error_test.sh \ |
---|
92 | test/yat_msg_error_test2.sh \ |
---|
93 | test/yat_m4_test.sh \ |
---|
94 | test/yat_m4_test2.sh \ |
---|
95 | test/yat_pc_test.sh \ |
---|
96 | test/yat_prog_move_if_change_test.sh \ |
---|
97 | test/yat_revision_header_test.sh \ |
---|
98 | test/yat_svn_release_year_test.sh \ |
---|
99 | test/yat_svn_revision_test.sh |
---|
100 | |
---|
101 | TESTS += $(DISTRIBUTED_TESTS) |
---|
102 | EXTRA_DIST += $(DISTRIBUTED_TESTS) |
---|
103 | |
---|
104 | TEST_EXTENSIONS = .sh .test |
---|
105 | |
---|
106 | LDADD = yat/libyat.la test/libyattest.la $(YAT_LIBS) |
---|
107 | |
---|
108 | #test_large_file_test_LDADD = test/libyattest.la |
---|
109 | |
---|
110 | test_libyattest_la_LIBADD = yat/libyat.la |
---|
111 | test_libyattest_la_SOURCES = test/Suite.cc |
---|
112 | |
---|
113 | lazycheck:; $(MAKE) $(AM_MAKEFLAGS) check RECHECK_LOGS= |
---|
114 | |
---|
115 | # dependencies for lazycheck |
---|
116 | test/cmd_test.log: test/help.test test/common_defs.sh |
---|
117 | test/help_test.log: test/help.test test/common_defs.sh |
---|
118 | test/static_test.log: $(srcdir)/m4/yat.m4 test/common_defs.sh |
---|
119 | test/yat_config_test.log: build_support/yat-config \ |
---|
120 | build_support/for_installation/yat-config test/common_defs.sh |
---|
121 | test/yat_config_cblas_test.log: build_support/yat-config test/common_defs.sh |
---|
122 | test/yat_cpp_add_flag_test.log: $(srcdir)/m4/yat_add_flag.m4 \ |
---|
123 | $(srcdir)/m4/ax_append_flag.m4 \ |
---|
124 | $(srcdir)/m4/ax_check_preproc_flag.m4 \ |
---|
125 | test/common_defs.sh |
---|
126 | test/yat_cxx_add_flag_test.log: $(top_srcdir)/m4/yat_add_flag.m4 \ |
---|
127 | $(top_srcdir)/m4/ax_append_compile_flags.m4 \ |
---|
128 | $(top_srcdir)/m4/ax_append_flag.m4 \ |
---|
129 | $(top_srcdir)/m4/ax_check_compile_flag.m4 \ |
---|
130 | test/common_defs.sh |
---|
131 | test/yat_have_svn_wc_test.log: $(srcdir)/m4/yat_am_macros.m4 test/common_defs.sh |
---|
132 | test/yat_ld_add_flag_test.log: $(top_srcdir)/m4/yat_add_flag.m4 \ |
---|
133 | $(top_srcdir)/m4/ax_append_flag.m4 \ |
---|
134 | $(top_srcdir)/m4/ax_append_link_flags.m4 \ |
---|
135 | $(top_srcdir)/m4/ax_check_link_flag.m4 \ |
---|
136 | test/common_defs.sh |
---|
137 | test/yat_lt_link_ifelse_test.log: $(top_srcdir)/m4/yat_lt_link_ifelse.m4 \ |
---|
138 | $(top_srcdir)/m4/yat.m4 test/common_defs.sh \ |
---|
139 | $(top_builddir)/build_support/yat-config |
---|
140 | test/yat_m4_test.log:$(top_srcdir)/m4/yat.m4 test/common_defs.sh \ |
---|
141 | $(top_builddir)/build_support/yat-config |
---|
142 | test/yat_m4_test2.log:$(top_srcdir)/m4/yat.m4 test/common_defs.sh |
---|
143 | test/yat_msg_error_test.log:$(srcdir)/m4/yat_msg_error.m4 test/common_defs.sh |
---|
144 | test/yat_msg_error_test2.log:$(srcdir)/m4/yat_msg_error.m4 test/common_defs.sh |
---|
145 | test/yat_pc_test.log: test/common_defs.sh build_support/yat.pc |
---|
146 | test/yat_prog_move_if_change_test.log: $(top_srcdir)/m4/yat_am_macros.m4 \ |
---|
147 | $(top_srcdir)/m4/ax_ac_append_to_file.m4 \ |
---|
148 | $(top_srcdir)/m4/ax_ac_print_to_file.m4 \ |
---|
149 | $(top_srcdir)/m4/ax_file_escapes.m4 \ |
---|
150 | test/common_defs.sh |
---|
151 | test/yat_revision_header_test.log: $(top_srcdir)/m4/yat_am_macros.m4 \ |
---|
152 | test/common_defs.sh \ |
---|
153 | $(top_srcdir)/m4/ax_ac_append_to_file.m4 \ |
---|
154 | $(top_srcdir)/m4/ax_ac_print_to_file.m4 \ |
---|
155 | $(top_srcdir)/m4/ax_file_escapes.m4 |
---|
156 | test/yat_svn_release_year_test.log: $(top_srcdir)/m4/yat_am_macros.m4 \ |
---|
157 | test/common_defs.sh \ |
---|
158 | $(top_srcdir)/m4/ax_ac_append_to_file.m4 \ |
---|
159 | $(top_srcdir)/m4/ax_ac_print_to_file.m4 \ |
---|
160 | $(top_srcdir)/m4/ax_file_escapes.m4 |
---|
161 | test/yat_svn_revision_test.log: $(top_srcdir)/m4/yat_am_macros.m4 \ |
---|
162 | test/common_defs.sh \ |
---|
163 | $(top_srcdir)/m4/ax_ac_append_to_file.m4 \ |
---|
164 | $(top_srcdir)/m4/ax_ac_print_to_file.m4 \ |
---|
165 | $(top_srcdir)/m4/ax_file_escapes.m4 |
---|
166 | |
---|
167 | if DX_ENABLE_HTML |
---|
168 | test/doxygen_test.log: doc/$(DX_HTML_OUTPUT)/index.html |
---|
169 | endif |
---|
170 | |
---|
171 | # yat-hello is an example of a tiny package that uses yat |
---|
172 | dist_noinst_DATA = $(srcdir)/test/yat-hello-1.0.tar.gz |
---|
173 | |
---|
174 | # Directory yat-hello contains what a developer would check out |
---|
175 | # from a VCS, i.e., no files generated by autotools. |
---|
176 | yat_hello_sources = |
---|
177 | yat_hello_sources += $(srcdir)/test/yat-hello/configure.ac |
---|
178 | yat_hello_sources += $(srcdir)/test/yat-hello/Makefile.am |
---|
179 | yat_hello_sources += $(srcdir)/test/yat-hello/hello.cc |
---|
180 | |
---|
181 | EXTRA_DIST += $(yat_hello_sources) |
---|
182 | |
---|
183 | yat_hello_tmp_files = |
---|
184 | yat_hello_tmp_files += Makefile.in |
---|
185 | yat_hello_tmp_files += autom4te.cache |
---|
186 | yat_hello_tmp_files += aclocal.m4 |
---|
187 | yat_hello_tmp_files += build-aux |
---|
188 | yat_hello_tmp_files += configure |
---|
189 | yat_hello_tmp_files += m4 |
---|
190 | |
---|
191 | |
---|
192 | yat_hello_deps = $(yat_hello_sources) |
---|
193 | yat_hello_deps += $(top_srcdir)/m4/yat.m4 |
---|
194 | ## We depend on version.m4 so tarball is updated at every release (at least) |
---|
195 | yat_hello_deps += $(top_srcdir)/m4/version.m4 |
---|
196 | |
---|
197 | $(srcdir)/test/yat-hello-1.0.tar.gz: $(yat_hello_deps) |
---|
198 | $(AM_V_GEN)cd $(srcdir)/test/yat-hello \ |
---|
199 | && $(MKDIR_P) m4 \ |
---|
200 | && cp $(abs_top_srcdir)/m4/yat.m4 m4/ \ |
---|
201 | && autoreconf -if $(yat_dev_null) \ |
---|
202 | && ./configure --without-yat $(yat_dev_null) \ |
---|
203 | && $(MAKE) $(AM_MAKEFLAGS) dist $(yat_dev_null) \ |
---|
204 | && $(MAKE) $(AM_MAKEFLAGS) distclean $(yat_dev_null) \ |
---|
205 | && mv yat-hello-1.0.tar.gz .. \ |
---|
206 | && rm -rf $(yat_hello_tmp_files) |
---|
207 | |
---|
208 | INSTALL_CHECK_TARGETS += yat-hello-check |
---|
209 | |
---|
210 | yat-hello-check: $(srcdir)/test/yat-hello-1.0.tar.gz |
---|
211 | GZIP=$(GZIP_ENV) gzip -dc $(srcdir)/test/yat-hello-1.0.tar.gz | $(am__untar)\ |
---|
212 | && cd yat-hello-1.0 \ |
---|
213 | && ./configure --with-yat=$(bindir) \ |
---|
214 | && $(MAKE) $(AM_MAKEFLAGS) all \ |
---|
215 | && ./hello \ |
---|
216 | && cd .. \ |
---|
217 | && rm -rf yat-hello-1.0 |
---|
218 | |
---|
219 | |
---|
220 | ## test data |
---|
221 | EXTRA_DIST += \ |
---|
222 | test/data/foo.sam \ |
---|
223 | test/data/isoform.peaks \ |
---|
224 | test/data/knni_matrix.data \ |
---|
225 | test/data/knni_result.data \ |
---|
226 | test/data/knni_weight.data \ |
---|
227 | test/data/nm_alpha_linear_matlab.txt \ |
---|
228 | test/data/nm_data_centralized.txt \ |
---|
229 | test/data/nm_kernel.txt \ |
---|
230 | test/data/nm_kernel2.txt \ |
---|
231 | test/data/nm_kernel_gaussian.txt \ |
---|
232 | test/data/nm_target_bin.txt \ |
---|
233 | test/data/normalization_test.data \ |
---|
234 | test/data/rank_data.txt \ |
---|
235 | test/data/rank_target.txt \ |
---|
236 | test/data/regression_gauss.data \ |
---|
237 | test/data/small.gff2 \ |
---|
238 | test/data/small.gff3 \ |
---|
239 | test/data/sorlie_centroid_classes.txt \ |
---|
240 | test/data/sorlie_centroid_data.txt \ |
---|
241 | test/data/sorlie_centroid_predictions.txt \ |
---|
242 | test/data/sorlie_centroids.txt \ |
---|
243 | test/data/vector1.data \ |
---|
244 | test/data/vector2.data \ |
---|
245 | test/data/vector3.data \ |
---|
246 | test/data/vector4.data \ |
---|
247 | test/data/vector5.data \ |
---|
248 | test/data/vector6.data \ |
---|
249 | test/data/vector7.data \ |
---|
250 | test/data/wenni_result.data \ |
---|
251 | test/data/wenni_weight.data |
---|
252 | |
---|
253 | CLEANFILES += test/data/.dirstamp |
---|
254 | CLEANFILES += test/data/foo.bam |
---|
255 | CLEANFILES += test/data/foo.sorted.bam |
---|
256 | CLEANFILES += test/data/foo.sorted.bam.bai |
---|
257 | |
---|
258 | check_DATA = test/data/foo.sorted.bam |
---|
259 | check_DATA += test/data/foo.sorted.bam.bai |
---|
260 | |
---|
261 | test/data/.dirstamp: |
---|
262 | @$(MKDIR_P) test/data |
---|
263 | @: > $@ |
---|
264 | |
---|
265 | if HAVE_SAMTOOLS |
---|
266 | test/data/foo.bam: test/data/foo.sam test/data/.dirstamp Makefile |
---|
267 | $(SAMTOOLS) view -Sb $(srcdir)/test/data/foo.sam > $@-t && mv $@-t $@ |
---|
268 | |
---|
269 | test/data/foo.sorted.bam: test/data/foo.bam |
---|
270 | $(SAMTOOLS) sort test/data/foo.bam test/data/foo.sorted |
---|
271 | |
---|
272 | test/data/foo.sorted.bam.bai: test/data/foo.sorted.bam |
---|
273 | $(SAMTOOLS) index test/data/foo.sorted.bam |
---|
274 | else |
---|
275 | test/data/foo.sorted.bam: test/data/.dirstamp |
---|
276 | : > $@ |
---|
277 | |
---|
278 | test/data/foo.sorted.bam.bai: test/data/.dirstamp |
---|
279 | : > $@ |
---|
280 | endif |
---|