Bug 495

Summary: "tar xf" in target can't extract sudoku-savant-1.3.tar
Product: [Build System, Metadata & Runtime] Meta-yocto Reporter: Dexuan Cui <dexuan.cui>
Component: meta-yoctoAssignee: Dexuan Cui <dexuan.cui>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: Medium CC: jessica.zhang, kevin.tian, poky.bs.watcher, poky.watcher, richard.purdie, sgw
Version: 0.9   
Target Milestone: 1.0 M1   
Hardware: All   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Program Management Documentation change: ---
Attachments:
Description Flags
sudoku-savant-1.3.tar.bz2: use "bunzip sudoku-savant-1.3.tar.bz2" to get "sudoku-savant-1.3.tar" none

Description Dexuan Cui 2010-10-19 22:12:11 UTC
In targets(like qemux86, or atom-pc), running "tar -xf sudoku-savant-1.3.tar" would get a "tar: invalid tar magic" error:

root@qemux86:~ # tar -xf sudoku-savant-1.3.tar
tar: invalid tar magic
root@qemux86:~ #

I happened to find this issue when I tried to build some test suites inside the target. BTW: in host, "tar -xf sudoku-savant-1.3.tar" runs ok.

This bug also exists in the RC3 images and should be a long-standing bug.
I'll attach the file sudoku-savant-1.3.tar.
Comment 1 Dexuan Cui 2010-10-19 22:16:39 UTC
Created attachment 60 [details]
sudoku-savant-1.3.tar.bz2: use "bunzip sudoku-savant-1.3.tar.bz2" to get "sudoku-savant-1.3.tar"
Comment 2 Dexuan Cui 2010-10-26 00:17:10 UTC
It's busybox's tar that has the issue.

I made the below patch to enable more options to fix the bug.

diff --git a/meta/recipes-core/busybox/busybox-1.16.2/defconfig b/meta/recipes-core/busybox/busybox-1.16.2/defconfig
index 431da94..87e6244 100644
--- a/meta/recipes-core/busybox/busybox-1.16.2/defconfig
+++ b/meta/recipes-core/busybox/busybox-1.16.2/defconfig
@@ -1,7 +1,7 @@
 #
 # Automatically generated make config: don't edit
 # Busybox version: 1.16.2
-# Tue Jul  6 14:52:48 2010
+# Tue Oct 26 15:07:52 2010
 #
 CONFIG_HAVE_DOT_CONFIG=y

@@ -105,10 +105,10 @@ CONFIG_FEATURE_HWIB=y
 #
 # Archival Utilities
 #
-# CONFIG_FEATURE_SEAMLESS_LZMA is not set
-# CONFIG_FEATURE_SEAMLESS_BZ2 is not set
-# CONFIG_FEATURE_SEAMLESS_GZ is not set
-# CONFIG_FEATURE_SEAMLESS_Z is not set
+CONFIG_FEATURE_SEAMLESS_LZMA=y
+CONFIG_FEATURE_SEAMLESS_BZ2=y
+CONFIG_FEATURE_SEAMLESS_GZ=y
+CONFIG_FEATURE_SEAMLESS_Z=y
 CONFIG_AR=y
 # CONFIG_FEATURE_AR_LONG_FILENAMES is not set
 CONFIG_BUNZIP2=y
@@ -128,9 +128,9 @@ CONFIG_GZIP=y
 # CONFIG_RPM is not set
 CONFIG_TAR=y
 CONFIG_FEATURE_TAR_CREATE=y
-# CONFIG_FEATURE_TAR_AUTODETECT is not set
+CONFIG_FEATURE_TAR_AUTODETECT=y
 CONFIG_FEATURE_TAR_FROM=y
-# CONFIG_FEATURE_TAR_OLDGNU_COMPATIBILITY is not set
+CONFIG_FEATURE_TAR_OLDGNU_COMPATIBILITY=y
 # CONFIG_FEATURE_TAR_OLDSUN_COMPATIBILITY is not set
 CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y
 # CONFIG_FEATURE_TAR_LONG_OPTIONS is not set
Comment 4 Dexuan Cui 2010-11-14 21:01:24 UTC
tar -jxf sudoku-savant-1.3.tar.bz2 can work normally in qemu target.
Let me VERIFY the bug.