blob: fb4ecb20a76fc9323168ae1784d2fc9909a18c82 [file] [log] [blame]
Brad Bishop1a886e32016-11-11 16:02:10 -05001EXTRAIFACES_C=@EXTRAIFACES_C@
2EXTRAIFACES_LO=@EXTRAIFACES_LO@
3BUILT_SOURCES=generated.cpp
Brad Bishopc7166352016-11-12 21:38:41 -05004
Brad Bishop1a886e32016-11-11 16:02:10 -05005CLEANFILES=$(BUILT_SOURCES) $(EXTRAIFACES_C) libextra.la
6
Brad Bishop73b776b2016-10-19 07:50:28 -04007sbin_PROGRAMS = phosphor-inventory
Brad Bishopd4468352016-10-31 13:20:02 -05008phosphor_inventory_SOURCES = app.cpp
9phosphor_inventory_LDADD = libmanager.la
Brad Bishopc7166352016-11-12 21:38:41 -050010phosphor_inventory_LDFLAGS = $(SYSTEMD_LIBS)
11phosphor_inventory_CFLAGS = $(SYSTEMD_CFLAGS)
Brad Bishopd4468352016-10-31 13:20:02 -050012
13noinst_LTLIBRARIES = libmanager.la
14libmanager_la_SOURCES = \
Brad Bishopadc45662016-10-28 20:00:57 -050015 xyz.openbmc_project.Inventory.Manager.cpp \
Brad Bishop789cf832016-10-22 00:47:54 -040016 generated.cpp \
Brad Bishopfa51da72017-01-19 11:06:51 -050017 events.cpp \
Brad Bishop49aefb32016-10-19 11:54:14 -040018 manager.cpp
Deepak Kodihalli2a9f9342017-02-03 05:02:27 -060019libmanager_la_LIBADD = libextra.la $(SDBUSPLUS_LIBS)
Brad Bishop64d994a2016-10-31 10:24:27 -050020
Brad Bishop1a886e32016-11-11 16:02:10 -050021# Automake does not allow autoconf substituted variables
22# in _SOURCES variables. Work around this by providing
23# our own target.
24#
25# Typically the recommendation is conditional compilation
26# but here the generated source files are completely
27# arbitrary and not known making that approach difficult.
28libextra.la: $(EXTRAIFACES_LO)
29 $(AM_V_CXXLD)$(CXXLINK) $(EXTRAIFACES_LO)
30
31$(EXTRAIFACES_C) generated.cpp:
32 $(AM_V_GEN)@PIMGEN@ -o $(top_builddir) generate-cpp
33
Brad Bishop74e52bc2016-10-31 13:12:04 -050034SUBDIRS = . test