hostapd/wpa_s: disable build with static zlib-ng
cover hostapd/wpa_s: disable build with static zlib-ng
Hi all,
Both zlib-ng and hostapd/wpa_supplicant utils define functions with the same name 'crc32'. For now do not allow to select zlib-ng as zlib provider for hostapd or wpa_supplicant in the case of BR2_STATIC_LIBS is selected. This change can be reverted if either project rename that function.
Regards,
Sergey
Sergey Matyukevich (2):
package/hostapd: disable build with static zlib-ng package/wpa_supplicant: disable build with static zlib-ng
package/hostapd/Config.in | 4 ++++ package/wpa_supplicant/Config.in | 4 ++++ 2 files changed, 8 insertions(+)
Signature · 6 lines
2.37.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH 1/2 package/hostapd: disable build with static zlib-ng
Static linking fails because both hostapd and zlib-ng define functions with the same name 'crc32'. For now do not allow to select zlib-ng as zlib provider for hostapd in the case if static libraries are enabled.
--- package/hostapd/Config.in | 4 ++++ 1 file changed, 4 insertions(+)
package/hostapd/Config.in +4 -0
@@ -1,6 +1,7 @@ config BR2_PACKAGE_HOSTAPD bool "hostapd" depends on BR2_USE_MMU # fork() + depends on !(BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS) select BR2_PACKAGE_LIBOPENSSL_ENABLE_DES if BR2_PACKAGE_LIBOPENSSL select BR2_PACKAGE_LIBOPENSSL_ENABLE_MD4 if BR2_PACKAGE_LIBOPENSSL help
@@ -12,6 +13,9 @@ config BR2_PACKAGE_HOSTAPD http://w1.fi/hostapd/ +comment "hostapd fails to build with static zlib-ng" + depends on BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS + if BR2_PACKAGE_HOSTAPD config BR2_PACKAGE_HOSTAPD_DRIVER_HOSTAP
Signature · 6 lines
2.37.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH 1/2] package/hostapd: disable build with static zlib-ng
Quoted 16 lines · On Sun, 4 Sep 2022 23:14:28 +0300 Sergey Matyukevich <[email protected]>…
Static linking fails because both hostapd and zlib-ng define functions with the same name 'crc32'. For now do not allow to select zlib-ng as zlib provider for hostapd in the case if static libraries are enabled.
Signed-off-by Sergey Matyukevich <[email protected]>--- package/hostapd/Config.in | 4 ++++ 1 file changed, 4 insertions(+)package/hostapd/Config.in +0
-0
package/hostapd/Config.in line 4
Quoted 4 lines
package/hostapd/Config.in +1
-0@@ -1,6 +1,7 @@ config BR2_PACKAGE_HOSTAPD bool "hostapd" depends on BR2_USE_MMU # fork() + depends on !(BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS)
Thanks for your patch. However, we generally don't like to add such weird dependencies. Instead, we prefer to fix the actual problem:
hostapd/wpa_supplicant should probably not define a crc32() function, but use some other naming for it.
Thanks!
Thomas
Signature · 7 lines
Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH 1/2] package/hostapd: disable build with static zlib-ng
Quoted 11 lines
Quoted 11 lines
Static linking fails because both hostapd and zlib-ng define functions with the same name 'crc32'. For now do not allow to select zlib-ng as zlib provider for hostapd in the case if static libraries are enabled.
Signed-off-by Sergey Matyukevich <[email protected]>--- package/hostapd/Config.in | 4 ++++ 1 file changed, 4 insertions(+)
Quoted 14 lines
package/hostapd/Config.in line 4
Quoted 9 lines
package/hostapd/Config.in +1
-0@@ -1,6 +1,7 @@ config BR2_PACKAGE_HOSTAPD bool "hostapd" depends on BR2_USE_MMU # fork() + depends on !(BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS)Thanks for your patch. However, we generally don't like to add such weird dependencies. Instead, we prefer to fix the actual problem:
hostapd/wpa_supplicant should probably not define acrc32()function, but use some other naming for it.
Indeed, suggested dependency is too weird. I sent a patch to hostapd mailing list fixing too generic name for its IEEE 802.11 CRC-32:
http://lists.infradead.org/pipermail/hostap/2022-September/040752.html
If it is ok with hostapd maintainer, then I will split/adapt this patch for hostapd/wpa_s v2.10 and send v2 here.
Regards,
Sergey
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH 2/2 package/wpa_supplicant: disable build with static zlib-ng
In reply to Sergey MatyukevichStatic linking fails because both wpa_supplicant and zlib-ng define functions with the same name 'crc32'. For now do not allow to select zlib-ng as zlib provider for wpa_supplicant in the case if static libraries are enabled.
--- package/wpa_supplicant/Config.in | 4 ++++ 1 file changed, 4 insertions(+)
package/wpa_supplicant/Config.in +4 -0
@@ -1,6 +1,7 @@ menuconfig BR2_PACKAGE_WPA_SUPPLICANT bool "wpa_supplicant" depends on BR2_USE_MMU # fork() + depends on !(BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS) select BR2_PACKAGE_LIBOPENSSL_ENABLE_DES if BR2_PACKAGE_LIBOPENSSL select BR2_PACKAGE_LIBOPENSSL_ENABLE_MD4 if BR2_PACKAGE_LIBOPENSSL help
@@ -8,6 +9,9 @@ menuconfig BR2_PACKAGE_WPA_SUPPLICANT http://w1.fi/wpa_supplicant/ +comment "wpa_supplicant fails to build with static zlib-ng" + depends on BR2_PACKAGE_ZLIB_NG && BR2_STATIC_LIBS + if BR2_PACKAGE_WPA_SUPPLICANT config BR2_PACKAGE_WPA_SUPPLICANT_NL80211
Signature · 6 lines
2.37.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot