redox/mk/repo.mk

49 lines
1.3 KiB
Makefile
Raw Normal View History

2022-11-12 00:23:08 +01:00
$(BUILD)/fetch.tag: cookbook installer prefix $(FILESYSTEM_CONFIG) $(CONTAINER_TAG)
ifeq ($(PODMAN_BUILD),1)
$(PODMAN_RUN) $(MAKE) $@
else
2022-09-12 15:51:13 +02:00
$(HOST_CARGO) build --manifest-path cookbook/Cargo.toml --release
$(HOST_CARGO) build --manifest-path installer/Cargo.toml --release
PACKAGES="$$($(INSTALLER) --list-packages -c $(FILESYSTEM_CONFIG))" && \
cd cookbook && \
./fetch.sh "$${PACKAGES}"
mkdir -p $(BUILD)
touch $@
2022-11-12 00:23:08 +01:00
endif
2022-09-12 15:51:13 +02:00
2022-11-12 00:23:08 +01:00
$(BUILD)/repo.tag: $(BUILD)/fetch.tag $(CONTAINER_TAG)
ifeq ($(PODMAN_BUILD),1)
$(PODMAN_RUN) $(MAKE) $@
else
2022-09-12 15:51:13 +02:00
$(HOST_CARGO) build --manifest-path cookbook/Cargo.toml --release
$(HOST_CARGO) build --manifest-path installer/Cargo.toml --release
export PATH="$(PREFIX_PATH):$$PATH" && \
PACKAGES="$$($(INSTALLER) --list-packages -c $(FILESYSTEM_CONFIG))" && \
cd cookbook && \
./repo.sh "$${PACKAGES}"
mkdir -p $(BUILD)
2022-11-12 00:23:08 +01:00
# make sure fetch.tag is newer than the things repo modifies
touch $<
2022-09-12 15:51:13 +02:00
touch $@
2022-11-12 00:23:08 +01:00
endif
2022-12-17 04:22:44 +01:00
# Invoke clean.sh for a single target
c.%: FORCE
ifeq ($(PODMAN_BUILD),1)
$(PODMAN_RUN) $(MAKE) $@
else
export PATH="$(PREFIX_PATH):$$PATH" && \
cd cookbook && \
./clean.sh $*
endif
2022-12-17 04:22:44 +01:00
# Invoke repo.sh for a single target
r.%: FORCE
ifeq ($(PODMAN_BUILD),1)
$(PODMAN_RUN) $(MAKE) $@
else
export PATH="$(PREFIX_PATH):$$PATH" && \
cd cookbook && \
./repo.sh $*
endif