Skip to contentSkip to conversation

gcc-6.1 and raspi

DISCUSSION Trevor Woerner 4 participants 9 messages Jun 4, 2016 – Jun 5, 2016

lore
Share & tools
lore
#0 lore raw

Has anyone tried building a raspi image lately from master?

ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0 do_compile: Function failed: do_compile

| In file included from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler.h:54:0,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/stddef.h:1,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/stddef.h:4,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/posix_types.h:4,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/types.h:13,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/types.h:5,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/mod_devicetable.h:11,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/scripts/mod/devicetable-offsets.c:2:
| /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler-gcc.h:121:30: fatal error: linux/compiler-gcc6.h: No such file or directory

#1 lore raw
Quoted 4 lines · Trevor Woerner

Has anyone tried building a raspi image lately from master?

ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0 do_compile: Function failed: do_compile

Quoted 9 lines

| In file included from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler.h:54:0,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/stddef.h:1,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/stddef.h:4,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/posix_types.h:4,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/types.h:13,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/types.h:5,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/mod_devicetable.h:11,
| from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/scripts/mod/devicetable-offsets.c:2:
| /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler-gcc.h:121:30: fatal error: linux/compiler-gcc6.h: No such file or directory

I can confirm this issue.

Regards,
Jonathan

#2 lore raw
Quoted 25 lines · On Sun, 5 Jun 2016 20:44:42 +1000 Jonathan Liu <[email protected]> wrote:
Quoted 15 lines · Trevor Woerner

Has anyone tried building a raspi image lately from master?

        ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0

do_compile: Function failed: do_compile

| In file included
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler.h:54:0, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/stddef.h:1, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/stddef.h:4, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/posix_types.h:4, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/uapi/linux/types.h:13,

Quoted 8 lines

|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/types.h:5, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/mod_devicetable.h:11, |
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/scripts/mod/devicetable-offsets.c:2:
| /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/include/linux/compiler-gcc.h:121:30:
fatal error: linux/compiler-gcc6.h: No such file or directory

Quoted 4 lines

I can confirm this issue.

Regards,
Jonathan

I can get a successful build with my kernel branch where I've merged the latest 4.1.y upstream stable release into the Raspberry Pi 4.1.y branch (https://gitlab.com/oryx/linux-oryx-rpi). I don't have the time to bisect this right now but one commit stands out as an obvious candidate for being the fix:

compiler-gcc: integrate the various compiler-gcc[345].h files
https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/?h=linux-4.1.y&id=f320793e52aee78f0fbb8bcaf10e6614d2e67bfc

I can also get a successful build using the recipe for the 4.4.y branch in meta-raspberrypi. The Raspberry Pi repository has moved over to the 4.4.y branch as the default, we should probably do the same in meta-raspberrypi.

Thanks,
Paul Barker

#3 lore raw

Hi,

