From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hamish Moffatt Date: Tue, 28 Oct 2008 12:04:42 +1100 Subject: [Buildroot] [PATCH] Avoid make distclean to remove packages fromrootfs In-Reply-To: References: <20081027204927.GF14184@mx.loc> Message-ID: <20081028010442.GA27610@cloud.net.au> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: buildroot@busybox.net On Mon, Oct 27, 2008 at 10:11:12PM +0100, Roberto A. Foglietta wrote: > clean remove a lot of things not only the stamps > > clean: $(TARGETS_CLEAN) > rm -rf $(STAGING_DIR) $(TARGET_DIR) $(IMAGE) > $(PROJECT_BUILD_DIR)/.root $(PROJECT_BUILD_DIR)/autotools-stamps > > a) you want reinstall things in root because they have been corrupted > without loosing your customization on scripts/configurations: You shouldn't edit anything in $(TARGET_DIR) yourself - edit the source, then rebuild. However, there does need to be a way to copy the target_skeleton over the root directory again in case you've edited files (startup scripts, passwd file, fstab etc). And you might not want to copy this over an existing $(TARGET_DIR), because then you might lose changes made by packages. I didn't understand your softclean and rootclean targets though. Here's what I have added to my own tree: root-clean: rm -rf $(PROJECT_BUILD_DIR)/.root $(PROJECT_BUILD_DIR)/autotools-stamps $(TARGET_DIR) Hamish -- Hamish Moffatt VK3SB