Bug 4314 - libcap do_patch fails for archive work directory and export source package with 'tar'
Summary: libcap do_patch fails for archive work directory and export source package wi...
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 1.4
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.4 M6
Assignee: Saul Wold
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2013-04-16 12:33 UTC by Stoicescu Cornel
Modified: 2013-04-29 15:15 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: ---


Attachments
libcap do_patch log (15.38 KB, application/octet-stream)
2013-04-16 12:33 UTC, Stoicescu Cornel
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stoicescu Cornel 2013-04-16 12:33:16 UTC
Created attachment 1175 [details]
libcap do_patch log

STATUS: FAILED
BUILD: dylan:dab237bc6a7679dfeaa981c14736aedc7b04ecb9
ENVIRONMENT: Ubuntu 12.04 X86_64
STEPS TO REPRODUCE: 
1. Download poky source
2. Add following line to meta/classes/package_rpm.bbclass :
inherit archive-original-source
3. Prepare the build environment and add the lines to the conf/local.conf:

INHERIT += "archive-original-source"

SOURCE_ARCHIVE_PACKAGE_TYPE ?= 'srpm' 
SOURCE_ARCHIVE_LOG_WITH_SCRIPTS ?= 'logs_with_scripts'
4. Run "bitbake core-image-sato". 
5. Change the following lines in conf/local.conf:

INHERIT += "archive-original-source"
SOURCE_ARCHIVE_PACKAGE_TYPE ?= 'tar' 
SOURCE_ARCHIVE_LOG_WITH_SCRIPTS ?= 'logs'
Run “bitbake core-image-sato” again.

Notice error (see attached log)

Note: this was performed with clean a build directory
Comment 1 Saul Wold 2013-04-24 14:07:12 UTC
Changing the ARCHIVER options seems to trigger do_patch(), my guess is the checksum of something within the archive_original_source_patches changes 
and since do_archive_original_source_patches() is "after do_unpack" the do_patch() need to run again since it does not know if anything has changed.

 ../../poky/bitbake/bin/bitbake-diffsigs tmp/stamps/x86_64-poky-linux/libpcap/1.3.0-r5.0.do_patch.sigdata.db8a1275445e0e4688bb0e702e3b1515 tmp/stamps/x86_64-poky-linux/libpcap/1.3.0-r5.0.do_patch.sigdata.0dee149942eb466c051506c4d613d2b5
Dependency on task libpcap_1.3.0.bb.do_archive_original_sources_patches was added with hash 447b549d8e80c275ccc9274e2f522c48
Comment 3 Saul Wold 2013-04-29 15:15:21 UTC
Digging into this deeper found 2 issues I think, first one was that the patches for libpcap including patching the configure file which is really not correct since this file gets re-written during the autoconf process and then when the stamps changed a second patch attempted to patch the autoconf'ed version!

The second issue is that adding the archiver bits should not alter the stamps, since nothing changes in the source or configuration, the archiver is simply archiving bits at various stages, it's a read-only process.  I think that those tasks need to be marked as non-dependent tasks some how