Do not rebuild container on make clean

This commit is contained in:
Wildan M 2025-11-10 14:00:51 +07:00
parent 154c7bf4bf
commit f80cd2413d
2 changed files with 21 additions and 17 deletions

View File

@ -28,26 +28,34 @@ rebuild:
rm -rf $(BUILD)/repo.tag $(BUILD)/harddrive.img $(BUILD)/redox-live.iso
$(MAKE) all
clean: $(CONTAINER_TAG)
clean:
ifeq ($(PODMAN_BUILD),1)
ifneq ("$(wildcard $(CONTAINER_TAG))","")
$(PODMAN_RUN) make $@
else
$(info will not run cookbook clean as container is not built)
endif
else
$(MAKE) c.--all
-rm -rf cookbook/repo
$(MAKE) fstools_clean
$(HOST_CARGO) clean --manifest-path relibc/Cargo.toml
endif
-$(FUMOUNT) $(BUILD)/filesystem/ || true
-$(FUMOUNT) /tmp/redox_installer/ || true
endif
rm -rf cookbook/repo
rm -rf relibc/target
rm -rf $(BUILD) $(PREFIX)
$(MAKE) fstools_clean
distclean: $(CONTAINER_TAG)
distclean:
ifeq ($(PODMAN_BUILD),1)
ifneq ("$(wildcard $(CONTAINER_TAG))","")
$(PODMAN_RUN) make $@
else
$(MAKE) u.--all
$(MAKE) clean
$(info will not run cookbook unfetch as container is not built)
endif
else
$(MAKE) u.--all
endif
$(MAKE) clean
pull:
git pull

View File

@ -25,14 +25,10 @@ else
touch $@
endif
fstools_clean: FORCE $(CONTAINER_TAG)
ifeq ($(PODMAN_BUILD),1)
$(PODMAN_RUN) make $@
else
$(HOST_CARGO) clean --manifest-path cookbook/Cargo.toml
$(HOST_CARGO) clean --manifest-path cookbook/pkgar/Cargo.toml
$(HOST_CARGO) clean --manifest-path installer/Cargo.toml
$(HOST_CARGO) clean --manifest-path redoxfs/Cargo.toml
fstools_clean: FORCE
rm -rf cookbook/target
rm -rf cookbook/pkgar/target
rm -rf installer/target
rm -rf redoxfs/target
rm -rf $(FSTOOLS)
rm -f $(FSTOOLS_TAG)
endif