Skip to contentSkip to conversation

New: kmod and gcc-14 build error

Buildroot [email protected] 1 participant 4 messages Jun 4, 2024

lore
Share & tools
lore
#0 lore raw

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

Bug ID: 16093
Summary: kmod and gcc-14 build error
Product: buildroot
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: P5
Component: Other
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Target Milestone: ---

Trying out 2024.05-rc1 ran into this issue when using gcc-14. Minimum defconfig below. I saw a patch in patchwork, but it wasn't gcc-14 related and didn't work here when applying it.

libkmod/libkmod-config.c: In function 'conf_files_insert_sorted':
libkmod/libkmod-config.c:797:24: error: implicit declaration of function 'basename' [-Wimplicit-function-declaration]

  797 |                 name = basename(path);
      |                        ^~~~~~~~

libkmod/libkmod-config.c:797:24: warning: nested extern declaration of 'basename' [-Wnested-externs]
libkmod/libkmod-config.c:797:22: error: assignment to 'const char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
797 | name = basename(path);
| ^
make[3]: *** [Makefile:1771: libkmod/libkmod-config.lo] Error 1 make[3]: *** Waiting for unfinished jobs....
shared/util.c: In function 'path_to_modname':
shared/util.c:177:19: error: implicit declaration of function 'basename' [-Wimplicit-function-declaration]

  177 |         modname = basename(path);
      |                   ^~~~~~~~

shared/util.c:177:19: warning: nested extern declaration of 'basename' [-Wnested-externs]
shared/util.c:177:17: error: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
177 | modname = basename(path);

BR2_x86_64=y
BR2_TOOLCHAIN_BUILDROOT_MUSL=y
BR2_KERNEL_HEADERS_6_6=y
BR2_BINUTILS_VERSION_2_42_X=y
BR2_GCC_VERSION_14_X=y
BR2_PACKAGE_KMOD=y

Signature · 6 lines
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw

[Buildroot] [Bug 16093] kmod and gcc-14 build error

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

--- Comment #1 from Fiona Klute <[email protected]> ---
I believe that is the same kmod/musl issue that caused a segfault (after "only" warnings during build) with GCC 13. I sent a patch based on an upstream PR in April, unfortunately it hasn't been merged yet. Good thing they upgraded that to an error in GCC.
https://patchwork.ozlabs.org/project/buildroot/patch/[email protected]/

Signature · 6 lines
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#2 lore raw

[Buildroot] [Bug 16093] kmod and gcc-14 build error

In reply to [email protected]

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

Yann E. MORIN <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

         Resolution|---                         |FIXED
                 CC|                            |[email protected]
             Status|NEW                         |RESOLVED

--- Comment #2 from Yann E. MORIN <[email protected]> --- Lance, All,

Thanks for the report.

We believe this issue is now fixed now we applied Fiona's patch:

https://gitlab.com/buildroot.org/buildroot/-/commit/05617724ee2b5db9a1a6bb07272915ef3c1fd535

If the issue still happens, please re-open and provide more details.

Regards,
Yann E. MORIN.

Signature · 6 lines
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#3 lore raw

[Buildroot] [Bug 16093] kmod and gcc-14 build error

In reply to [email protected]

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

--- Comment #3 from Lance Fredrickson <[email protected]> --- Working good for me, I realized I originally applied the patch incorrectly. Thanks for the quick turnaround!

Signature · 6 lines
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot