blob: b79675d5b3a0868a41b05159b7aabddedf2faac5 [file] [log] [blame]
Brad Bishop40a360c2016-05-28 18:41:04 -04001GDBUS_APPS = bmcctl \
Brad Bishop40a360c2016-05-28 18:41:04 -04002 flashbios \
Adriana Kobylak066d56f2016-06-16 09:23:24 -05003 hostcheckstop \
Brad Bishop40a360c2016-05-28 18:41:04 -04004 hostwatchdog \
Brad Bishop40a360c2016-05-28 18:41:04 -04005 op-flasher \
6 op-hostctl \
7 op-pwrctl \
8 pciedetect \
9 pwrbutton \
10 rstbutton
Norman Jamese2765102015-08-19 22:00:55 -050011
Brad Bishop6f4ba052016-06-27 13:45:18 -040012SUBDIRS = hacks \
Brad Bishop40a360c2016-05-28 18:41:04 -040013 ledctl \
14 libopenbmc_intf \
15 pychassisctl \
16 pydownloadmgr \
17 pyfanctl \
18 pyflashbmc \
19 pyhwmon \
20 pyinventorymgr \
21 pyipmitest \
22 pysensormgr \
23 pystatemgr \
24 pysystemmgr \
25 pytools
Norman Jamese2765102015-08-19 22:00:55 -050026
Brad Bishop6f4ba052016-06-27 13:45:18 -040027REVERSE_SUBDIRS = $(shell echo $(SUBDIRS) $(GDBUS_APPS) | tr ' ' '\n' | tac |tr '\n' ' ')
Norman Jamesddb97382015-08-27 21:31:31 -050028
Brad Bishop6f4ba052016-06-27 13:45:18 -040029.PHONY: subdirs $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050030
Brad Bishop6f4ba052016-06-27 13:45:18 -040031subdirs: $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050032
Brad Bishop40a360c2016-05-28 18:41:04 -040033$(SUBDIRS):
34 $(MAKE) -C $@
Norman James1e25d1d2015-09-15 08:20:56 -050035
Brad Bishop40a360c2016-05-28 18:41:04 -040036$(GDBUS_APPS): libopenbmc_intf
Brad Bishop6f4ba052016-06-27 13:45:18 -040037 $(MAKE) -C $@ CFLAGS="-I ../$^" LDFLAGS="-L ../$^"
Adriana Kobylak597d49e2015-10-29 08:33:03 -050038
Brad Bishop40a360c2016-05-28 18:41:04 -040039install: subdirs
Brad Bishop6f4ba052016-06-27 13:45:18 -040040 @for d in $(SUBDIRS) $(GDBUS_APPS); do \
Brad Bishop40a360c2016-05-28 18:41:04 -040041 $(MAKE) -C $$d $@ DESTDIR=$(DESTDIR) PREFIX=$(PREFIX) || exit 1; \
42 done
43clean:
44 @for d in $(REVERSE_SUBDIRS); do \
45 $(MAKE) -C $$d $@ || exit 1; \
46 done