2 # Copyright (C) 2007-2014 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.xz
15 PKG_SOURCE_URL
:=@GNU
/$(PKG_NAME
)
16 PKG_MD5SUM
:=78942cc0cce0a23e18114d982789e360
17 PKG_MAINTAINER
:=Maxim Storchak
<m.storchak@gmail.com
>
20 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(BUILD_VARIANT
)/$(PKG_NAME
)-$(PKG_VERSION
)
22 include $(INCLUDE_DIR
)/package.mk
24 define Package
/wget
/Default
28 SUBMENU
:=File Transfer
29 TITLE
:=Non-interactive network downloader
30 URL
:=http
://www.gnu.org
/software
/wget
/index.html
33 define Package
/wget
/Default
/description
34 Wget is a network utility to retrieve files from the Web using http
35 and ftp
, the two most widely used Internet protocols. It works
36 non-interactively
, so it will work in the background
, after having
37 logged off. The program supports recursive retrieval of web-authoring
38 pages
as well
as ftp sites
-- you can use wget to make mirrors of
39 archives and home pages or to travel the Web like a WWW robot.
43 $(call Package
/wget
/Default
)
44 DEPENDS
+= +libopenssl
+librt
45 TITLE
+= (with SSL support
)
49 define Package
/wget
/description
50 $(call Package
/wget
/Default
/description
)
51 This package is built with SSL support.
54 define Package
/wget-nossl
55 $(call Package
/wget
/Default
)
56 TITLE
+= (without SSL support
)
61 define Package
/wget-nossl
/description
62 $(call Package
/wget
/Default
/description
)
63 This package is built without SSL support.
72 ac_cv_header_uuid_uuid_h
=no
74 ifeq ($(BUILD_VARIANT
),ssl
)
77 --with-libssl-prefix
="$(STAGING_DIR)/usr"
80 ifeq ($(BUILD_VARIANT
),nossl
)
86 define Package
/wget
/install
87 $(INSTALL_DIR
) $(1)/usr
/bin
88 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/src
/wget
$(1)/usr
/bin
/wget-ssl
91 define Package
/wget-nossl
/install
92 $(INSTALL_DIR
) $(1)/usr
/bin
93 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/src
/wget
$(1)/usr
/bin
/wget-nossl
96 define Package
/wget
/postinst
98 if
[ -e
$${IPKG_INSTROOT}/usr
/bin
/wget
]; then
99 rm -rf
$${IPKG_INSTROOT}/usr
/bin
/wget
;
101 ln
-sf .
/wget-ssl
$${IPKG_INSTROOT}/usr
/bin
/wget
104 define Package
/wget
/postrm
106 rm $${IPKG_INSTROOT}/usr
/bin
/wget
107 [ -x
$${IPKG_INSTROOT}/usr
/bin
/wget-nossl
] && ln
-s .
/wget-nossl
$${IPKG_INSTROOT}/usr
/bin
/wget ||
{
108 ln
-s ..
/..
/bin
/busybox
$${IPKG_INSTROOT}/usr
/bin
/wget
109 $${IPKG_INSTROOT}/usr
/bin
/wget
2>&1 | grep
'applet not found' > /dev
/null
2>&1 && rm $${IPKG_INSTROOT}/usr
/bin
/wget
114 define Package
/wget-nossl
/postinst
116 if
[ -e
$${IPKG_INSTROOT}/usr
/bin
/wget
]; then
117 rm -rf
$${IPKG_INSTROOT}/usr
/bin
/wget
;
119 ln
-s .
/wget-nossl
$${IPKG_INSTROOT}/usr
/bin
/wget
122 define Package
/wget-nossl
/postrm
124 rm $${IPKG_INSTROOT}/usr
/bin
/wget
125 [ -x
$${IPKG_INSTROOT}/usr
/bin
/wget-ssl
] && ln
-s .
/wget-ssl
$${IPKG_INSTROOT}/usr
/bin
/wget ||
{
126 ln
-s ..
/..
/bin
/busybox
$${IPKG_INSTROOT}/usr
/bin
/wget
127 $${IPKG_INSTROOT}/usr
/bin
/wget
2>&1 | grep
'applet not found' > /dev
/null
2>&1 && rm $${IPKG_INSTROOT}/usr
/bin
/wget
132 $(eval
$(call BuildPackage
,wget
))
133 $(eval
$(call BuildPackage
,wget-nossl
))