pkg.in: initial profiles/

This is to support Centaurus-like images featuring
more than a single installation profile (e.g.,
"workstation/server/minimal").

Quite a few more modifications are needed to do it
right though as m-p has fallen prey to exactly the
"single root composition" assumption with its current
THE_* variables semantics and processing.
This commit is contained in:
Michael Shigorin 2016-03-25 13:41:41 +03:00
parent 39acb23760
commit 1f13b3a039
2 changed files with 22 additions and 1 deletions

View File

@ -7,6 +7,6 @@ endif
# sequential execution, no reason to haste
all:
@for dir in lists groups; do \
@for dir in lists groups profiles; do \
$(MAKE) -C $$dir; \
done

21
pkg.in/profiles/Makefile Normal file
View File

@ -0,0 +1,21 @@
# step 3: copy package profiles referenced in distro configuration
# (and only those!) over to $(BUILDDIR)
ifndef BUILDDIR
$(error BUILDDIR not defined)
endif
include $(BUILDDIR)/distcfg.mk
SUFFIX := pkg/profiles
TARGET := $(BUILDDIR)/$(SUFFIX)
all: $(GLOBAL_DEBUG)
@if [ -n "$(PKG_PROFILES)" ]; then \
mkdir -p $(TARGET) && \
cp -at $(TARGET) -- \
$(addsuffix .directory,$(PKG_PROFILES)); \
mp-commit "$(TARGET)" "requested $(SUFFIX) copied over"; \
fi
debug:
@echo "** PKG_PROFILES: $(PKG_PROFILES)"