46a1e2847f
kismets fails to build statically with libwebsockets since commit
14522a8f9d
because libwebsockets does not
specify any Libs.Private field in its pkg-config file resulting in the
following failure:
configure:10659: checking for lws_client_connect_via_info in -lwebsockets
configure:10684: /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/host/bin/arm-linux-g++ -std=gnu++17 -o conftest -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -static -static -O3 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 conftest.cpp -lwebsockets -latomic -lz >&5
/usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libwebsockets.a(tls.c.o): in function `alpn_cb':
tls.c:(.text+0x24): undefined reference to `SSL_select_next_proto'
As it is not trivial to specify Libs.Private with cmake buildsystem
(i.e. LIB_LIST contains the list of libraries but in the "cmake format"
with full paths and ';'), just disable static build with libwebsockets.
Fixes:
- http://autobuild.buildroot.org/results/9fc7891b61b1c487b95f07c59b802dd98ef71e3a
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
77 lines
2.1 KiB
Makefile
77 lines
2.1 KiB
Makefile
################################################################################
|
|
#
|
|
# libwebsockets
|
|
#
|
|
################################################################################
|
|
|
|
LIBWEBSOCKETS_VERSION = 4.0.21
|
|
LIBWEBSOCKETS_SITE = $(call github,warmcat,libwebsockets,v$(LIBWEBSOCKETS_VERSION))
|
|
LIBWEBSOCKETS_LICENSE = MIT with exceptions
|
|
LIBWEBSOCKETS_LICENSE_FILES = LICENSE
|
|
LIBWEBSOCKETS_DEPENDENCIES = zlib
|
|
LIBWEBSOCKETS_INSTALL_STAGING = YES
|
|
LIBWEBSOCKETS_CONF_OPTS = \
|
|
-DLWS_WITHOUT_TESTAPPS=ON \
|
|
-DLWS_IPV6=ON \
|
|
-DLWS_UNIX_SOCK=ON \
|
|
-DLWS_WITHOUT_EXTENSIONS=OFF
|
|
|
|
# If LWS_MAX_SMP=1, then there is no code related to pthreads compiled
|
|
# in the library. If unset, LWS_MAX_SMP defaults to 32 and a small
|
|
# amount of pthread mutex code is built into the library.
|
|
ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),)
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_MAX_SMP=1
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_MAX_SMP=
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_OPENSSL),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += openssl host-openssl
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_SSL=ON
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_SSL=OFF
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBEV),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += libev
|
|
LIBWEBSOCKETS_CONF_OPTS += \
|
|
-DLWS_WITH_LIBEV=ON \
|
|
-DLWS_WITH_LIBEVENT=OFF
|
|
else ifeq ($(BR2_PACKAGE_LIBEVENT),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += libevent
|
|
LIBWEBSOCKETS_CONF_OPTS += \
|
|
-DLWS_WITH_LIBEV=OFF \
|
|
-DLWS_WITH_LIBEVENT=ON
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += \
|
|
-DLWS_WITH_LIBEV=OFF \
|
|
-DLWS_WITH_LIBEVENT=OFF
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBGLIB2),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += libglib2
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_GLIB=ON
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_GLIB=OFF
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_UTIL_LINUX_LIBMOUNT),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += util-linux
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_FSMOUNT=ON
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_FSMOUNT=OFF
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBUV),y)
|
|
LIBWEBSOCKETS_DEPENDENCIES += libuv
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_LIBUV=ON
|
|
else
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_LIBUV=OFF
|
|
endif
|
|
|
|
ifeq ($(BR2_SHARED_LIBS),y)
|
|
LIBWEBSOCKETS_CONF_OPTS += -DLWS_WITH_STATIC=OFF
|
|
endif
|
|
|
|
$(eval $(cmake-package))
|