* [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k
@ 2026-07-04 8:52 Bernd Kuhls
2026-07-04 8:52 ` [Buildroot] [PATCH 2/2] package/samba4: bump version to 4.24.4 Bernd Kuhls
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Bernd Kuhls @ 2026-07-04 8:52 UTC (permalink / raw)
To: buildroot
samba4 uses very big switch statements, which causes the build to fail
on m68k, because the offsets there are only 16-bit.
We fix that by using -mlong-jump-table-offsets on m68k to use 32-bit
offsets for switch statements, but this is only available starting with
gcc 7 [0] [1].
Only one package selects samba4, mpd, but it already depends on gcc
>= 12. As such, we do not need to propagate that new dependency.
Fixes:
https://autobuild.buildroot.net/results/b60/b606da691bb462879d4f9769928b5a40b9170837/
[0] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c15
[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c16
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
Series passed Gitlab pipelines:
https://gitlab.com/bkuhls/buildroot/-/commits/00a09b88bb7905e5daf558adf59cbb13a05e05dc
package/samba4/Config.in | 5 +++++
package/samba4/samba4.mk | 5 +++++
2 files changed, 10 insertions(+)
diff --git a/package/samba4/Config.in b/package/samba4/Config.in
index e1d3dd9bf7..59f040e96a 100644
--- a/package/samba4/Config.in
+++ b/package/samba4/Config.in
@@ -4,6 +4,10 @@ comment "samba4 needs a uClibc or glibc toolchain w/ wchar, dynamic library, NPT
|| BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS_NPTL
depends on BR2_USE_MMU
+comment "samba4 needs a toolchain w/ gcc >= 7"
+ depends on BR2_m68k
+ depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_7
+
config BR2_PACKAGE_SAMBA4
bool "samba4"
depends on BR2_USE_MMU # fork()
@@ -12,6 +16,7 @@ config BR2_PACKAGE_SAMBA4
depends on !BR2_STATIC_LIBS # cmocka, python, gnutls
depends on BR2_TOOLCHAIN_HAS_SYNC_4
depends on !BR2_TOOLCHAIN_USES_MUSL
+ depends on !BR2_m68k || BR2_TOOLCHAIN_GCC_AT_LEAST_7 # m68k needs gcc >= 7.x
select BR2_PACKAGE_CMOCKA
select BR2_PACKAGE_E2FSPROGS
select BR2_PACKAGE_GNUTLS
diff --git a/package/samba4/samba4.mk b/package/samba4/samba4.mk
index 2d6bc80b9e..006fbff6c5 100644
--- a/package/samba4/samba4.mk
+++ b/package/samba4/samba4.mk
@@ -32,6 +32,11 @@ SAMBA4_CONF_ENV = \
XSLTPROC=false \
WAF_NO_PREFORK=1
+# m68k needs 32-bit offsets in switch tables to build
+ifeq ($(BR2_m68k),y)
+SAMBA4_CFLAGS += -mlong-jump-table-offsets
+endif
+
SAMBA4_PYTHON = PYTHON="$(HOST_DIR)/bin/python3"
ifeq ($(BR2_PACKAGE_PYTHON3),y)
SAMBA4_PYTHON += PYTHON_CONFIG="$(STAGING_DIR)/usr/bin/python3-config"
--
2.47.3
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 5+ messages in thread* [Buildroot] [PATCH 2/2] package/samba4: bump version to 4.24.4
2026-07-04 8:52 [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Bernd Kuhls
@ 2026-07-04 8:52 ` Bernd Kuhls
2026-08-07 11:16 ` Titouan Christophe via buildroot
2026-07-10 20:48 ` [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Julien Olivain via buildroot
2026-07-17 15:47 ` Thomas Perale via buildroot
2 siblings, 1 reply; 5+ messages in thread
From: Bernd Kuhls @ 2026-07-04 8:52 UTC (permalink / raw)
To: buildroot
https://www.samba.org/samba/history/samba-4.24.4.html
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
Series passed Gitlab pipelines:
https://gitlab.com/bkuhls/buildroot/-/commits/00a09b88bb7905e5daf558adf59cbb13a05e05dc
package/samba4/samba4.hash | 4 ++--
package/samba4/samba4.mk | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/package/samba4/samba4.hash b/package/samba4/samba4.hash
index 83e77f039b..7c44ed747a 100644
--- a/package/samba4/samba4.hash
+++ b/package/samba4/samba4.hash
@@ -1,4 +1,4 @@
# Locally calculated after checking pgp signature
-# https://download.samba.org/pub/samba/stable/samba-4.24.3.tar.asc
-sha256 4a5e0ed1ea192b798c873d9957c50a5767c10c2767cccb00d56ecc427e94f8e9 samba-4.24.3.tar.gz
+# https://download.samba.org/pub/samba/stable/samba-4.24.4.tar.asc
+sha256 df2c51ab4361ec626ab9988e5946efcca8465bc7afae834291d5558468265ff8 samba-4.24.4.tar.gz
sha256 8ceb4b9ee5adedde47b31e975c1d90c73ad27b6b165a1dcd80c7c545eb65b903 COPYING
diff --git a/package/samba4/samba4.mk b/package/samba4/samba4.mk
index 006fbff6c5..d481f9d417 100644
--- a/package/samba4/samba4.mk
+++ b/package/samba4/samba4.mk
@@ -4,7 +4,7 @@
#
################################################################################
-SAMBA4_VERSION = 4.24.3
+SAMBA4_VERSION = 4.24.4
SAMBA4_SITE = https://download.samba.org/pub/samba/stable
SAMBA4_SOURCE = samba-$(SAMBA4_VERSION).tar.gz
SAMBA4_INSTALL_STAGING = YES
--
2.47.3
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k
2026-07-04 8:52 [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Bernd Kuhls
2026-07-04 8:52 ` [Buildroot] [PATCH 2/2] package/samba4: bump version to 4.24.4 Bernd Kuhls
@ 2026-07-10 20:48 ` Julien Olivain via buildroot
2026-07-17 15:47 ` Thomas Perale via buildroot
2 siblings, 0 replies; 5+ messages in thread
From: Julien Olivain via buildroot @ 2026-07-10 20:48 UTC (permalink / raw)
To: Bernd Kuhls; +Cc: buildroot
On 04/07/2026 10:52, Bernd Kuhls wrote:
> samba4 uses very big switch statements, which causes the build to fail
> on m68k, because the offsets there are only 16-bit.
>
> We fix that by using -mlong-jump-table-offsets on m68k to use 32-bit
> offsets for switch statements, but this is only available starting with
> gcc 7 [0] [1].
>
> Only one package selects samba4, mpd, but it already depends on gcc
>> = 12. As such, we do not need to propagate that new dependency.
>
> Fixes:
> https://autobuild.buildroot.net/results/b60/b606da691bb462879d4f9769928b5a40b9170837/
>
> [0] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c15
> [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c16
>
> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
Series applied to master, thanks.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k
2026-07-04 8:52 [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Bernd Kuhls
2026-07-04 8:52 ` [Buildroot] [PATCH 2/2] package/samba4: bump version to 4.24.4 Bernd Kuhls
2026-07-10 20:48 ` [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Julien Olivain via buildroot
@ 2026-07-17 15:47 ` Thomas Perale via buildroot
2 siblings, 0 replies; 5+ messages in thread
From: Thomas Perale via buildroot @ 2026-07-17 15:47 UTC (permalink / raw)
To: Bernd Kuhls; +Cc: Thomas Perale, buildroot
In reply of:
> samba4 uses very big switch statements, which causes the build to fail
> on m68k, because the offsets there are only 16-bit.
>
> We fix that by using -mlong-jump-table-offsets on m68k to use 32-bit
> offsets for switch statements, but this is only available starting with
> gcc 7 [0] [1].
>
> Only one package selects samba4, mpd, but it already depends on gcc
> >= 12. As such, we do not need to propagate that new dependency.
>
> Fixes:
> https://autobuild.buildroot.net/results/b60/b606da691bb462879d4f9769928b5a40b9170837/
>
> [0] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c15
> [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57583#c16
>
> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
Applied to 2025.02.x & 2026.05.x. Thanks
> ---
> Series passed Gitlab pipelines:
> https://gitlab.com/bkuhls/buildroot/-/commits/00a09b88bb7905e5daf558adf59cbb13a05e05dc
>
> package/samba4/Config.in | 5 +++++
> package/samba4/samba4.mk | 5 +++++
> 2 files changed, 10 insertions(+)
>
> diff --git a/package/samba4/Config.in b/package/samba4/Config.in
> index e1d3dd9bf7..59f040e96a 100644
> --- a/package/samba4/Config.in
> +++ b/package/samba4/Config.in
> @@ -4,6 +4,10 @@ comment "samba4 needs a uClibc or glibc toolchain w/ wchar, dynamic library, NPT
> || BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS_NPTL
> depends on BR2_USE_MMU
>
> +comment "samba4 needs a toolchain w/ gcc >= 7"
> + depends on BR2_m68k
> + depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_7
> +
> config BR2_PACKAGE_SAMBA4
> bool "samba4"
> depends on BR2_USE_MMU # fork()
> @@ -12,6 +16,7 @@ config BR2_PACKAGE_SAMBA4
> depends on !BR2_STATIC_LIBS # cmocka, python, gnutls
> depends on BR2_TOOLCHAIN_HAS_SYNC_4
> depends on !BR2_TOOLCHAIN_USES_MUSL
> + depends on !BR2_m68k || BR2_TOOLCHAIN_GCC_AT_LEAST_7 # m68k needs gcc >= 7.x
> select BR2_PACKAGE_CMOCKA
> select BR2_PACKAGE_E2FSPROGS
> select BR2_PACKAGE_GNUTLS
> diff --git a/package/samba4/samba4.mk b/package/samba4/samba4.mk
> index 2d6bc80b9e..006fbff6c5 100644
> --- a/package/samba4/samba4.mk
> +++ b/package/samba4/samba4.mk
> @@ -32,6 +32,11 @@ SAMBA4_CONF_ENV = \
> XSLTPROC=false \
> WAF_NO_PREFORK=1
>
> +# m68k needs 32-bit offsets in switch tables to build
> +ifeq ($(BR2_m68k),y)
> +SAMBA4_CFLAGS += -mlong-jump-table-offsets
> +endif
> +
> SAMBA4_PYTHON = PYTHON="$(HOST_DIR)/bin/python3"
> ifeq ($(BR2_PACKAGE_PYTHON3),y)
> SAMBA4_PYTHON += PYTHON_CONFIG="$(STAGING_DIR)/usr/bin/python3-config"
> --
> 2.47.3
>
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-08-07 11:16 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-04 8:52 [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Bernd Kuhls
2026-07-04 8:52 ` [Buildroot] [PATCH 2/2] package/samba4: bump version to 4.24.4 Bernd Kuhls
2026-08-07 11:16 ` Titouan Christophe via buildroot
2026-07-10 20:48 ` [Buildroot] [PATCH 1/2] package/samba4: fix build on m68k Julien Olivain via buildroot
2026-07-17 15:47 ` Thomas Perale via buildroot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox