Patchwork [4/4] rootfs_ipk.bbclass: Don't duplicate remove_packaging_data_files code

login
register
mail settings
Submitter Andrei Gherzan
Date Oct. 20, 2012, 9:44 p.m.
Message ID <dce705cf201278411e230dd004688af5f3a8e7f1.1350769062.git.andrei@gherzan.ro>
Download mbox | patch
Permalink /patch/38359/
State New
Headers show

Comments

Andrei Gherzan - Oct. 20, 2012, 9:44 p.m.
While removing packaging data files in rootfs_ipk_do_rootfs use the
remove_packaging_data_files function. By using this function we ensure
that /var/lib/opkg directory is created. opkg needs this directory to
create lock files.
Some extra spaces / tabs were removed / formated.

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
---
 meta/classes/rootfs_ipk.bbclass |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
Otavio Salvador - Oct. 21, 2012, 12:36 p.m.
On Sat, Oct 20, 2012 at 6:44 PM, Andrei Gherzan <andrei@gherzan.ro> wrote:
> While removing packaging data files in rootfs_ipk_do_rootfs use the
> remove_packaging_data_files function. By using this function we ensure
> that /var/lib/opkg directory is created. opkg needs this directory to
> create lock files.
> Some extra spaces / tabs were removed / formated.
>
> Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>

I'd prefer if you could split the formating changes to another patch.

Patch

diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass
index 9d716fb..f69cc0e 100644
--- a/meta/classes/rootfs_ipk.bbclass
+++ b/meta/classes/rootfs_ipk.bbclass
@@ -111,11 +111,11 @@  fakeroot rootfs_ipk_do_rootfs () {
 			fi
 
 			# Also delete the status files
-			rm -rf ${IMAGE_ROOTFS}${opkglibdir}
+			remove_packaging_data_files
 		fi
 	fi
 	set +x
-	log_check rootfs 	
+	log_check rootfs
 }
 
 rootfs_ipk_write_manifest() {
@@ -134,8 +134,8 @@  rootfs_ipk_write_manifest() {
 
 remove_packaging_data_files() {
 	rm -rf ${IMAGE_ROOTFS}${opkglibdir}
-        # We need the directory for the package manager lock
-        mkdir ${IMAGE_ROOTFS}${opkglibdir}
+	# We need the directory for the package manager lock
+	mkdir ${IMAGE_ROOTFS}${opkglibdir}
 }
 
 list_installed_packages() {