summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
Diffstat (limited to 'utils')
-rw-r--r--utils/Makefile.am5
-rw-r--r--utils/weights_test.cc2
2 files changed, 5 insertions, 2 deletions
diff --git a/utils/Makefile.am b/utils/Makefile.am
index 3177325b..c5fedb78 100644
--- a/utils/Makefile.am
+++ b/utils/Makefile.am
@@ -13,7 +13,10 @@ TESTS = ts small_vector_test logval_test weights_test dict_test m_test
noinst_LIBRARIES = libutils.a
+# EXTRA_DIST = test_data
+
libutils_a_SOURCES = \
+ test_data \
alias_sampler.h \
alignment_io.h \
array2d.h \
@@ -101,6 +104,6 @@ small_vector_test_LDADD = libutils.a $(BOOST_UNIT_TEST_FRAMEWORK_LDFLAGS) $(BOOS
################################################################
# do NOT NOT NOT add any other -I includes NO NO NO NO NO ######
-AM_CPPFLAGS = -DBOOST_TEST_DYN_LINK -W -Wall -I.
+AM_CPPFLAGS = -DBOOST_TEST_DYN_LINK -W -Wall -I. -I$(top_srcdir) -DTEST_DATA=\"$(top_srcdir)/utils/test_data\"
################################################################
diff --git a/utils/weights_test.cc b/utils/weights_test.cc
index 4be4c40f..0d5d8512 100644
--- a/utils/weights_test.cc
+++ b/utils/weights_test.cc
@@ -7,6 +7,6 @@ using namespace std;
BOOST_AUTO_TEST_CASE(Load) {
vector<weight_t> v;
- Weights::InitFromFile("test_data/weights", &v);
+ Weights::InitFromFile(TEST_DATA "/weights", &v);
Weights::WriteToFile("-", v);
}