diff mbox

[1/5] validation: own main in odp_time.c

Message ID 1434988980-14008-2-git-send-email-christophe.milard@linaro.org
State Superseded
Headers show

Commit Message

Christophe Milard June 22, 2015, 4:02 p.m. UTC
Signed-off-by: Christophe Milard <christophe.milard@linaro.org>
---
 test/validation/Makefile.am |  2 ++
 test/validation/odp_time.c  | 13 ++++++++++++-
 2 files changed, 14 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am
index a0277e7..3d8f712 100644
--- a/test/validation/Makefile.am
+++ b/test/validation/Makefile.am
@@ -45,6 +45,8 @@  dist_odp_random_SOURCES = odp_random.c
 dist_odp_scheduler_SOURCES = odp_scheduler.c
 dist_odp_shared_memory_SOURCES	= odp_shared_memory.c
 dist_odp_synchronizers_SOURCES = odp_synchronizers.c
+odp_time_LDADD = $(top_builddir)/test/validation/common/libcunit_common.a \
+		 $(LIB)/libodp.la
 dist_odp_time_SOURCES   = odp_time.c
 dist_odp_timer_SOURCES  = odp_timer.c
 dist_odp_packet_SOURCES = odp_packet.c
diff --git a/test/validation/odp_time.c b/test/validation/odp_time.c
index 8db9894..38d940e 100644
--- a/test/validation/odp_time.c
+++ b/test/validation/odp_time.c
@@ -65,7 +65,18 @@  CU_TestInfo test_odp_time[] = {
 	 CU_TEST_INFO_NULL
 };
 
-CU_SuiteInfo odp_testsuites[] = {
+static CU_SuiteInfo system_suites[] = {
 		{"Time", NULL, NULL, NULL, NULL, test_odp_time},
 		 CU_SUITE_INFO_NULL
 };
+
+static int system_main(void)
+{
+	return odp_cunit_run(system_suites);
+}
+
+/* the following main function will be separated when lib is created */
+int main(void)
+{
+	return system_main();
+}