[4/4] core-updates: Ensure we have no temporary data in the package

Message ID 20200323193459.19522-4-michael.tremer@ipfire.org
State Accepted
Commit 70e7351c3e81dd2f3c3b5764fcf0be879cfaa36d
Headers
Series [1/4] cdrom: Cleanup everything after mastering |

Commit Message

Michael Tremer March 23, 2020, 7:34 p.m. UTC
  Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
---
 lfs/cdrom        | 3 ---
 lfs/core-updates | 2 +-
 lfs/flash-images | 2 +-
 3 files changed, 2 insertions(+), 5 deletions(-)
  

Patch

diff --git a/lfs/cdrom b/lfs/cdrom
index 175a5aedc..f18b80a03 100644
--- a/lfs/cdrom
+++ b/lfs/cdrom
@@ -255,9 +255,6 @@  endif
 	cd $(DIR_TMP)/cdrom && mkisofs $(ISO_ARGS) \
 		-o /install/images/$(SNAME)-$(VERSION).$(BUILD_ARCH)-full-core$(CORE).iso .
 
-	# Cleanup everything
-	rm -rf $(DIR_TMP)/cdrom
-
 ifeq "$(HAS_ISOLINUX)" "1"
 	isohybrid $(ISOHYBRID_ARGS) /install/images/$(SNAME)-$(VERSION).$(BUILD_ARCH)-full-core$(CORE).iso
 endif
diff --git a/lfs/core-updates b/lfs/core-updates
index fe4fb837c..e0dfa69f4 100644
--- a/lfs/core-updates
+++ b/lfs/core-updates
@@ -52,7 +52,7 @@  $(TARGET) : $(CORE)
 
 .PHONY:
 core/%:
-	rm -rf /install/packages/package
+	rm -rf /install/packages/package /tmp/*
 	mkdir -p /install/packages/package
 	eval $$(cat /usr/src/config/rootfiles/$@/meta)
 
diff --git a/lfs/flash-images b/lfs/flash-images
index 422acac22..5f39c488f 100644
--- a/lfs/flash-images
+++ b/lfs/flash-images
@@ -262,4 +262,4 @@  endif
 
 	# Compress Image
 	xz $(XZ_OPT) < $(IMG) > $(IMAGE_FILE)
-	rm -rf $(IMG) $(MNThdd)
+	rm -rf $(IMG) $(MNThdd) $(DIR_TMP)/cdrom