blob: 6d249e27c4ef86d366389f61c0339f655180c723 [file] [log] [blame]
Deepak Kodihalli707a3e12017-06-14 03:56:12 -05001AM_CPPFLAGS = -I${top_srcdir}
Andrew Geissler328889d2016-10-10 12:43:48 -05002
Andrew Geissler328889d2016-10-10 12:43:48 -05003TESTS = $(check_PROGRAMS)
4
Deepak Kodihalli707a3e12017-06-14 03:56:12 -05005check_PROGRAMS = \
Nagaraju Goruganti477b7312018-06-25 23:28:58 -05006 elog_errorwrap_test \
Deepak Kodihalli707a3e12017-06-14 03:56:12 -05007 serialization_test_path \
Deepak Kodihalli834dcf12018-08-30 05:05:46 -05008 serialization_test_properties \
9 remote_logging_test_address \
Deepak Kodihalli5ac1bde2018-08-30 05:38:44 -050010 remote_logging_test_port \
Patrick Venture31552c02018-12-03 19:09:55 -080011 remote_logging_test_config \
Matt Spinler99c2b402019-05-23 14:29:16 -050012 sdjournal_mock_test \
Matt Spinler1e71a4d2020-03-04 13:40:22 -060013 extensions_test \
Andrew Geisslere4960ee2020-03-30 14:31:52 -050014 elog_update_ts_test \
15 elog_quiesce_test
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050016
17test_cppflags = \
18 -Igtest \
19 $(GTEST_CPPFLAGS) \
20 $(AM_CPPFLAGS) \
21 $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \
Patrick Williams81a91e32020-05-28 14:39:28 -050022 $(SDBUSPLUS_CFLAGS) \
23 $(SYSTEMD_CFLAGS)
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050024
25test_cxxflags = \
26 $(PTHREAD_CFLAGS)
27
28test_ldflags = \
29 -lgtest_main -lgtest \
Matt Spinler1787c522019-07-09 12:58:37 -050030 -lgmock -lstdc++fs \
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050031 $(PTHREAD_LIBS) \
32 $(OESDK_TESTCASE_FLAGS) \
33 $(PHOSPHOR_DBUS_INTERFACES_LIBS) \
Patrick Williams81a91e32020-05-28 14:39:28 -050034 $(SDBUSPLUS_LIBS) \
35 $(SYSTEMD_LIBS)
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050036
37test_ldadd = \
38 $(top_builddir)/elog_serialize.o \
39 $(top_builddir)/elog_entry.o \
40 $(top_builddir)/log_manager.o \
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050041 $(top_builddir)/xyz/openbmc_project/Logging/Internal/Manager/server.o \
42 $(top_builddir)/elog_meta.o \
43 $(top_builddir)/elog-lookup.o \
Patrick Venture59a6b1f2018-08-29 11:41:01 -070044 $(top_builddir)/elog-process-metadata.o \
Matt Spinler99c2b402019-05-23 14:29:16 -050045 $(top_builddir)/sdjournal.o \
46 $(top_builddir)/extensions.o
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050047
Patrick Venture59a6b1f2018-08-29 11:41:01 -070048remote_logging_test_ldadd = \
49 $(top_builddir)/phosphor-rsyslog-config/server-conf.o \
50 $(top_builddir)/sdjournal.o
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050051
Nagaraju Goruganti477b7312018-06-25 23:28:58 -050052elog_errorwrap_test_CPPFLAGS = $(test_cppflags)
53elog_errorwrap_test_CXXFLAGS = $(test_cxxflags)
54elog_errorwrap_test_SOURCES = elog_errorwrap_test.cpp
55elog_errorwrap_test_LDADD = $(test_ldadd)
56elog_errorwrap_test_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050057 $(test_ldflags)
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050058
59serialization_test_path_CPPFLAGS = $(test_cppflags)
60serialization_test_path_CXXFLAGS = $(test_cxxflags)
61serialization_test_path_SOURCES = serialization_test_path.cpp
62serialization_test_path_LDADD = $(test_ldadd)
63serialization_test_path_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050064 $(test_ldflags)
Deepak Kodihalli707a3e12017-06-14 03:56:12 -050065
66serialization_test_properties_CPPFLAGS = $(test_cppflags)
67serialization_test_properties_CXXFLAGS = $(test_cxxflags)
68serialization_test_properties_SOURCES = serialization_test_properties.cpp
69serialization_test_properties_LDADD = $(test_ldadd)
70serialization_test_properties_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050071 $(test_ldflags)
Deepak Kodihalli834dcf12018-08-30 05:05:46 -050072
73remote_logging_test_address_CPPFLAGS = $(test_cppflags)
74remote_logging_test_address_CXXFLAGS = $(test_cxxflags)
75remote_logging_test_address_SOURCES = remote_logging_test_address.cpp
76remote_logging_test_address_LDADD = $(remote_logging_test_ldadd)
77remote_logging_test_address_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050078 $(test_ldflags)
Deepak Kodihalli834dcf12018-08-30 05:05:46 -050079
80remote_logging_test_port_CPPFLAGS = $(test_cppflags)
81remote_logging_test_port_CXXFLAGS = $(test_cxxflags)
82remote_logging_test_port_SOURCES = remote_logging_test_port.cpp
83remote_logging_test_port_LDADD = $(remote_logging_test_ldadd)
84remote_logging_test_port_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050085 $(test_ldflags)
Deepak Kodihalli5ac1bde2018-08-30 05:38:44 -050086
87remote_logging_test_config_CPPFLAGS = $(test_cppflags)
88remote_logging_test_config_CXXFLAGS = $(test_cxxflags)
89remote_logging_test_config_SOURCES = remote_logging_test_config.cpp
90remote_logging_test_config_LDADD = $(remote_logging_test_ldadd)
91remote_logging_test_config_LDFLAGS = \
Matt Spinler1787c522019-07-09 12:58:37 -050092 $(test_ldflags)
Adriana Kobylak7d111a82018-09-04 10:14:24 -050093
Patrick Venture31552c02018-12-03 19:09:55 -080094sdjournal_mock_test_CPPFLAGS = $(test_cppflags)
95sdjournal_mock_test_CXXFLAGS = $(test_cxxflags)
96sdjournal_mock_test_SOURCES = sdtest.cpp
97sdjournal_mock_test_LDADD = $(top_builddir)/sdjournal.o
98sdjournal_mock_test_LDFLAGS = $(test_ldflags)
99
Matt Spinler99c2b402019-05-23 14:29:16 -0500100extensions_test_CPPFLAGS = $(test_cppflags)
101extensions_test_CXXFLAGS = $(test_cxxflags)
102extensions_test_SOURCES = extensions_test.cpp
103extensions_test_LDADD = \
104 $(top_builddir)/elog_entry.o \
105 $(top_builddir)/elog-lookup.o \
106 $(top_builddir)/elog_meta.o \
107 $(top_builddir)/elog-process-metadata.o \
108 $(top_builddir)/elog_serialize.o \
109 $(top_builddir)/log_manager.o \
Matt Spinler99c2b402019-05-23 14:29:16 -0500110 $(top_builddir)/xyz/openbmc_project/Logging/Internal/Manager/server.o
Matt Spinler1787c522019-07-09 12:58:37 -0500111extensions_test_LDFLAGS = $(test_ldflags)
Matt Spinler99c2b402019-05-23 14:29:16 -0500112
Matt Spinler1e71a4d2020-03-04 13:40:22 -0600113elog_update_ts_test_CPPFLAGS = $(test_cppflags)
114elog_update_ts_test_CXXFLAGS = $(test_cxxflags)
115elog_update_ts_test_SOURCES = elog_update_ts_test.cpp
116elog_update_ts_test_LDADD = $(test_ldadd)
117elog_update_ts_test_LDFLAGS = \
118 $(test_ldflags)
119
Andrew Geisslere4960ee2020-03-30 14:31:52 -0500120elog_quiesce_test_CPPFLAGS = $(test_cppflags)
121elog_quiesce_test_CXXFLAGS = $(test_cxxflags)
122elog_quiesce_test_SOURCES = elog_quiesce_test.cpp
123elog_quiesce_test_LDADD = $(test_ldadd)
124elog_quiesce_test_LDFLAGS = \
125 $(test_ldflags)
126
127
Adriana Kobylak7d111a82018-09-04 10:14:24 -0500128# TODO Remove once the test-case failure is resolved openbmc/phosphor-logging#11
129XFAIL_TESTS = elog_errorwrap_test
Matt Spinler15ee6ae2019-07-08 16:50:06 -0500130
131if ENABLE_PEL_EXTENSION
132include openpower-pels/Makefile.include
133endif