I'm using kernel 4.4, and it does build properly with gcc 6.1. But the build does fail on other packages later on, so I ended up reverting to 5.3 for now.
I also think we should make 4.4 the default kernel version for meta-raspberrypi, to follow the raspberrypi repository. The fixes on 4.1 are far from what can be seen on 4.4 now (on the part that I'm involved with, vc4 on 4.1 is not functional, while it is on 4.4 and later). And it will only grow worse.

Herve

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Paul Barker
Sent: dimanche 5 juin 2016 13:22
To: Jonathan Liu <[email protected]>
Cc: Yocto Project <[email protected]>
Subject: Re: [yocto] gcc-6.1 and raspi

Quoted 28 lines · On Sun, 5 Jun 2016 20:44:42 +1000 Jonathan Liu <[email protected]> wrote:
Quoted 27 lines · Trevor Woerner

Has anyone tried building a raspi image lately from master?

        ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0

do_compile: Function failed: do_compile

| In file included
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/linux/compiler.h:54:0,
|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/uapi/linux/stddef.h:1,
|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/linux/stddef.h:4,
|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/uapi/linux/posix_types.h:4,
|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/uapi/linux/types.h:13,
|
from

Quoted 8 lines
Quoted 8 lines

/z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/linux/types.h:5,
|
from /z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-sour ce/include/linux/mod_devicetable.h:11,
|
from

/z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/scrip ts/mod/devicetable-offsets.c:2:

Quoted 1 line
Quoted 1 line

|

/z/layerindex-master/raspi2/tmp/work-shared/raspberrypi2/kernel-source/inclu de/linux/compiler-gcc.h:121:30:

Quoted 6 lines
Quoted 1 line

fatal error: linux/compiler-gcc6.h: No such file or directory

I can confirm this issue.

Regards,
Jonathan

I can get a successful build with my kernel branch where I've merged the latest 4.1.y upstream stable release into the Raspberry Pi 4.1.y branch
(https://gitlab.com/oryx/linux-oryx-rpi). I don't have the time to bisect this right now but one commit stands out as an obvious candidate for being the fix:

compiler-gcc: integrate the various compiler-gcc[345].h files
https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/
?h=linux-4.1.y&id=f320793e52aee78f0fbb8bcaf10e6614d2e67bfc

I can also get a successful build using the recipe for the 4.4.y branch in meta-raspberrypi. The Raspberry Pi repository has moved over to the 4.4.y branch as the default, we should probably do the same in meta-raspberrypi.

Thanks,
Paul Barker
--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

#4 lore raw
Quoted 3 lines · Herve Jourdain

I'm using kernel 4.4, and it does build properly with gcc 6.1. But the build does fail on other packages later on, so I ended up reverting to 5.3 for now.

Both the official meta-raspberrypi and Khem Raj's meta-raspberrypi layers have recipes for the 4.4% kernel. I tried them but I keep getting:

ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0 do_rpiboot_mkimage: Function failed: do_rpiboot_mkimage
Log data follows:
| DEBUG: Executing shell function do_rpiboot_mkimage
| Usage: mkknlimg [--dtok] [--283x] <vmlinux|zImage|bzImage> <outfile>
| WARNING: /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.1.21+gitAUTOINC+ff45bc0e89-r0/temp/run.do_rpiboot_mkimage.1254:1 exit 1 from '/z/layerindex-master/raspi2/tmp/sysroots/x86_64-linux/usr/bin/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}' | ERROR: Function failed: do_rpiboot_mkimage (log file is located at /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.1.21+gitAUTOINC+ff45bc0e89-r0/temp/log.do_rpiboot_mkimage.1254)

So I'm not sure what's going on there.

#5 lore raw

Re: ***SPAM*** Re: gcc-6.1 and raspi

Hi,

It seems like you are building the 4.1.21 kernel.
Did you set PREFERRED_VERSION_linux-raspberrypi = "4.4.%" in your distro.conf or local.conf?

Herve

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Trevor Woerner
Sent: dimanche 5 juin 2016 14:58
To: 'Yocto Project' <[email protected]>
Subject: ***SPAM*** Re: [yocto] gcc-6.1 and raspi

Quoted 3 lines · Herve Jourdain

I'm using kernel 4.4, and it does build properly with gcc 6.1. But the build does fail on other packages later on, so I ended up reverting to 5.3 for now.

Both the official meta-raspberrypi and Khem Raj's meta-raspberrypi layers have recipes for the 4.4% kernel. I tried them but I keep getting:

	ERROR: linux-raspberrypi-1_4.1.21+gitAUTOINC+ff45bc0e89-r0

do_rpiboot_mkimage: Function failed: do_rpiboot_mkimage
Log data follows:
| DEBUG: Executing shell function do_rpiboot_mkimage
| Usage: mkknlimg [--dtok] [--283x] <vmlinux|zImage|bzImage>
<outfile>
| WARNING:
/z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-r aspberrypi/1_4.1.21+gitAUTOINC+ff45bc0e89-r0/temp/run.do_rpiboot_mkimage.125 4:1 exit 1 from '/z/layerindex-master/raspi2/tmp/sysroots/x86_64-linux/usr/bin/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}'
| ERROR: Function failed: do_rpiboot_mkimage (log file is located at
/z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-r aspberrypi/1_4.1.21+gitAUTOINC+ff45bc0e89-r0/temp/log.do_rpiboot_mkimage.125
4)

So I'm not sure what's going on there.
--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

#6 lore raw
Quoted 3 lines · Herve Jourdain

It seems like you are building the 4.1.21 kernel.
Did you set PREFERRED_VERSION_linux-raspberrypi = "4.4.%" in your distro.conf or local.conf?

I was trying to save myself the time required to rebuild with the 4.4 kernel. I knew from my experiments that the result was the same for both, but here it is anyway:

ERROR: linux-raspberrypi-1_4.4.9+gitAUTOINC+3b440738b5-r0 do_rpiboot_mkimage: Function failed: do_rpiboot_mkimage
Log data follows:
| DEBUG: Executing shell function do_rpiboot_mkimage
| Usage: mkknlimg [--dtok] [--283x] <vmlinux|zImage|bzImage> <outfile>
| WARNING: /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/run.do_rpiboot_mkimage.18615:1 exit 1 from '/z/layerindex-master/raspi2/tmp/sysroots/x86_64-linux/usr/bin/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}' | ERROR: Function failed: do_rpiboot_mkimage (log file is located at /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/log.do_rpiboot_mkimage.18615)

#7 lore raw

Hi,

This one is a different issue, that was caused by a patch in oe 1 week ago.
I did send a patch to solve it last wednesday, I believe.
The root cause is KERNEL_OUTPUT has been removed from kernel.bbclass, but meta-raspberrypi uses it. This is the link to the patch:
http://article.gmane.org/gmane.linux.embedded.yocto.general/30093/

Herve

Quoted 17 lines · Trevor Woerner
Quoted 5 lines · Herve Jourdain

It seems like you are building the 4.1.21 kernel.
Did you set PREFERRED_VERSION_linux-raspberrypi = "4.4.%" in your distro.conf or local.conf?

I was trying to save myself the time required to rebuild with the 4.4 kernel. I knew from my experiments that the result was the same for both, but here it is anyway:

ERROR: linux-raspberrypi-1_4.4.9+gitAUTOINC+3b440738b5-r0 do_rpiboot_mkimage: Function failed: do_rpiboot_mkimage Log data follows:

   | DEBUG: Executing shell function do_rpiboot_mkimage
   | Usage: mkknlimg [--dtok] [--283x] <vmlinux|zImage|bzImage> <outfile>
   | WARNING: /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/run.do_rpiboot_mkimage.18615:1 exit 1 from '/z/layerindex-master/raspi2/tmp/sysroots/x86_64-linux/usr/bin/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}'
   | ERROR: Function failed: do_rpiboot_mkimage (log file is located at /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/log.do_rpiboot_mkimage.18615)
#8 lore raw
Quoted 7 lines · Herve Jourdain

Hi,

This one is a different issue, that was caused by a patch in oe 1 week ago.
I did send a patch to solve it last wednesday, I believe.
The root cause is KERNEL_OUTPUT has been removed from kernel.bbclass, but meta-raspberrypi uses it. This is the link to the patch:
http://article.gmane.org/gmane.linux.embedded.yocto.general/30093/

Thanks, the patch works great :-)

Quoted 20 lines

Herve

Quoted 17 lines · Trevor Woerner
Quoted 5 lines · Herve Jourdain

It seems like you are building the 4.1.21 kernel.
Did you set PREFERRED_VERSION_linux-raspberrypi = "4.4.%" in your distro.conf or local.conf?

I was trying to save myself the time required to rebuild with the 4.4 kernel. I knew from my experiments that the result was the same for both, but here it is anyway:

ERROR: linux-raspberrypi-1_4.4.9+gitAUTOINC+3b440738b5-r0 do_rpiboot_mkimage: Function failed: do_rpiboot_mkimage Log data follows:

   | DEBUG: Executing shell function do_rpiboot_mkimage
   | Usage: mkknlimg [--dtok] [--283x] <vmlinux|zImage|bzImage> <outfile>
   | WARNING: /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/run.do_rpiboot_mkimage.18615:1 exit 1 from '/z/layerindex-master/raspi2/tmp/sysroots/x86_64-linux/usr/bin/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}'
   | ERROR: Function failed: do_rpiboot_mkimage (log file is located at /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/linux-raspberrypi/1_4.4.9+gitAUTOINC+3b440738b5-r0/temp/log.do_rpiboot_mkimage.18615)