summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2013-01-21 12:29:43 +0100
committerPatrick Simianer <p@simianer.de>2013-01-21 12:29:43 +0100
commit0d23f8aecbfaf982cd165ebfc2a1611cefcc7275 (patch)
tree8eafa6ea43224ff70635cadd4d6f027d28f4986f /utils
parentdbc66cd3944321961c5e11d5254fd914f05a98ad (diff)
parent7cac43b858f3b681555bf0578f54b1f822c43207 (diff)
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'utils')
-rw-r--r--utils/Makefile.am53
-rw-r--r--utils/weights_test.cc2
2 files changed, 53 insertions, 2 deletions
diff --git a/utils/Makefile.am b/utils/Makefile.am
index 639c30b8..c5fedb78 100644
--- a/utils/Makefile.am
+++ b/utils/Makefile.am
@@ -13,7 +13,57 @@ 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 \
+ b64tools.h \
+ batched_append.h \
+ city.h \
+ citycrc.h \
+ corpus_tools.h \
+ dict.h \
+ fast_sparse_vector.h \
+ fdict.h \
+ feature_vector.h \
+ filelib.h \
+ gzstream.h \
+ hash.h \
+ have_64_bits.h \
+ indices_after.h \
+ kernel_string_subseq.h \
+ logval.h \
+ m.h \
+ murmur_hash.h \
+ named_enum.h \
+ null_deleter.h \
+ null_traits.h \
+ perfect_hash.h \
+ prob.h \
+ sampler.h \
+ semiring.h \
+ show.h \
+ small_vector.h \
+ sparse_vector.h \
+ static_utoa.h \
+ stringlib.h \
+ swap_pod.h \
+ tdict.h \
+ timing_stats.h \
+ utoa.h \
+ value_array.h \
+ verbose.h \
+ warning_compiler.h \
+ warning_pop.h \
+ warning_push.h \
+ weights.h \
+ wordid.h \
+ writer.h \
+ fast_lexical_cast.hpp \
+ intrusive_refcount.hpp \
alignment_io.cc \
b64tools.cc \
corpus_tools.cc \
@@ -54,5 +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);
}