python-dataproperty: bump version to 0.17.0
[buildroot-gz.git] / package / luvi / luvi.mk
blobade63f5fba87df02fdc3a5e35d2ce9acf0daf146
1 ################################################################################
3 # luvi
5 ################################################################################
7 LUVI_VERSION = v2.7.5
8 LUVI_SOURCE = luvi-src-$(LUVI_VERSION).tar.gz
9 LUVI_SITE = https://github.com/luvit/luvi/releases/download/$(LUVI_VERSION)
10 LUVI_LICENSE = Apache-2.0
11 LUVI_LICENSE_FILES = LICENSE.txt
12 LUVI_DEPENDENCIES = libuv luajit luv host-luajit
14 # Dispatch all architectures of LuaJIT
15 ifeq ($(BR2_i386),y)
16 LUVI_TARGET_ARCH = x86
17 else ifeq ($(BR2_x86_64),y)
18 LUVI_TARGET_ARCH = x64
19 else ifeq ($(BR2_powerpc),y)
20 LUVI_TARGET_ARCH = ppc
21 else ifeq ($(BR2_arm)$(BR2_armeb),y)
22 LUVI_TARGET_ARCH = arm
23 else ifeq ($(BR2_mips),y)
24 LUVI_TARGET_ARCH = mips
25 else ifeq ($(BR2_mipsel),y)
26 LUVI_TARGET_ARCH = mipsel
27 else
28 LUVI_TARGET_ARCH = $(BR2_ARCH)
29 endif
31 # Bundled lua bindings have to be linked statically into the luvi executable
32 LUVI_CONF_OPTS = \
33 -DBUILD_SHARED_LIBS=OFF \
34 -DWithSharedLibluv=ON \
35 -DTARGET_ARCH=$(LUVI_TARGET_ARCH) \
36 -DLUA_PATH=$(HOST_DIR)/usr/share/luajit-2.0.4/?.lua
38 # Add "rex" module (PCRE via bundled lrexlib)
39 ifeq ($(BR2_PACKAGE_PCRE),y)
40 LUVI_DEPENDENCIES += pcre
41 LUVI_CONF_OPTS += -DWithPCRE=ON -DWithSharedPCRE=ON
42 else
43 LUVI_CONF_OPTS += -DWithPCRE=OFF -DWithSharedPCRE=OFF
44 endif
46 # Add "ssl" module (via bundled lua-openssl)
47 ifeq ($(BR2_PACKAGE_OPENSSL),y)
48 LUVI_DEPENDENCIES += openssl
49 LUVI_CONF_OPTS += -DWithOpenSSL=ON -DWithOpenSSLASM=ON -DWithSharedOpenSSL=ON
50 else
51 LUVI_CONF_OPTS += -DWithOpenSSL=OFF -DWithOpenSSLASM=OFF -DWithSharedOpenSSL=OFF
52 endif
54 # Add "zlib" module (via bundled lua-zlib)
55 ifeq ($(BR2_PACKAGE_ZLIB),y)
56 LUVI_DEPENDENCIES += zlib
57 LUVI_CONF_OPTS += -DWithZLIB=ON -DWithSharedZLIB=ON
58 else
59 LUVI_CONF_OPTS += -DWithZLIB=OFF -DWithSharedZLIB=OFF
60 endif
62 $(eval $(cmake-package))