AW: AW: AW: Issue with tar (Busybox 1.20.2): unknown file type

dietmar.schindler at manroland-web.com dietmar.schindler at manroland-web.com
Mon Jun 24 08:31:02 UTC 2013


> Von: piquemal michel [mailto:michel_piquemal at yahoo.fr]
> Gesendet: Sonntag, 23. Juni 2013 09:40
> ...
> Did add printf (bb_error_msg) in libbb/recursive_action.c:recursive_action(), after
> status = (follow ? stat : lstat)(fileName, &statbuf)
>
> bb_error_msg("status=%d flags=%x  statbuf.st_ino=%d statbuf.st_mode=%d", status, flags,
> statbuf.st_ino, statbuf.st_mode);
>
> and compiled 2 versions: one static (that works), and one dynamic.
>
>
> I tryied to tar tst directory (which contains 2 files) with the 2 compiled versions:
>
> # busybox_stat tar -cf toto.tar tst
> tar: status=0 flags=1  statbuf.st_ino=838 statbuf.st_mode=16877
> tar: status=0 flags=1  statbuf.st_ino=861 statbuf.st_mode=33188
> tar: status=0 flags=1  statbuf.st_ino=857 statbuf.st_mode=33188
>
> # busybox_dyn tar -cf toto.tar tst
>
> tar: status=0 flags=1  statbuf.st_ino=0 statbuf.st_mode=838
> tar: tst: unknown file type
> tar: error exit delayed from previous errors

Apparently there is a mismatch between the expected and the effective layout of "struct stat". Are you sure that when compiling busybox, the same (or a compatible) definition of "struct stat" was used as in the target library? You could also print "sizeof statbuf.st_ino" and "offsetof(struct stat, st_mode)" or a dump of the bytes in "statbuf". Or you could try if changing the option CONFIG_LFS makes any difference.
Another approach: You wrote that the dynamic busybox works on your aboriginal system image; you could copy the shared object from there to your target.
________________________________________
manroland web systems GmbH -- Managing Director: Eckhard Hoerner-Marass
Registered Office: Augsburg -- Trade Register: AG Augsburg -- HRB-No. 26816 -- VAT: DE281389840

Confidentiality note:
This eMail and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you are not the intended recipient, you are hereby notified that any use or dissemination of this communication is strictly prohibited. If you have received this eMail in error, then please delete this eMail.

! Please consider your environmental responsibility before printing this eMail
________________________________________


More information about the busybox mailing list