Merge pull request #16 from jiangyy/fix-makefile

Makefile.app: use rules to spefify the dependency, instead of sub-make
This commit is contained in:
Yanyan Jiang 2019-02-17 13:44:28 +08:00 committed by GitHub
commit ce2308aa80
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 8 deletions

View File

@ -24,16 +24,13 @@ LINK_FILES += $(addsuffix -$(ARCH).a, $(join \
$(LINKLIBS) \
))
.PHONY: app _app prebuild postbuild run clean
prebuild: $(PREBUILD)
postbuild: $(POSTBUILD)
.PHONY: app _app __dummy run clean
$(OBJS): $(PREBUILD)
_app: $(OBJS) am $(LIBS)
@bash $(AM_HOME)/am/arch/$(ARCH)/img/build $(BINARY) $(LINK_FILES)
app:
$(MAKE) prebuild
$(MAKE) _app
$(MAKE) postbuild
$(POSTBUILD) __dummy: _app
app: $(POSTBUILD) __dummy
run: app
@bash $(AM_HOME)/am/arch/$(ARCH)/img/run $(BINARY)