a2b3b5eef1ed8ea5d38aca51441fd456fe85147c
[openwrt/openwrt.git] / package / libs / cyassl / Makefile
1 #
2 # Copyright (C) 2006-2016 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=wolfssl
11 PKG_VERSION:=3.9.0
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).zip
15 PKG_SOURCE_URL:=https://www.wolfssl.com/
16 PKG_MD5SUM:=f3396726a9befd61443c2cce216e39ba
17
18 PKG_FIXUP:=libtool
19 PKG_INSTALL:=1
20 PKG_BUILD_PARALLEL:=1
21 PKG_LICENSE:=GPL-2.0+
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/libcyassl
26 SECTION:=libs
27 SUBMENU:=SSL
28 CATEGORY:=Libraries
29 TITLE:=CyaSSL library
30 URL:=http://www.wolfssl.com/
31 endef
32
33 define Package/libcyassl/description
34 CyaSSL is an SSL library optimized for small footprint, both on disk and for
35 memory use.
36 endef
37
38 TARGET_CFLAGS += $(FPIC)
39
40 CONFIGURE_ARGS += \
41 --enable-singlethreaded \
42 --enable-opensslextra \
43 --enable-sni \
44 --enable-stunnel \
45 --enable-ecc \
46 --disable-examples
47
48 #ifneq ($(CONFIG_TARGET_x86),)
49 # CONFIGURE_ARGS += --enable-intelasm
50 #endif
51 #ifneq ($(CONFIG_TARGET_x86_64),)
52 # CONFIGURE_ARGS += --enable-intelasm
53 #endif
54
55 define Build/InstallDev
56 $(INSTALL_DIR) $(1)/usr/include
57 $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
58
59 $(INSTALL_DIR) $(1)/usr/lib
60 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwolfssl.{so*,la} $(1)/usr/lib/
61 ln -s libwolfssl.so $(1)/usr/lib/libcyassl.so
62 ln -s libwolfssl.la $(1)/usr/lib/libcyassl.la
63 endef
64
65 define Package/libcyassl/install
66 $(INSTALL_DIR) $(1)/usr/lib
67 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwolfssl.so* $(1)/usr/lib/
68 ln -s libwolfssl.so $(1)/usr/lib/libcyassl.so
69 endef
70
71 $(eval $(call BuildPackage,libcyassl))