blob: 6a6422f3e5026066ca5a2df4f19fafbee8f12c94 [file] [log] [blame]
Brad Bishop40a360c2016-05-28 18:41:04 -04001GDBUS_APPS = bmcctl \
Brad Bishop40a360c2016-05-28 18:41:04 -04002 flashbios \
Brad Bishop40a360c2016-05-28 18:41:04 -04003 op-flasher \
4 op-hostctl \
5 op-pwrctl \
6 pciedetect \
7 pwrbutton \
8 rstbutton
Norman Jamese2765102015-08-19 22:00:55 -05009
Yi Li2f3213f2016-08-03 11:09:55 +080010SUBDIRS = fanctl \
Brad Bishop40a360c2016-05-28 18:41:04 -040011 ledctl \
12 libopenbmc_intf \
13 pychassisctl \
14 pydownloadmgr \
Brad Bishop40a360c2016-05-28 18:41:04 -040015 pyflashbmc \
Brad Bishop40a360c2016-05-28 18:41:04 -040016 pyinventorymgr \
17 pyipmitest \
Brad Bishop40a360c2016-05-28 18:41:04 -040018 pystatemgr \
19 pysystemmgr \
20 pytools
Norman Jamese2765102015-08-19 22:00:55 -050021
Brad Bishop6f4ba052016-06-27 13:45:18 -040022REVERSE_SUBDIRS = $(shell echo $(SUBDIRS) $(GDBUS_APPS) | tr ' ' '\n' | tac |tr '\n' ' ')
Norman Jamesddb97382015-08-27 21:31:31 -050023
Brad Bishop6f4ba052016-06-27 13:45:18 -040024.PHONY: subdirs $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050025
Brad Bishop6f4ba052016-06-27 13:45:18 -040026subdirs: $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050027
Brad Bishop40a360c2016-05-28 18:41:04 -040028$(SUBDIRS):
29 $(MAKE) -C $@
Norman James1e25d1d2015-09-15 08:20:56 -050030
Brad Bishop40a360c2016-05-28 18:41:04 -040031$(GDBUS_APPS): libopenbmc_intf
Brad Bishop6f4ba052016-06-27 13:45:18 -040032 $(MAKE) -C $@ CFLAGS="-I ../$^" LDFLAGS="-L ../$^"
Adriana Kobylak597d49e2015-10-29 08:33:03 -050033
Brad Bishop40a360c2016-05-28 18:41:04 -040034install: subdirs
Brad Bishop6f4ba052016-06-27 13:45:18 -040035 @for d in $(SUBDIRS) $(GDBUS_APPS); do \
Brad Bishop40a360c2016-05-28 18:41:04 -040036 $(MAKE) -C $$d $@ DESTDIR=$(DESTDIR) PREFIX=$(PREFIX) || exit 1; \
37 done
38clean:
39 @for d in $(REVERSE_SUBDIRS); do \
40 $(MAKE) -C $$d $@ || exit 1; \
41 done