Skip to contentSkip to conversation

package/rpi-userland: fix build with GCC 15.x

PATCH Applied Thomas Petazzoni via buildroot 1 participant 2 messages Aug 23, 2025 – Aug 24, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/rpi-userland: fix build with GCC 15.x

The following defconfig:

BR2_arm=y
BR2_cortex_a9=y
BR2_ARM_ENABLE_VFP=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_INIT_NONE=y
BR2_SYSTEM_BIN_SH_NONE=y
# BR2_PACKAGE_BUSYBOX is not set
BR2_PACKAGE_RPI_USERLAND=y
# BR2_TARGET_ROOTFS_TAR is not set

will fail to build due to two issues in various part of rpi-userland making GCC 15.x unhappy.

Patch 0008-Fix-conflicting-types-build-error.patch is taken from a pull request already submitted by a contributor to the upstream project.

Patch 0009-Fix-raspicommonsettings_parse_cmdline.patch is backported from upstream, and can be dropped next time we bump rpi-userland.

Note that there are no autobuilder failures for this issue.

---
 ...08-Fix-conflicting-types-build-error.patch | 41 +++++++++++++++++++
 ...ix-raspicommonsettings_parse_cmdline.patch | 28 +++++++++++++
 2 files changed, 69 insertions(+)
 create mode 100644 package/rpi-userland/0008-Fix-conflicting-types-build-error.patch
 create mode 100644 package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch
package/rpi-userland/0008-Fix-conflicting-types-build-error.patch new file +41 -0
new file mode 100644
index 0000000000..349ef2027e
@@ -0,0 +1,41 @@
+From c2337c83c627dd94f9b673361dca6ffafca7f59b Mon Sep 17 00:00:00 2001
+From: Jonas Kvinge <[email protected]>
+Date: Sun, 6 Jul 2025 20:21:00 +0200
+Subject: [PATCH] Fix conflicting types build error
+
+Upstream: https://github.com/raspberrypi/userland/pull/744
+Signed-off-by: Thomas Petazzoni <[email protected]>
+---
+ interface/vchiq_arm/vchiq_lib.c       | 2 +-
+ interface/vmcs_host/vc_vchi_gpuserv.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/interface/vchiq_arm/vchiq_lib.c b/interface/vchiq_arm/vchiq_lib.c
+index 133d5ca..7a2dae5 100755
+--- a/interface/vchiq_arm/vchiq_lib.c
++++ b/interface/vchiq_arm/vchiq_lib.c
+@@ -537,7 +537,7 @@ vchiq_bulk_receive_handle(VCHIQ_SERVICE_HANDLE_T handle,
+    int size,
+    void *userdata,
+    VCHIQ_BULK_MODE_T mode,
+-   int (*copy_pagelist)())
++   int (*copy_pagelist)(char *vcptr, const struct pagelist_struct *pagelist))
+ {
+    VCHIQ_SERVICE_T *service = find_service_by_handle(handle);
+    VCHIQ_QUEUE_BULK_TRANSFER_T args;
+diff --git a/interface/vmcs_host/vc_vchi_gpuserv.h b/interface/vmcs_host/vc_vchi_gpuserv.h
+index fc0bfee..ce6cb58 100755
+--- a/interface/vmcs_host/vc_vchi_gpuserv.h
++++ b/interface/vmcs_host/vc_vchi_gpuserv.h
+@@ -58,7 +58,7 @@ struct sync_job_s {
+ 
+ struct gpu_callback_s {
+   // callback to call when complete (can be NULL)
+-  void (*func)();
++  void (*func)(void*);
+   void *cookie;
+ };
+ 
+-- 
+2.50.1
+
package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch new file +28 -0
new file mode 100644
index 0000000000..df11d591fc
@@ -0,0 +1,28 @@
+From cf6d0ac0d31fcc2e64c83b8105b078e792f2d441 Mon Sep 17 00:00:00 2001
+From: Krawlow <[email protected]>
+Date: Wed, 23 Mar 2022 16:46:18 +0100
+Subject: [PATCH] Fix raspicommonsettings_parse_cmdline
+
+Fix raspicommonsettings_parse_cmdline's definition to match declaration
+
+Upstream: c4fd1b8986c6d6d4ae5cd51e65a8bbeb495dfa4e
+Signed-off-by: Thomas Petazzoni <[email protected]>
+---
+ host_applications/linux/apps/raspicam/RaspiCommonSettings.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
+index 75b2937..2e9de7d 100644
+--- a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
++++ b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
+@@ -54,6 +54,6 @@ typedef struct
+ void raspicommonsettings_set_defaults(RASPICOMMONSETTINGS_PARAMETERS *);
+ void raspicommonsettings_dump_parameters(RASPICOMMONSETTINGS_PARAMETERS *);
+ void raspicommonsettings_display_help();
+-int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)());
++int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)(char*));
+ 
+ #endif
+-- 
+2.50.1
+
Signature · 6 lines
2.50.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw

Hello Thomas, All,

