use lbzip2 to unpack the stages
authorRick Farina (Zero_Chaos) <zerochaos@gentoo.org>
Mon, 27 May 2013 20:13:28 +0000 (16:13 -0400)
committerRick Farina (Zero_Chaos) <zerochaos@gentoo.org>
Mon, 27 May 2013 20:13:28 +0000 (16:13 -0400)
Since we already use lbzip2 to compress everthing,
it makes a significant performance difference to
also unpack the stages using lbzip2.  When the stage
compression is selectable this should be enhanced to use
other decompressors as well (although xz doesn't seem to
need a multi-threaded decompressor).

modules/generic_stage_target.py

index 31cb025e6745a3858acacdf583d6df7dbaaf330c..a9cc68ec66ca716acb71197d7780c8867a01f0a2 100644 (file)
@@ -657,7 +657,7 @@ class generic_stage_target(generic_target):
                                        unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                                self.settings["chroot_path"]
                                else:
                                        unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                                self.settings["chroot_path"]
                                else:
-                                       unpack_cmd="tar xpf "+self.settings["source_path"]+" -C "+\
+                                       unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                                self.settings["chroot_path"]
                                error_msg="Tarball extraction of "+\
                                        self.settings["source_path"]+" to "+\
                                                self.settings["chroot_path"]
                                error_msg="Tarball extraction of "+\
                                        self.settings["source_path"]+" to "+\
@@ -672,7 +672,7 @@ class generic_stage_target(generic_target):
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                        self.settings["chroot_path"]
                        else:
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                        self.settings["chroot_path"]
                        else:
-                               unpack_cmd="tar xpf "+self.settings["source_path"]+" -C "+\
+                               unpack_cmd="tar -I lbzip2 -xpf "+self.settings["source_path"]+" -C "+\
                                        self.settings["chroot_path"]
                        error_msg="Tarball extraction of "+self.settings["source_path"]+\
                                " to "+self.settings["chroot_path"]+" failed."
                                        self.settings["chroot_path"]
                        error_msg="Tarball extraction of "+self.settings["source_path"]+\
                                " to "+self.settings["chroot_path"]+" failed."
@@ -773,7 +773,7 @@ class generic_stage_target(generic_target):
                        if "bz2" == self.settings["chroot_path"][-3:]:
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+destdir
                        else:
                        if "bz2" == self.settings["chroot_path"][-3:]:
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+destdir
                        else:
-                               unpack_cmd="tar xpf "+self.settings["snapshot_path"]+" -C "+destdir
+                               unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+destdir
                        unpack_errmsg="Error unpacking snapshot"
                        cleanup_msg="Cleaning up invalid snapshot cache at \n\t"+\
                                self.settings["snapshot_cache_path"]+\
                        unpack_errmsg="Error unpacking snapshot"
                        cleanup_msg="Cleaning up invalid snapshot cache at \n\t"+\
                                self.settings["snapshot_cache_path"]+\
@@ -793,7 +793,7 @@ class generic_stage_target(generic_target):
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+\
                                        self.settings["chroot_path"]+"/usr"
                        else:
                                unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+\
                                        self.settings["chroot_path"]+"/usr"
                        else:
-                               unpack_cmd="tar xpf "+self.settings["snapshot_path"]+" -C "+\
+                               unpack_cmd="tar -I lbzip2 -xpf "+self.settings["snapshot_path"]+" -C "+\
                                        self.settings["chroot_path"]+"/usr"
                        unpack_errmsg="Error unpacking snapshot"
 
                                        self.settings["chroot_path"]+"/usr"
                        unpack_errmsg="Error unpacking snapshot"