Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 1 | AM_DEFAULT_SOURCE_EXT = .cpp |
| 2 | |
Patrick Venture | 94feffa | 2019-03-06 09:54:49 -0800 | [diff] [blame] | 3 | # Ignore system headers |
| 4 | CODE_COVERAGE_IGNORE_PATTERN = '/include/*' '/usr/include/*' '$(includedir)/*' |
| 5 | export CODE_COVERAGE_IGNORE_PATTERN |
| 6 | |
| 7 | CODE_COVERAGE_LCOV_SHOPTS = $(CODE_COVERAGE_LCOV_SHOPTS_DEFAULT) |
| 8 | # Use our configuration file for lcov |
| 9 | CODE_COVERAGE_LCOV_SHOPTS += --config-file $(abs_srcdir)/.lcovrc |
| 10 | export CODE_COVERAGE_LCOV_SHOPTS |
| 11 | |
| 12 | CODE_COVERAGE_LCOV_OPTIONS = $(CODE_COVERAGE_LCOV_OPTIONS_DEFAULT) |
| 13 | # Use our configuration file for lcov |
| 14 | CODE_COVERAGE_LCOV_OPTIONS += --config-file $(abs_srcdir)/.lcovrc |
| 15 | export CODE_COVERAGE_LCOV_OPTIONS |
| 16 | |
| 17 | CODE_COVERAGE_LCOV_RMOPTS = $(CODE_COVERAGE_LCOV_RMOPTS_DEFAULT) |
| 18 | # Use our configuration file for lcov |
| 19 | CODE_COVERAGE_LCOV_RMOPTS += --config-file $(abs_srcdir)/.lcovrc |
| 20 | export CODE_COVERAGE_LCOV_RMOPTS |
| 21 | |
| 22 | CODE_COVERAGE_GENHTML_OPTIONS = $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT) |
| 23 | # Use our configuration file for genhtml |
| 24 | CODE_COVERAGE_GENHTML_OPTIONS += --config-file $(abs_srcdir)/.lcovrc |
| 25 | # Don't generate the absolute path for each file in the HTML output |
| 26 | CODE_COVERAGE_GENHTML_OPTIONS += --prefix $(abs_srcdir) --prefix $(abs_builddir) |
| 27 | export CODE_COVERAGE_GENHTML_OPTIONS |
| 28 | |
Patrick Venture | 90e9dbc | 2019-03-19 09:10:41 -0700 | [diff] [blame] | 29 | if AUTOCONF_CODE_COVERAGE_2019_01_06 |
| 30 | include $(top_srcdir)/aminclude_static.am |
| 31 | clean-local: code-coverage-clean |
| 32 | distclean-local: code-coverage-dist-clean |
| 33 | else |
| 34 | @CODE_COVERAGE_RULES@ |
| 35 | endif |
| 36 | |
Patrick Venture | 94feffa | 2019-03-06 09:54:49 -0800 | [diff] [blame] | 37 | AM_CPPFLAGS = $(CODE_COVERAGE_CPPFLAGS) |
| 38 | AM_CFLAGS = $(CODE_COVERAGE_CFLAGS) |
| 39 | AM_CXXFLAGS = $(CODE_COVERAGE_CXXFLAGS) |
| 40 | |
Vijay Khemka | 5584543 | 2019-06-19 14:25:40 -0700 | [diff] [blame] | 41 | if HAVE_SYSTEMD |
| 42 | systemdsystemunit_DATA = phosphor-pid-control.service |
| 43 | endif |
| 44 | |
Patrick Venture | fe0b896 | 2019-03-28 10:39:40 -0700 | [diff] [blame] | 45 | bin_PROGRAMS = swampd setsensor |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 46 | |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 47 | setsensor_SOURCES = setsensor.cpp |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 48 | setsensor_LDADD = \ |
| 49 | $(SDBUSPLUS_LIBS) \ |
| 50 | $(PHOSPHOR_DBUS_INTERFACES_LIBS) \ |
Patrick Venture | 94feffa | 2019-03-06 09:54:49 -0800 | [diff] [blame] | 51 | $(PHOSPHOR_LOGGING_LIBS) \ |
| 52 | $(CODE_COVERAGE_LIBS) |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 53 | setsensor_CXXFLAGS = \ |
| 54 | $(SDBUSPLUS_CFLAGS) \ |
| 55 | $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \ |
Patrick Venture | f427411 | 2019-03-06 13:37:46 -0800 | [diff] [blame] | 56 | $(PHOSPHOR_LOGGING_CFLAGS) \ |
| 57 | $(CODE_COVERAGE_CXXFLAGS) |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 58 | |
Patrick Venture | cdd6134 | 2020-08-07 15:49:56 -0700 | [diff] [blame] | 59 | swampd_SOURCES = main.cpp |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 60 | swampd_LDADD = \ |
| 61 | $(SDBUSPLUS_LIBS) \ |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 62 | libswampd.la |
| 63 | swampd_CXXFLAGS = \ |
| 64 | $(SDBUSPLUS_CFLAGS) \ |
Patrick Venture | f427411 | 2019-03-06 13:37:46 -0800 | [diff] [blame] | 65 | $(CODE_COVERAGE_CXXFLAGS) |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 66 | |
| 67 | noinst_LTLIBRARIES = libswampd.la |
| 68 | libswampd_la_LDFLAGS = -static |
| 69 | libswampd_la_LIBADD = \ |
| 70 | -lstdc++fs \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 71 | $(SDBUSPLUS_LIBS) \ |
| 72 | $(PHOSPHOR_DBUS_INTERFACES_LIBS) \ |
Patrick Venture | 94feffa | 2019-03-06 09:54:49 -0800 | [diff] [blame] | 73 | $(PHOSPHOR_LOGGING_LIBS) \ |
| 74 | $(CODE_COVERAGE_LIBS) |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 75 | libswampd_la_CXXFLAGS = \ |
| 76 | $(SDBUSPLUS_CFLAGS) \ |
| 77 | $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \ |
Patrick Venture | f0b7fa3 | 2018-11-09 08:40:32 -0800 | [diff] [blame] | 78 | $(PHOSPHOR_LOGGING_CFLAGS) \ |
Patrick Venture | 86a1820 | 2019-09-09 12:27:53 -0700 | [diff] [blame] | 79 | $(CODE_COVERAGE_CXXFLAGS) |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 80 | |
| 81 | libswampd_la_SOURCES = \ |
| 82 | notimpl/readonly.cpp \ |
| 83 | notimpl/writeonly.cpp \ |
Patrick Venture | 7f9d690 | 2020-09-10 12:09:57 -0700 | [diff] [blame] | 84 | dbus/dbusconfiguration.cpp \ |
Patrick Venture | aadb30d | 2020-08-10 09:17:11 -0700 | [diff] [blame] | 85 | dbus/dbusutil.cpp \ |
| 86 | dbus/dbushelper.cpp \ |
James Feist | 98b704e | 2019-06-03 16:24:53 -0700 | [diff] [blame] | 87 | dbus/dbuspassiveredundancy.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 88 | dbus/dbuspassive.cpp \ |
| 89 | dbus/dbusactiveread.cpp \ |
James Feist | 7136a5a | 2018-07-19 09:52:05 -0700 | [diff] [blame] | 90 | dbus/dbuswrite.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 91 | sysfs/sysfsread.cpp \ |
| 92 | sysfs/sysfswrite.cpp \ |
| 93 | sysfs/util.cpp \ |
| 94 | sensors/pluggable.cpp \ |
| 95 | sensors/host.cpp \ |
Patrick Venture | 5e92909 | 2018-06-08 10:55:23 -0700 | [diff] [blame] | 96 | sensors/builder.cpp \ |
Patrick Venture | eeeb867 | 2019-02-08 11:47:42 -0800 | [diff] [blame] | 97 | sensors/buildjson.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 98 | sensors/manager.cpp \ |
Patrick Venture | cdd6134 | 2020-08-07 15:49:56 -0700 | [diff] [blame] | 99 | sensors/build_utils.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 100 | pid/ec/pid.cpp \ |
James Feist | 22c257a | 2018-08-31 14:07:12 -0700 | [diff] [blame] | 101 | pid/ec/stepwise.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 102 | pid/fancontroller.cpp \ |
| 103 | pid/thermalcontroller.cpp \ |
James Feist | 22c257a | 2018-08-31 14:07:12 -0700 | [diff] [blame] | 104 | pid/pidcontroller.cpp \ |
| 105 | pid/stepwisecontroller.cpp \ |
Patrick Venture | 5c7cc54 | 2018-06-11 14:29:38 -0700 | [diff] [blame] | 106 | pid/builder.cpp \ |
Patrick Venture | d149172 | 2019-02-08 14:37:45 -0800 | [diff] [blame] | 107 | pid/buildjson.cpp \ |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 108 | pid/zone.cpp \ |
| 109 | pid/util.cpp \ |
James Feist | ce6a3f3 | 2019-03-12 11:20:16 -0700 | [diff] [blame] | 110 | pid/pidloop.cpp \ |
Patrick Venture | c32e3fc | 2019-02-28 10:01:11 -0800 | [diff] [blame] | 111 | pid/tuning.cpp \ |
Patrick Venture | 5426c34 | 2019-02-11 12:03:30 -0800 | [diff] [blame] | 112 | build/buildjson.cpp \ |
Patrick Venture | 18b1311 | 2019-02-14 11:43:59 -0800 | [diff] [blame] | 113 | experiments/drive.cpp |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 114 | |
Patrick Venture | ba00343 | 2018-07-27 06:59:05 -0700 | [diff] [blame] | 115 | libmanualcmdsdir = ${libdir}/ipmid-providers |
| 116 | libmanualcmds_LTLIBRARIES = libmanualcmds.la |
| 117 | libmanualcmds_la_SOURCES = \ |
Patrick Venture | 9bf5cef | 2020-08-16 08:59:54 -0700 | [diff] [blame] | 118 | ipmi/main_ipmi.cpp \ |
Patrick Venture | d82d0b7 | 2020-08-16 09:17:37 -0700 | [diff] [blame] | 119 | ipmi/manualcmds.cpp \ |
| 120 | ipmi/dbus_mode.cpp |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 121 | libmanualcmds_la_LDFLAGS = \ |
| 122 | $(SYSTEMD_LIBS) \ |
| 123 | $(PHOSPHOR_DBUS_INTERFACES_LIBS) \ |
| 124 | $(PHOSPHOR_LOGGING_LIBS) \ |
William A. Kennington III | 331143c | 2019-02-07 15:52:44 -0800 | [diff] [blame] | 125 | $(LIBIPMID_LIBS) \ |
Patrick Venture | 94feffa | 2019-03-06 09:54:49 -0800 | [diff] [blame] | 126 | $(CODE_COVERAGE_LIBS) \ |
Patrick Venture | ba3c8c1 | 2018-11-09 08:43:00 -0800 | [diff] [blame] | 127 | -version-info 0:0:0 -shared |
| 128 | libmanualcmds_la_CXXFLAGS = \ |
| 129 | $(SYSTEMD_CFLAGS) \ |
| 130 | $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \ |
| 131 | $(PHOSPHOR_LOGGING_CFLAGS) \ |
William A. Kennington III | 331143c | 2019-02-07 15:52:44 -0800 | [diff] [blame] | 132 | $(LIBIPMID_CFLAGS) \ |
Patrick Venture | 86a1820 | 2019-09-09 12:27:53 -0700 | [diff] [blame] | 133 | $(CODE_COVERAGE_CXXFLAGS) |
Patrick Venture | e620656 | 2018-03-08 15:36:53 -0800 | [diff] [blame] | 134 | |
Patrick Venture | 7a841b6 | 2018-06-13 09:39:46 -0700 | [diff] [blame] | 135 | SUBDIRS = . test |