Le 23/08/2025 à 22:44, Thomas Petazzoni via buildroot a écrit :

Quoted 16 lines

The following defconfig:

BR2_arm=y
BR2_cortex_a9=y
BR2_ARM_ENABLE_VFP=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_INIT_NONE=y
BR2_SYSTEM_BIN_SH_NONE=y
# BR2_PACKAGE_BUSYBOX is not set
BR2_PACKAGE_RPI_USERLAND=y
# BR2_TARGET_ROOTFS_TAR is not set

will fail to build due to two issues in various part of rpi-userland making GCC 15.x unhappy.

Quoted 8 lines

Patch 0008-Fix-conflicting-types-build-error.patch is taken from a pull request already submitted by a contributor to the upstream project.

Patch 0009-Fix-raspicommonsettings_parse_cmdline.patch is backported from upstream, and can be dropped next time we bump rpi-userland.

Note that there are no autobuilder failures for this issue.

Applied to master, thanks.

Best regards,
Romain

Quoted 80 lines
---
 ...08-Fix-conflicting-types-build-error.patch | 41 +++++++++++++++++++
 ...ix-raspicommonsettings_parse_cmdline.patch | 28 +++++++++++++
 2 files changed, 69 insertions(+)
 create mode 100644 package/rpi-userland/0008-Fix-conflicting-types-build-error.patch
 create mode 100644 package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch
package/rpi-userland/0008-Fix-conflicting-types-build-error.patch new file +41 -0
new file mode 100644
index 0000000000..349ef2027e
@@ -0,0 +1,41 @@
+From c2337c83c627dd94f9b673361dca6ffafca7f59b Mon Sep 17 00:00:00 2001
+From: Jonas Kvinge <[email protected]>
+Date: Sun, 6 Jul 2025 20:21:00 +0200
+Subject: [PATCH] Fix conflicting types build error
+
+Upstream: https://github.com/raspberrypi/userland/pull/744
+Signed-off-by: Thomas Petazzoni <[email protected]>
+---
+ interface/vchiq_arm/vchiq_lib.c       | 2 +-
+ interface/vmcs_host/vc_vchi_gpuserv.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/interface/vchiq_arm/vchiq_lib.c b/interface/vchiq_arm/vchiq_lib.c
+index 133d5ca..7a2dae5 100755
+--- a/interface/vchiq_arm/vchiq_lib.c
++++ b/interface/vchiq_arm/vchiq_lib.c
+@@ -537,7 +537,7 @@ vchiq_bulk_receive_handle(VCHIQ_SERVICE_HANDLE_T handle,
+    int size,
+    void *userdata,
+    VCHIQ_BULK_MODE_T mode,
+-   int (*copy_pagelist)())
++   int (*copy_pagelist)(char *vcptr, const struct pagelist_struct *pagelist))
+ {
+    VCHIQ_SERVICE_T *service = find_service_by_handle(handle);
+    VCHIQ_QUEUE_BULK_TRANSFER_T args;
+diff --git a/interface/vmcs_host/vc_vchi_gpuserv.h b/interface/vmcs_host/vc_vchi_gpuserv.h
+index fc0bfee..ce6cb58 100755
+--- a/interface/vmcs_host/vc_vchi_gpuserv.h
++++ b/interface/vmcs_host/vc_vchi_gpuserv.h
+@@ -58,7 +58,7 @@ struct sync_job_s {
+ 
+ struct gpu_callback_s {
+   // callback to call when complete (can be NULL)
+-  void (*func)();
++  void (*func)(void*);
+   void *cookie;
+ };
+ 
+-- 
+2.50.1
+
package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch new file +18 -0
new file mode 100644
index 0000000000..df11d591fc
@@ -0,0 +1,28 @@
+From cf6d0ac0d31fcc2e64c83b8105b078e792f2d441 Mon Sep 17 00:00:00 2001
+From: Krawlow <[email protected]>
+Date: Wed, 23 Mar 2022 16:46:18 +0100
+Subject: [PATCH] Fix raspicommonsettings_parse_cmdline
+
+Fix raspicommonsettings_parse_cmdline's definition to match declaration
+
+Upstream: c4fd1b8986c6d6d4ae5cd51e65a8bbeb495dfa4e
+Signed-off-by: Thomas Petazzoni <[email protected]>
+---
+ host_applications/linux/apps/raspicam/RaspiCommonSettings.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
+index 75b2937..2e9de7d 100644
+--- a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
++++ b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
+@@ -54,6 +54,6 @@ typedef struct

package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch line 28

Quoted 10 lines
package/rpi-userland/0009-Fix-raspicommonsettings_parse_cmdline.patch new file +10 -0
+ void raspicommonsettings_set_defaults(RASPICOMMONSETTINGS_PARAMETERS *);
+ void raspicommonsettings_dump_parameters(RASPICOMMONSETTINGS_PARAMETERS *);
+ void raspicommonsettings_display_help();
+-int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)());
++int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)(char*));
+ 
+ #endif
+-- 
+2.50.1
+

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot