blob: 3373fcbbc1648c2f37aed9b56f59d4a3e527b60c [file] [log] [blame]
Gunnar Mills01a323b2017-01-18 09:48:13 -06001AM_DEFAULT_SOURCE_EXT = .cpp
2
Deepak Kodihalli059e2332017-04-12 06:40:53 -05003# Build these headers, don't install them
4noinst_HEADERS = \
Deepak Kodihalli059e2332017-04-12 06:40:53 -05005 download_manager.hpp \
Gunnar Millse91d3212017-04-19 15:42:47 -05006 watch.hpp \
7 version.hpp \
Lei YU1be8d502018-06-20 11:48:36 +08008 images.hpp \
Gunnar Millsec1b41c2017-05-02 12:20:36 -05009 image_manager.hpp \
Saqib Khanb0774702017-05-23 16:02:41 -050010 item_updater.hpp \
Lei YU56aaf452018-06-21 16:09:44 +080011 activation.hpp \
12 flash.hpp \
13 item_updater_helper.hpp
Deepak Kodihalli059e2332017-04-12 06:40:53 -050014
Gunnar Mills01a323b2017-01-18 09:48:13 -060015sbin_PROGRAMS = \
Gunnar Mills701e0212017-04-03 11:21:27 -050016 phosphor-version-software-manager \
Gunnar Millsec1b41c2017-05-02 12:20:36 -050017 phosphor-download-manager \
18 phosphor-image-updater
Gunnar Mills01a323b2017-01-18 09:48:13 -060019
20phosphor_version_software_manager_SOURCES = \
Deepak Kodihalli059e2332017-04-12 06:40:53 -050021 image_manager_main.cpp \
Gunnar Millse91d3212017-04-19 15:42:47 -050022 watch.cpp \
23 version.cpp \
24 image_manager.cpp
Gunnar Mills01a323b2017-01-18 09:48:13 -060025
Gunnar Mills93c12d32017-05-10 13:11:53 -050026BUILT_SOURCES = \
27 xyz/openbmc_project/Software/Version/error.cpp \
Gunnar Millsf5eaf392017-08-22 16:36:55 -050028 xyz/openbmc_project/Software/Version/error.hpp \
29 org/openbmc/Associations/server.cpp \
30 org/openbmc/Associations/server.hpp
Gunnar Mills93c12d32017-05-10 13:11:53 -050031
32CLEANFILES = ${BUILT_SOURCES}
33
Gunnar Mills701e0212017-04-03 11:21:27 -050034phosphor_download_manager_SOURCES = \
35 download_manager.cpp \
36 download_manager_main.cpp
37
Gunnar Millsec1b41c2017-05-02 12:20:36 -050038phosphor_image_updater_SOURCES = \
Saqib Khanb0774702017-05-23 16:02:41 -050039 activation.cpp \
Saqib Khan705f1bf2017-06-09 23:58:38 -050040 version.cpp \
Saqib Khan5d532672017-08-09 10:44:50 -050041 serialize.cpp \
Gunnar Millsec1b41c2017-05-02 12:20:36 -050042 item_updater.cpp \
Jayanth Othayoth0e0c1272018-02-21 05:46:36 -060043 item_updater_main.cpp
44
Lei YUa7853ee2018-05-23 11:13:12 +080045if UBIFS_LAYOUT
Adriana Kobylak9f89e2e2018-05-30 13:16:20 -050046include ubi/Makefile.am.include
Lei YUa7853ee2018-05-23 11:13:12 +080047else
48include static/Makefile.am.include
49endif
Adriana Kobylak9f89e2e2018-05-30 13:16:20 -050050
Jayanth Othayoth0e0c1272018-02-21 05:46:36 -060051if WANT_SIGNATURE_VERIFY_BUILD
Adriana Kobylak5ed9b2d2018-09-06 13:15:34 -050052noinst_HEADERS += \
53 image_verify.hpp \
54 utils.hpp
55phosphor_image_updater_SOURCES += \
56 image_verify.cpp \
57 utils.cpp
Jayanth Othayoth0e0c1272018-02-21 05:46:36 -060058endif
Gunnar Mills652da832017-08-29 08:34:54 -050059
Adriana Kobylak7e8d76b2018-04-20 10:03:01 -050060if WANT_SYNC
Adriana Kobylakb072d1b2018-04-24 11:37:21 -050061noinst_HEADERS += \
62 sync_manager.hpp \
63 sync_watch.hpp
Adriana Kobylak7e8d76b2018-04-20 10:03:01 -050064sbin_PROGRAMS += phosphor-sync-software-manager
Adriana Kobylakb072d1b2018-04-24 11:37:21 -050065phosphor_sync_software_manager_SOURCES = \
66 sync_manager.cpp \
67 sync_watch.cpp \
68 sync_manager_main.cpp
Adriana Kobylak7e8d76b2018-04-20 10:03:01 -050069phosphor_sync_software_manager_CXXFLAGS = $(generic_cxxflags)
70phosphor_sync_software_manager_LDFLAGS = $(generic_ldflags)
71endif
72
Gunnar Mills652da832017-08-29 08:34:54 -050073nodist_phosphor_image_updater_SOURCES = \
Gunnar Millsf5eaf392017-08-22 16:36:55 -050074 org/openbmc/Associations/server.cpp
Gunnar Millsec1b41c2017-05-02 12:20:36 -050075
Deepak Kodihalli059e2332017-04-12 06:40:53 -050076generic_cxxflags = \
77 $(SYSTEMD_CFLAGS) \
78 $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \
79 $(SDBUSPLUS_CFLAGS) \
Andrew Geisslere4c06322018-08-27 11:27:54 -070080 $(PHOSPHOR_LOGGING_CFLAGS) \
81 -flto
Deepak Kodihalli059e2332017-04-12 06:40:53 -050082generic_ldflags = \
83 $(SYSTEMD_LIBS) \
84 $(PHOSPHOR_DBUS_INTERFACES_LIBS) \
85 $(SDBUSPLUS_LIBS) \
Gunnar Mills3a482f62017-04-20 16:07:20 -050086 $(PHOSPHOR_LOGGING_LIBS) \
Saqib Khan26a960d2017-09-19 14:23:28 -050087 -lstdc++fs \
88 -lssl \
89 -lcrypto
Gunnar Mills32159fb2017-01-31 21:44:36 -060090
Gunnar Mills93c12d32017-05-10 13:11:53 -050091xyz/openbmc_project/Software/Version/error.hpp: ${top_srcdir}/xyz/openbmc_project/Software/Version.errors.yaml
92 @mkdir -p `dirname $@`
93 $(SDBUSPLUSPLUS) -r $(srcdir) error exception-header xyz.openbmc_project.Software.Version > $@
94
95xyz/openbmc_project/Software/Version/error.cpp: ${top_srcdir}/xyz/openbmc_project/Software/Version.errors.yaml
96 @mkdir -p `dirname $@`
97 $(SDBUSPLUSPLUS) -r $(srcdir) error exception-cpp xyz.openbmc_project.Software.Version > $@
98
Gunnar Millsf5eaf392017-08-22 16:36:55 -050099org/openbmc/Associations/server.cpp: org/openbmc/Associations.interface.yaml
100 @mkdir -p `dirname $@`
101 $(SDBUSPLUSPLUS) -r $(srcdir) interface server-cpp org.openbmc.Associations > $@
102
103org/openbmc/Associations/server.hpp: org/openbmc/Associations.interface.yaml
104 @mkdir -p `dirname $@`
105 $(SDBUSPLUSPLUS) -r $(srcdir) interface server-header org.openbmc.Associations > $@
106
Gunnar Mills32159fb2017-01-31 21:44:36 -0600107phosphor_version_software_manager_CXXFLAGS = $(generic_cxxflags)
108phosphor_version_software_manager_LDFLAGS = $(generic_ldflags)
Gunnar Mills701e0212017-04-03 11:21:27 -0500109phosphor_download_manager_CXXFLAGS = $(generic_cxxflags)
110phosphor_download_manager_LDFLAGS = $(generic_ldflags)
Gunnar Millsec1b41c2017-05-02 12:20:36 -0500111phosphor_image_updater_CXXFLAGS = $(generic_cxxflags)
112phosphor_image_updater_LDFLAGS = $(generic_ldflags)
Gunnar Mills01d55c32017-04-20 10:52:15 -0500113
114SUBDIRS = test