blob: bbadf04d93a568cf26ae05a0f85e574856f57b6e [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 \
Brad Bishop40a360c2016-05-28 18:41:04 -04006 pwrbutton \
7 rstbutton
Norman Jamese2765102015-08-19 22:00:55 -05008
Yi Li2f3213f2016-08-03 11:09:55 +08009SUBDIRS = fanctl \
Brad Bishop40a360c2016-05-28 18:41:04 -040010 ledctl \
11 libopenbmc_intf \
12 pychassisctl \
13 pydownloadmgr \
Brad Bishop40a360c2016-05-28 18:41:04 -040014 pyflashbmc \
Brad Bishop40a360c2016-05-28 18:41:04 -040015 pyinventorymgr \
16 pyipmitest \
Brad Bishop40a360c2016-05-28 18:41:04 -040017 pystatemgr \
18 pysystemmgr \
19 pytools
Norman Jamese2765102015-08-19 22:00:55 -050020
Brad Bishop6f4ba052016-06-27 13:45:18 -040021REVERSE_SUBDIRS = $(shell echo $(SUBDIRS) $(GDBUS_APPS) | tr ' ' '\n' | tac |tr '\n' ' ')
Norman Jamesddb97382015-08-27 21:31:31 -050022
Brad Bishop6f4ba052016-06-27 13:45:18 -040023.PHONY: subdirs $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050024
Brad Bishop6f4ba052016-06-27 13:45:18 -040025subdirs: $(SUBDIRS) $(GDBUS_APPS)
Norman Jamese2765102015-08-19 22:00:55 -050026
Brad Bishop40a360c2016-05-28 18:41:04 -040027$(SUBDIRS):
28 $(MAKE) -C $@
Norman James1e25d1d2015-09-15 08:20:56 -050029
Brad Bishop40a360c2016-05-28 18:41:04 -040030$(GDBUS_APPS): libopenbmc_intf
Brad Bishop6f4ba052016-06-27 13:45:18 -040031 $(MAKE) -C $@ CFLAGS="-I ../$^" LDFLAGS="-L ../$^"
Adriana Kobylak597d49e2015-10-29 08:33:03 -050032
Brad Bishop40a360c2016-05-28 18:41:04 -040033install: subdirs
Brad Bishop6f4ba052016-06-27 13:45:18 -040034 @for d in $(SUBDIRS) $(GDBUS_APPS); do \
Brad Bishop40a360c2016-05-28 18:41:04 -040035 $(MAKE) -C $$d $@ DESTDIR=$(DESTDIR) PREFIX=$(PREFIX) || exit 1; \
36 done
37clean:
38 @for d in $(REVERSE_SUBDIRS); do \
39 $(MAKE) -C $$d $@ || exit 1; \
40 done