@@ -31,6 +31,8 @@ dist_odp_scheduler_SOURCES = odp_scheduler.c
dist_odp_shared_memory_SOURCES = odp_shared_memory.c
dist_odp_synchronizers_SOURCES = odp_synchronizers.c
dist_odp_timer_SOURCES = odp_timer.c
+odp_packet_LDADD = $(top_builddir)/test/validation/common/libcunit_common.a \
+ $(LIB)/libodp.la
dist_odp_packet_SOURCES = odp_packet.c
dist_odp_cpumask_SOURCES = odp_cpumask.c
dist_odp_thread_SOURCES = odp_thread.c
@@ -700,7 +700,7 @@ static void packet_offset(void)
CU_ASSERT(ptr != NULL);
}
-CU_TestInfo packet_tests[] = {
+static CU_TestInfo packet_tests[] = {
_CU_TEST_INFO(packet_alloc_free),
_CU_TEST_INFO(packet_alloc_segmented),
_CU_TEST_INFO(packet_basic_metadata),
@@ -722,7 +722,7 @@ CU_TestInfo packet_tests[] = {
CU_TEST_INFO_NULL,
};
-CU_SuiteInfo odp_testsuites[] = {
+static CU_SuiteInfo packet_suites[] = {
{ .pName = "packet tests",
.pTests = packet_tests,
.pInitFunc = packet_testsuite_init,
@@ -730,3 +730,14 @@ CU_SuiteInfo odp_testsuites[] = {
},
CU_SUITE_INFO_NULL,
};
+
+static int packet_main(void)
+{
+ return odp_cunit_run(packet_suites);
+}
+
+/* the following main function will be separated when lib is created */
+int main(void)
+{
+ return packet_main();
+}
Signed-off-by: Christophe Milard <christophe.milard@linaro.org> --- test/validation/Makefile.am | 2 ++ test/validation/odp_packet.c | 15 +++++++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-)