package/haproxy: fix build on m68k
authorFabrice Fontaine <fontaine.fabrice@gmail.com>
Fri, 1 Nov 2019 11:10:05 +0000 (12:10 +0100)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Sun, 19 Apr 2020 20:50:18 +0000 (22:50 +0200)
When threads are enabled, haproxy expects that pthread_getcpuclockid is
available which is not the case on m68k. Fix this by enabling threads
support only if NPTL is available.

Fixes:
 - http://autobuild.buildroot.org/results/52cc4b1fcac2a4fc84ab15ec4c692d2cd9b6d8bd

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/haproxy/haproxy.mk

index 6752367fac1f9c17c899d9aa81ff9e60c4a5ed1e..e59896b485563619dee4dddcb74606df073d4d58 100644 (file)
@@ -19,7 +19,7 @@ ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
 HAPROXY_LIBS += -latomic
 endif
 
-ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),y)
+ifeq ($(BR2_TOOLCHAIN_HAS_THREADS_NPTL),y)
 # threads uses atomics on gcc >= 4.7 and sync otherwise (see
 # include/common/hathreads.h)
 ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_4_7):$(BR2_TOOLCHAIN_HAS_ATOMIC),y:y)