Bug 5461

Summary: Wrong value for size variable (table: Build_File)
Product: [Build System, Metadata & Runtime] Toaster Reporter: Andreea Brandusa Proca <andreea.b.proca>
Component: toasterAssignee: Alexandru Damian <alexandru.damian>
Status: VERIFIED NOTABUG QA Contact:
Severity: normal    
Priority: Undecided CC: alexandru.damian, belen.barros.pena
Version: unspecified   
Target Milestone: ---   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Andreea Brandusa Proca 2013-11-05 08:56:38 UTC
The value of the size variable is different from the value returned by os.path.getsize (or ls command).

e.g.:
in the database: {'path': u'/usr/include/asm-generic/ioctls.h', 'size': 3740}

os.path.getsize("/usr/include/asm-generic/ioctls.h")
3539

brandusa@andreea-Vostro-460:/usr/include/asm-generic$ ls -l
total 184
-rw-r--r-- 1 root root  3539 Sep 11 00:41 ioctls.h
Comment 1 Alexandru Damian 2013-11-05 15:27:02 UTC
The path in the database is related to the target filesystem, while you are testing with os.path.getsize() or ls -l a file on your host filesystem.

You need to test against $SYSROOT or target image file system.
Comment 2 Andreea Brandusa Proca 2013-11-06 07:37:57 UTC
Yes, you are right.