All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [Bug 14971] New: Kernel 3.10.108 fail to build in Buildroot 2022.08-rc1
@ 2022-08-18 22:29 bugzilla
  2023-01-04 13:10 ` [Buildroot] [Bug 14971] " bugzilla
  0 siblings, 1 reply; 2+ messages in thread
From: bugzilla @ 2022-08-18 22:29 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14971

            Bug ID: 14971
           Summary: Kernel 3.10.108 fail to build in Buildroot 2022.08-rc1
           Product: buildroot
           Version: unspecified
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
          Assignee: unassigned@buildroot.uclibc.org
          Reporter: ju.o@free.fr
                CC: buildroot@uclibc.org, yann.morin.1998@free.fr
  Target Milestone: ---

Hi,

During a linux-backports update, it was found that kernel v3.10.108 was failing
to compile in buildroot 2022.08-rc1. See:
https://lists.buildroot.org/pipermail/buildroot/2022-August/649507.html

As reported by Yann, this was likely introduced by:
https://git.buildroot.org/buildroot/commit/?id=9b41b54be07711c10ad13ce157be272ed1cf402e

The issue can be reproduced with:

    make qemu_aarch64_virt_defconfig
    utils/config \
      --set-str LINUX_KERNEL_CUSTOM_VERSION_VALUE 3.10.108 \
      -e PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_10 \
      -d PACKAGE_HOST_LINUX_HEADERS_CUSTOM_5_15
    make olddefconfig
    make linux

After some analysis, it appears that in 3.10.108, bison does not generate the
declaration 'YYLTYPE yylloc', which is also removed by the Buildroot commit
9b41b54b.  We end up with no declaration at all.  Those declaration are emitted
with the dtc-parser.y contains the '%locations' directive.

In the kernel, dtc was updated to v1.5.1-22-gc40aeb60b47a in:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=0cec114e36606412908a35695a5db944cec2e3db

This commit is included in kernel v5.6.

This dtc update include the dtc commit:
https://git.kernel.org/pub/scm/utils/dtc/dtc.git/commit/?id=7150286225476345bd6e7312331e3baf4d621c32

which adds the '%locations' directive.

I'm able to workaround the failure by adding in linux/linux.mk:

define LINUX_ADD_DTC_LOCATIONS
  if test -e $(@D)/scripts/dtc/dtc-parser.y && \
      ! grep -Eq '^%locations$$' $(@D)/scripts/dtc/dtc-parser.y ; then \
    $(SED) '/^%{$$/i %locations' $(@D)/scripts/dtc/dtc-parser.y; \
  fi
endef
LINUX_POST_PATCH_HOOKS += LINUX_ADD_DTC_LOCATIONS

and add REGENERATE_PARSERS=1 into LINUX_MAKE_FLAGS. This basically adds the
missing directive, if not found.

Before sending a patch, I created this bug to log my findings and collect few
comments, if this is a good approach.  Any suggestions?

Thanks!

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Buildroot] [Bug 14971] Kernel 3.10.108 fail to build in Buildroot 2022.08-rc1
  2022-08-18 22:29 [Buildroot] [Bug 14971] New: Kernel 3.10.108 fail to build in Buildroot 2022.08-rc1 bugzilla
@ 2023-01-04 13:10 ` bugzilla
  0 siblings, 0 replies; 2+ messages in thread
From: bugzilla @ 2023-01-04 13:10 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14971

Peter Korsgaard <jacmet@uclibc.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|NEW                         |RESOLVED

--- Comment #1 from Peter Korsgaard <jacmet@uclibc.org> ---
Fixed (by yourself) by
https://gitlab.com/buildroot.org/buildroot/-/commit/e75f3962084045cf50f38f0adf8bfaa8da71dfd5,
thanks!

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-01-04 13:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-18 22:29 [Buildroot] [Bug 14971] New: Kernel 3.10.108 fail to build in Buildroot 2022.08-rc1 bugzilla
2023-01-04 13:10 ` [Buildroot] [Bug 14971] " bugzilla

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.