From: Adam Simpkins Date: Thu, 15 Jun 2017 18:28:06 +0000 (-0700) Subject: fix issues with the open source tests X-Git-Tag: v2017.06.19.00~13 X-Git-Url: http://plrg.eecs.uci.edu/git/?p=folly.git;a=commitdiff_plain;h=5dd16dc0be87d7c124416a77a43b5e975825f584 fix issues with the open source tests Summary: Fix build problems in the open source Makefiles that cause issues when running `make check` - The test subdirectory needs to be processed before experimental, since some tests in experimental/ depend on libfollytestmain from test/ - The stats/test Makefile had an incorrectly copy-and-pasted line for libgtest_la_SOURCES but didn't actually build a libgtest.la library. - The test/ Makefile defined thread_id_test but forgot to add it to TESTS so that it would actually be run as part of "make check" Reviewed By: Orvid Differential Revision: D5249132 fbshipit-source-id: 5a71e1f72a39d5407b843a5876891c67238ec006 --- diff --git a/folly/Makefile.am b/folly/Makefile.am index 558a4859..b2bad52a 100644 --- a/folly/Makefile.am +++ b/folly/Makefile.am @@ -2,7 +2,10 @@ if FOLLY_TESTMAIN MAYBE_INIT = init endif -SUBDIRS = . experimental $(MAYBE_INIT) test io/test stats/test +# Note that the order of SUBDIRS matters. +# Many subdirectories depend on libfollytest from the test directory, +# so it must appear before other directories +SUBDIRS = . test experimental $(MAYBE_INIT) io/test stats/test ACLOCAL_AMFLAGS = -I m4 diff --git a/folly/stats/test/Makefile.am b/folly/stats/test/Makefile.am index 0957edc1..f6f47150 100755 --- a/folly/stats/test/Makefile.am +++ b/folly/stats/test/Makefile.am @@ -3,8 +3,6 @@ ACLOCAL_AMFLAGS = -I m4 CPPFLAGS = -I$(top_srcdir)/test/gtest/googletest/include ldadd = $(top_builddir)/test/libfollytestmain.la -libgtest_la_SOURCES = gtest/googletest/src/gtest-all.cc - check_PROGRAMS = \ histogram_test diff --git a/folly/test/Makefile.am b/folly/test/Makefile.am index 7494920d..539b6000 100644 --- a/folly/test/Makefile.am +++ b/folly/test/Makefile.am @@ -98,6 +98,7 @@ thread_cached_int_test_LDADD = libfollytestmain.la $(top_builddir)/libfollybench thread_id_test_SOURCES = ThreadIdTest.cpp thread_id_test_LDADD = libfollytestmain.la +TESTS += thread_id_test thread_local_test_SOURCES = ThreadLocalTest.cpp thread_local_test_LDADD = libfollytestmain.la $(top_builddir)/libfollybenchmark.la