Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,17 @@ endif

# The list of packages to be built. The order matters.
# wolfictl determines the list and order
PKGLIST ?= $(shell $(WOLFICTL) text --dir . --type name)
# set only to be called when needed, so make can be instant to run
# when it is not
PKGLISTCMD ?= $(WOLFICTL) text --dir . --type name

all: ${KEY} .build-packages
ifeq ($(MAKECMDGOALS),all)
PKGLIST := $(addprefix package/,$(shell $(PKGLISTCMD)))
else
PKGLIST :=
endif
.build-packages: $(PKGLIST)

${KEY}:
${MELANGE} keygen ${KEY}
Expand All @@ -46,15 +54,13 @@ clean:

.PHONY: list list-yaml
list:
$(info $(PKGLIST))
$(info $(shell $(PKGLISTCMD)))
@printf ''

list-yaml:
$(info $(addsuffix .yaml,$(PKGLIST)))
$(info $(addsuffix .yaml,$(shell $(PKGLISTCMD))))
@printf ''

.build-packages: $(addprefix package/,${PKGLIST})

package/%:
$(eval yamlfile := $*.yaml)
$(eval pkgver := $(shell $(MELANGE) package-version $(yamlfile)))
Expand Down