[OE-core] What is expected of a kernel recipe nowadays?

Martin Jansa martin.jansa at gmail.com
Tue Jan 6 08:57:31 UTC 2015


On Tue, Jan 06, 2015 at 08:14:33AM +0100, Mike Looijmans wrote:
> On 01/05/2015 09:18 PM, Bruce Ashfield wrote:
> > On Mon, Jan 5, 2015 at 3:29 AM, Mike Looijmans <mike.looijmans at topic.nl> wrote:
> >> I think I found it. The kernel bbclass changes "S" to point elsewhere.
> >> Moving the statement
> >> S = "${WORKDIR}/git"
> >> to after the "inherit kernel" line makes the compile run again.
> >
> >
> > Interesting. Can you confirm that Richard's commit:
> >
> > -----------------
> >
> > commit 1dd37a2a9960ad26e27567d1871d78bec336e1a2
> > Author: Richard Purdie <richard.purdie at linuxfoundation.org>
> > Date:   Fri Dec 19 17:46:27 2014 +0000
> >
> >      kernel: Fix non linux-yocto builds
> >
> >      After the recent kernel changes, non linux-yocto builds stopped working
> >      properly for two reasons:
> >
> >      a) ${S} was being reset to ${WORKDIR}/git for example and STAGING_KERNEL_DIR
> >         did not contain the source
> >
> >      b) Most builds were using ${B} == ${S}
> >
> >      This patch adds a fixup to the unpack function to handle the case where
> >      ${S} != ${STAGING_KERNEL_DIR} and also set up the infrastrcture so that
> >      B != S for kernel builds from now on. The kernel build system is one of the
> >      best for supporting this and there is no good reason not to take advantage
> >      of it.
> >
> >      (From OE-Core rev: 106dab2fd0321e6b4e77b40111e59a3a31d329d4)
> >
> >      Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
> >
> > ------------
> >
> > Is in your tree ? it should be fixing things up and allowing the source to
> > be found.
> 
> Yes, this is the part that changes "S" and it's how I discovered to move the 
> assignment to after inheriting it.
> 
> 
> > Alternatively, if you drop the explicit set of S, does the build start working
> > again ?
> 
> If I just remove the S=... line, it fails in the same way. The git fetch 
> apparently places the code at WORKDIR/git where the new kernel recipe cannot 
> find it.

FWIW: I'm also seeing various kernel failures since the changes.

Most my kernel are also using linux.inc from meta-oe which wasn't updated yet
(I plan to look into it soon, unless someone else beats me to it)

The worst part is that some of these issues are random (the race-condition showing
more often than before).

1) do_unpack failing:

ERROR: Error executing a python function in /home/jenkins/workspace/luneos-unstable/webos-ports/meta-smartphone/meta-samsung/recipes-kernel/linux/linux-samsung-tuna_git.bb:

The stack trace of python calls that resulted in this exception/failure was:
File: 'base_do_unpack', lineno: 24, function: <module>
     0020:        subprocess.call(d.expand("mv /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/maguro-webos-linux-gnueabi/linux-samsung-tuna/3_3.0.72+gitrAUTOINC+f8ed73f94a-r12/git/ /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/sysroots/maguro/usr/src/kernel"), shell=True)
     0021:        os.symlink(kernsrc, s)
     0022:
     0023:
 *** 0024:base_do_unpack(d)
     0025:
File: 'base_do_unpack', lineno: 21, function: base_do_unpack
     0017:        bb.utils.mkdirhier(kernsrc)
     0018:        bb.utils.remove(kernsrc, recurse=True)
     0019:        import subprocess
     0020:        subprocess.call(d.expand("mv /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/maguro-webos-linux-gnueabi/linux-samsung-tuna/3_3.0.72+gitrAUTOINC+f8ed73f94a-r12/git/ /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/sysroots/maguro/usr/src/kernel"), shell=True)
 *** 0021:        os.symlink(kernsrc, s)
     0022:
     0023:
     0024:base_do_unpack(d)
     0025:
Exception: OSError: [Errno 2] No such file or directory

ERROR: Function failed: base_do_unpack
ERROR: Logfile of failure stored in: /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/maguro-webos-linux-gnueabi/linux-samsung-tuna/3_3.0.72+gitrAUTOINC+f8ed73f94a-r12/temp/log.do_unpack.13495

2) do_configure failing:

ERROR: Function failed: do_configure (log file is located at /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/mako-webos-linux-gnueabi/linux-lg-mako/3.4.0+gitrAUTOINC+38bdbfe224-r0/temp/log.do_configure.17498)
ERROR: Logfile of failure stored in: /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/mako-webos-linux-gnueabi/linux-lg-mako/3.4.0+gitrAUTOINC+38bdbfe224-r0/temp/log.do_configure.17498
Log data follows:
| DEBUG: Executing python function sysroot_cleansstate
| DEBUG: Python function sysroot_cleansstate finished
| DEBUG: Executing shell function do_configure
| NOTE: make oldconfig
| make: *** No rule to make target `oldconfig'.  Stop.
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_configure (log file is located at /home/jenkins/workspace/luneos-unstable/webos-ports/tmp-glibc/work/mako-webos-linux-gnueabi/linux-lg-mako/3.4.0+gitrAUTOINC+38bdbfe224-r0/temp/log.do_configure.17498)
NOTE: recipe linux-lg-mako-3.4.0+gitrAUTOINC+38bdbfe224-r0: task do_configure: Failed
ERROR: Task 491 (/home/jenkins/workspace/luneos-unstable/webos-ports/meta-smartphone/meta-lg/recipes-kernel/linux/linux-lg-mako_git.bb, do_configure) failed with exit code '1'

3) do_patch failing when S assignment is dropped

ERROR: Command Error: exit status: 1  Output:
Applying patch patch-3.2.52
can't find file to patch at input line 5
...
8 out of 8 hunks ignored
Patch patch-3.2.52 does not apply (enforce with -f)
ERROR: Function failed: patch_do_patch
ERROR: Logfile of failure stored in: /OE/build/shr-core/tmp-glibc/work/om_gta02-oe-linux-gnueabi/linux-openmoko/1_3.2-r14/temp/log.do_patch.15984
NOTE: recipe linux-openmoko-1_3.2-r14: task do_patch: Failed

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20150106/5c17606c/attachment-0002.sig>


More information about the Openembedded-core mailing list