Bug 3524

Summary: linux-yocto do_patch fails after setting an option with yocto-kernel config add
Product: [Build System, Metadata & Runtime] BSPs Reporter: Stefan Stanacar <sstncr>
Component: bsps-toolsAssignee: Tom Zanussi <tom.zanussi>
Status: VERIFIED NOTABUG QA Contact:
Severity: normal    
Priority: Medium CC: poky.bs.watcher, poky.watcher, sgw
Version: 1.4   
Target Milestone: 1.4   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---
Attachments:
Description Flags
logfile for do_patch
none
run do_patch
none
my test patch
none
myqemu layer as generated by yocto-bsp
none
logfile for do_patch none

Description Stefan Stanacar 2012-12-03 16:10:04 UTC
Created attachment 960 [details]
logfile for do_patch

Build Configuration:
BB_VERSION        = "1.17.0"
BUILD_SYS         = "x86_64-linux"
NATIVELSBSTRING   = "Ubuntu-12.04"
TARGET_SYS        = "x86_64-poky-linux"
MACHINE           = "qemux86-64"
DISTRO            = "poky"
DISTRO_VERSION    = "1.3+snapshot-20121203"
TUNE_FEATURES     = "m64"
TARGET_FPU        = ""
meta              
meta-yocto        
meta-yocto-bsp    = "master:247b6a3754c2c50318e2a73d79981ba0e9cb560b"
meta-myqemu       = "<unknown>:<unknown>"


Steps to reproduce:

 - yocto-bsp create myqemu qemu
 - modify your bblayers.conf and local.conf appropriately
 - bitbaking an image at this point will work
 - yocto-kernel patch add myqemu test.patch (see attached patch)
 - yocto-kernel config add myqemu CONFIG_MISC_DEVICES=y
 - yocto-kernel config add myqemu CONFIG_YOCTO_TESTMOD=y
 - bitbake core-image-minimal fails


| [INFO] validating against known patches  (qemux86-64-standard-meta)
/data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
/data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 716: cd_to_toplevel: command not found
| Context reduced to (1/1) to apply fragment at 384
| error: patch failed: drivers/misc/Makefile:36
| error: drivers/misc/Makefile: patch does not apply
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt-push: line 137: die: command not found
| [ERROR] unable to complete push
| pending patches are:
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
| ERROR: Function failed: do_patch (see /data/ubuntu/yocto/builds/yotta/tmp/work/qemux86_64-poky-linux/linux-yocto/3.4.18+git2+1c5980714d482f8ccb72909b40f3e1467a3fd590_1+f1c2320544eaffd6ecc7fcb8b18f8a0ed4ba2e14-r4.3.5/temp/log.do_patch.16196 for further information)
Comment 1 Stefan Stanacar 2012-12-03 16:10:25 UTC
Created attachment 961 [details]
run do_patch
Comment 2 Stefan Stanacar 2012-12-03 16:10:57 UTC
Created attachment 962 [details]
my test patch
Comment 3 Stefan Stanacar 2012-12-03 16:11:22 UTC
Created attachment 963 [details]
myqemu layer as generated by yocto-bsp
Comment 4 Stefan Stanacar 2012-12-03 16:19:38 UTC
The bitbake output in the first comment is actually wrong, sorry.

stefans@ubuntu12:/data/ubuntu/yocto/builds/yotta$ bitbake linux-yocto
Loading cache:  41% |########################################################################                                                                   Loading cache:  42% |#########################################################################                                                                  Loading cache:  43% |###########################################################################                                                                Loading cache:  44% |#############################################################################                                                              Loading cache:  45% |###############################################################################                                                            Loading cache:  46% |#################################################################################                                                          Loading cache:  47% |##################################################################################                                                         Loading cache:  48% |####################################################################################                                                       Loading cache:  49% |######################################################################################                                                     Loading cache:  50% |########################################################################################                                                   Loading cache: 100% |###########################################| ETA:  00:00:00
Loaded 1115 entries from dependency cache.

Build Configuration:
BB_VERSION        = "1.17.0"
BUILD_SYS         = "x86_64-linux"
NATIVELSBSTRING   = "Ubuntu-12.04"
TARGET_SYS        = "i586-poky-linux"
MACHINE           = "myqemu"
DISTRO            = "poky"
DISTRO_VERSION    = "1.3+snapshot-20121203"
TUNE_FEATURES     = "m32 i586"
TARGET_FPU        = ""
meta              
meta-yocto        
meta-yocto-bsp    = "master:247b6a3754c2c50318e2a73d79981ba0e9cb560b"
meta-myqemu       = "<unknown>:<unknown>"

Log data follows:
| DEBUG: Executing shell function do_patch
| Deleted branch meta-temp (was 580ac9c).



| [INFO] validating against known patches  (myqemu-standard-meta)
/data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 716: cd_to_toplevel: command not found
| Context reduced to (1/1) to apply fragment at 384
| error: patch failed: drivers/misc/Makefile:36
| error: drivers/misc/Makefile: patch does not apply
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt-push: line 137: die: command not found
| [ERROR] unable to complete push
| pending patches are:
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
| /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/guilt: line 29: /data/ubuntu/yocto/builds/yotta/tmp/sysroots/x86_64-linux/usr/bin/../libexec/git-core/git-sh-setup: No such file or directory
| links/files/test.patch
| ERROR. could not update git tree
| ERROR. Could not apply patches for myqemu.
|        Patch failures can be resolved in the devshell (bitbake -c devshell linux-yocto)
| ERROR: Function failed: do_patch (see /data/ubuntu/yocto/builds/yotta/tmp/work/myqemu-poky-linux/linux-yocto/3.4.18+git2+1c5980714d482f8ccb72909b40f3e1467a3fd590_1+f1c2320544eaffd6ecc7fcb8b18f8a0ed4ba2e14-r4.3.5/temp/log.do_patch.16980 for further information)
ERROR: Task 3 (/data/ubuntu/yocto/poky/meta/recipes-kernel/linux/linux-yocto_3.4.bb, do_patch) failed with exit code '1'
Comment 5 Stefan Stanacar 2012-12-03 16:21:03 UTC
Created attachment 964 [details]
logfile for do_patch
Comment 6 Tom Zanussi 2012-12-03 22:43:15 UTC
Could this be the same problem as the below?:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=2589
Comment 7 Stefan Stanacar 2012-12-04 10:13:01 UTC
Indeed, using the patch from the wiki it worked, my bad :).
Comment 8 Stefan Stanacar 2013-01-04 18:24:41 UTC
Marking as Verified.