Marri Devender Rao | 82056ee | 2017-04-27 00:54:50 -0500 | [diff] [blame] | 1 | AM_DEFAULT_SOURCE_EXT = .cpp |
Marri Devender Rao | ca04522 | 2017-09-26 11:58:59 -0500 | [diff] [blame] | 2 | |
Marri Devender Rao | ca04522 | 2017-09-26 11:58:59 -0500 | [diff] [blame] | 3 | if !INSTALL_ERROR_YAML |
Vishwanatha Subbanna | 0eff609 | 2017-06-12 21:03:36 +0530 | [diff] [blame] | 4 | sbin_PROGRAMS = checkstop_app \ |
| 5 | watchdog_timeout |
Marri Devender Rao | 82056ee | 2017-04-27 00:54:50 -0500 | [diff] [blame] | 6 | |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 7 | nobase_nodist_include_HEADERS = \ |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 8 | org/open_power/Host/Boot/error.hpp |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 9 | |
Marri Devender Rao | caeecac | 2017-09-26 12:06:24 -0500 | [diff] [blame] | 10 | if GEN_ERRORS |
| 11 | nobase_nodist_include_HEADERS += \ |
| 12 | phosphor-logging/elog-errors.hpp |
| 13 | endif |
| 14 | |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 15 | BUILT_SOURCES = \ |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 16 | org/open_power/Host/Boot/error.cpp \ |
| 17 | org/open_power/Host/Boot/error.hpp |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 18 | |
Marri Devender Rao | caeecac | 2017-09-26 12:06:24 -0500 | [diff] [blame] | 19 | if GEN_ERRORS |
| 20 | BUILT_SOURCES += phosphor-logging/elog-errors.hpp |
| 21 | endif |
| 22 | |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 23 | CLEANFILES = ${BUILT_SOURCES} |
| 24 | |
| 25 | checkstop_app_SOURCES = checkstop_app.cpp \ |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 26 | org/open_power/Host/Boot/error.cpp |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 27 | |
Vishwanatha Subbanna | 0eff609 | 2017-06-12 21:03:36 +0530 | [diff] [blame] | 28 | watchdog_timeout_SOURCES = watchdog_timeout.cpp \ |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 29 | org/open_power/Host/Boot/error.cpp |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 30 | |
Vishwanatha Subbanna | 0eff609 | 2017-06-12 21:03:36 +0530 | [diff] [blame] | 31 | generic_ldflags = \ |
| 32 | $(PHOSPHOR_LOGGING_LIBS) \ |
| 33 | $(SDBUSPLUS_LIBS) |
| 34 | |
| 35 | generic_cxxflags = \ |
| 36 | $(PHOSPHOR_LOGGING_CFLAGS) \ |
| 37 | $(SDBUSPLUS_CFLAGS) |
| 38 | |
| 39 | checkstop_app_LDFLAGS = ${generic_ldflags} |
| 40 | watchdog_timeout_LDFLAGS = ${generic_ldflags} |
| 41 | |
| 42 | checkstop_app_CXXFLAGS = ${generic_cxxflags} |
| 43 | watchdog_timeout_CXXFLAGS = ${generic_cxxflags} |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 44 | |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 45 | org/open_power/Host/Boot/error.hpp: ${top_srcdir}/org/open_power/Host/Boot.errors.yaml |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 46 | @mkdir -p `dirname $@` |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 47 | $(SDBUSPLUSPLUS) -r $(srcdir) error exception-header org.open_power.Host.Boot> $@ |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 48 | |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 49 | org/open_power/Host/Boot/error.cpp: ${top_srcdir}/org/open_power/Host/Boot.errors.yaml |
Marri Devender Rao | ce640f6 | 2017-05-14 09:11:05 -0500 | [diff] [blame] | 50 | @mkdir -p `dirname $@` |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 51 | $(SDBUSPLUSPLUS) -r $(srcdir) error exception-cpp org.open_power.Host.Boot> $@ |
Marri Devender Rao | caeecac | 2017-09-26 12:06:24 -0500 | [diff] [blame] | 52 | |
| 53 | endif |
Marri Devender Rao | ca04522 | 2017-09-26 11:58:59 -0500 | [diff] [blame] | 54 | # Export error YAML to shared location |
| 55 | yamldir = ${datadir}/phosphor-dbus-yaml/yaml |
| 56 | nobase_yaml_DATA = \ |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 57 | org/open_power/Host/Boot.errors.yaml |
Marri Devender Rao | caeecac | 2017-09-26 12:06:24 -0500 | [diff] [blame] | 58 | |
| 59 | # Generate phosphor-logging/elog-errors.hpp |
| 60 | if GEN_ERRORS |
| 61 | ELOG_MAKO ?= elog-gen-template.mako.hpp |
| 62 | ELOG_DIR ?= ${OECORE_NATIVE_SYSROOT}${datadir}/phosphor-logging/elog |
| 63 | ELOG_GEN_DIR ?= ${ELOG_DIR}/tools/ |
| 64 | ELOG_MAKO_DIR ?= ${ELOG_DIR}/tools/phosphor-logging/templates/ |
| 65 | YAML_DIR ?= ${OECORE_NATIVE_SYSROOT}${datadir}/phosphor-dbus-yaml/yaml |
| 66 | phosphor-logging/elog-errors.hpp: |
Marri Devender Rao | 0947c65 | 2017-10-24 02:27:15 -0500 | [diff] [blame] | 67 | @mkdir -p ${YAML_DIR}/org/open_power/Host |
| 68 | @cp ${top_srcdir}/org/open_power/Host/Boot.errors.yaml ${YAML_DIR}/org/open_power/Host/Boot.errors.yaml |
Marri Devender Rao | caeecac | 2017-09-26 12:06:24 -0500 | [diff] [blame] | 69 | @mkdir -p `dirname $@` |
| 70 | @chmod 777 $(ELOG_GEN_DIR)/elog-gen.py |
| 71 | $(AM_V_at)$(PYTHON) $(ELOG_GEN_DIR)/elog-gen.py -y ${YAML_DIR} -t ${ELOG_MAKO_DIR} -m ${ELOG_MAKO} -o $@ |
| 72 | endif |