uclient: update to the latest version, fixes HTTP redirect support
[openwrt/openwrt.git] / package / libs / uclient / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=uclient
4 PKG_VERSION:=2016-07-04
5 PKG_RELEASE=$(PKG_SOURCE_VERSION)
6
7 PKG_SOURCE_PROTO:=git
8 PKG_SOURCE_URL=$(LEDE_GIT)/project/uclient.git
9 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
10 PKG_SOURCE_VERSION:=4fdad31fd199ef97b078f6355463d64ce598e85e
11 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
12 PKG_MIRROR_MD5SUM:=
13 CMAKE_INSTALL:=1
14
15 PKG_BUILD_DEPENDS:=ustream-ssl
16
17 PKG_LICENSE:=ISC
18 PKG_LICENSE_FILES:=
19
20 PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
21
22 include $(INCLUDE_DIR)/package.mk
23 include $(INCLUDE_DIR)/cmake.mk
24
25 define Package/libuclient
26 SECTION:=libs
27 CATEGORY:=Libraries
28 TITLE:=HTTP/1.1 client library
29 ABI_VERSION:=$(PKG_VERSION)
30 DEPENDS:=+libubox
31 endef
32
33 define Package/uclient-fetch
34 SECTION:=net
35 CATEGORY:=Network
36 TITLE:=Tiny wget replacement using libuclient
37 DEPENDS:=+libuclient
38 endef
39
40 define Package/libuclient/install
41 $(INSTALL_DIR) $(1)/usr/lib
42 $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libuclient.so $(1)/usr/lib/
43 endef
44
45 define Package/uclient-fetch/install
46 $(INSTALL_DIR) $(1)/bin
47 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/uclient-fetch $(1)/bin/
48 ln -s uclient-fetch $(1)/bin/wget
49 endef
50
51 $(eval $(call BuildPackage,libuclient))
52 $(eval $(call BuildPackage,uclient-fetch))