first apps :)

This commit is contained in:
Yann Autissier
2023-11-26 05:14:30 +01:00
parent 5e3782c944
commit 2699a04c84
12 changed files with 122 additions and 15 deletions
+8 -1
View File
@@ -12,8 +12,11 @@ $(APP): myos-user
## ex: app-foo-build will call app-build for app foo in ../foo
.PHONY: app-%
app-%:
$(eval COMPOSE_FILE :=)
$(eval STACK :=)
$(eval app := $(subst -$(lastword $(subst -, ,$*)),,$*))
$(eval command := $(lastword $(subst -, ,$*)))
$(eval include $(wildcard apps/$(app).mk apps/$(app)/$(app).mk)) \
$(if $(wildcard $(RELATIVE)$(app)), \
$(if $(filter app-$(command),$(.VARIABLES)), \
$(call app-bootstrap,$(app)) \
@@ -26,7 +29,11 @@ app-%:
) \
) \
, \
$(call WARNING,Unable to find app,$(app),in dir,$(RELATIVE)$(app)) \
$(if $(wildcard apps/$(app).mk apps/$(app)/$(app).mk), \
$(call app-install) \
$(call app-bootstrap) \
,$(call WARNING,Unable to find app,$(app),in dir,$(RELATIVE)$(app)) \
) \
)
# target app-required-install: Call app-install for each APP_REQUIRED