2 # Copyright (C) 2010-2016 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.gz
15 PKG_SOURCE_URL
:=https
://nlnetlabs.nl
/downloads
/unbound
16 PKG_HASH
:=1d98fc6ea99197a20b4a0e540e87022cf523085786e0fc26de6ebb2720f5aaf0
18 PKG_MAINTAINER
:=Eric Luehrsen
<ericluehrsen@gmail.com
>
19 PKG_LICENSE
:=BSD-3-Clause
20 PKG_LICENSE_FILES
:=LICENSE
21 PKG_CPE_ID
:=cpe
:/a
:nlnetlabs
:unbound
27 include $(INCLUDE_DIR
)/package.mk
29 define Package
/unbound
/Default
32 SUBMENU
:=IP Addresses and Names
33 USERID
:=unbound
:unbound
34 TITLE
:=Recursive DNS Server
35 URL
:=https
://nlnetlabs.nl
/projects
/unbound
/about
36 DEPENDS
:=+libopenssl
+@OPENSSL_WITH_EC
39 define Package
/unbound-daemon
40 $(call Package
/unbound
/Default
)
41 TITLE
+= (daemon
, light traffic
)
46 define Package
/unbound-daemon
/description
47 This package contains the Unbound daemon with basic includes
48 necessary to meet the needs of UCI
/LuCI configuration optoins.
51 define Package
/unbound-daemon-heavy
52 $(call Package
/unbound
/Default
)
53 TITLE
+= (daemon
, heavy traffic
)
54 URL
:=https
://nlnetlabs.nl
/documentation
/unbound
/howto-optimise
55 DEPENDS
+= +libunbound-heavy
+libpthread
+libevent2
+libevent2-pthreads
57 PROVIDES
:=unbound-daemon
60 define Package
/unbound-daemon-heavy
/description
61 This package contains the Unbound daemon including
'libevent' and
62 'libpthread' to better handle large networks with heavy query loads.
65 define Package
/libunbound
66 $(call Package
/unbound
/Default
)
70 TITLE
+= (library
, light traffic
)
75 define Package
/libunbound
/description
76 This package contains the Unbound shared library with basic includes
77 necessary to meet the needs of UCI
/LuCI configuration optoins.
80 define Package
/libunbound-heavy
81 $(call Package
/unbound
/Default
)
85 TITLE
+= (library
, heavy traffic
)
86 URL
:=https
://nlnetlabs.nl
/documentation
/unbound
/howto-optimise
87 DEPENDS
+= +libpthread
+libevent2
+libevent2-pthreads
92 define Package
/libunbound-heavy
/description
93 This package contains the Unbound shared library including
'libevent' and
94 'libpthread' to better handle large networks with heavy query loads.
97 define Package
/unbound-anchor
98 $(call Package
/unbound
/Default
)
100 DEPENDS
+= +unbound-daemon
+libexpat
103 define Package
/unbound-anchor
/description
104 This package contains the Unbound anchor utility.
107 define Package
/unbound-checkconf
108 $(call Package
/unbound
/Default
)
109 TITLE
+= (config checker
)
110 DEPENDS
+= +unbound-daemon
113 define Package
/unbound-checkconf
/description
114 This package contains the Unbound DNS configuration checker utility.
117 define Package
/unbound-control
118 $(call Package
/unbound
/Default
)
119 TITLE
+= (remote control
)
120 DEPENDS
+= +unbound-daemon
123 define Package
/unbound-control
/description
124 This package contains the Unbound control utility.
127 define Package
/unbound-control-setup
128 $(call Package
/unbound
/Default
)
129 TITLE
+= (control setup
)
130 DEPENDS
+= +unbound-control
+openssl-util
133 define Package
/unbound-control-setup
/description
134 This package contains the Unbound control setup utility.
137 define Package
/unbound-host
138 $(call Package
/unbound
/Default
)
140 DEPENDS
+= +libunbound
143 define Package
/unbound-host
/description
144 This package contains the Unbound DNS lookup utility.
150 --enable-allsymbols \
152 --enable-tfo-client \
153 --enable-tfo-server \
154 --with-libexpat
="$(STAGING_DIR)/usr" \
155 --with-ssl
="$(STAGING_DIR)/usr" \
156 --with-user
=unbound \
157 --with-run-dir
=/var
/lib
/unbound \
158 --with-conf-file
=/var
/lib
/unbound
/unbound.conf \
159 --with-pidfile
=/var
/run
/unbound.pid
161 ifeq ($(BUILD_VARIANT
),heavy
)
164 --with-libevent
="$(STAGING_DIR)/usr" \
169 --without-solaris-threads \
173 define Package
/unbound-daemon
/conffiles
175 /etc
/unbound
/unbound.conf
176 /etc
/unbound
/unbound_ext.conf
177 /etc
/unbound
/unbound_srv.conf
180 Package
/unbound-daemon-heavy
/conffiles
= $(Package
/unbound-daemon
/conffiles
)
182 define Build
/InstallDev
183 $(INSTALL_DIR
) $(1)/usr
/lib
184 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/lib
/libunbound.
{so
*,a
,la
} $(1)/usr
/lib
/
185 $(INSTALL_DIR
) $(1)/usr
/include
186 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/include/unbound.h
$(1)/usr
/include/
187 ifeq ($(BUILD_VARIANT
),heavy
)
188 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/include/unbound-event.h
$(1)/usr
/include/
192 define Package
/unbound-daemon
/install
193 $(INSTALL_DIR
) $(1)/usr
/sbin
195 $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound
$(1)/usr
/sbin
/
196 $(INSTALL_DIR
) $(1)/etc
/unbound
198 $(PKG_INSTALL_DIR
)/var
/lib
/unbound
/unbound.conf \
199 $(1)/etc
/unbound
/unbound.conf
200 $(INSTALL_DATA
) .
/files
/root.key
$(1)/etc
/unbound
/root.key
201 $(INSTALL_DATA
) .
/files
/unbound_ext.conf
$(1)/etc
/unbound
/unbound_ext.conf
202 $(INSTALL_DATA
) .
/files
/unbound_srv.conf
$(1)/etc
/unbound
/unbound_srv.conf
203 $(INSTALL_DIR
) $(1)/etc
/config
204 $(INSTALL_DATA
) .
/files
/unbound.uci
$(1)/etc
/config
/unbound
205 $(INSTALL_DIR
) $(1)/etc
/hotplug.d
/ntp
206 $(INSTALL_BIN
) .
/files
/unbound.ntpd
$(1)/etc
/hotplug.d
/ntp
/25-unbound
207 $(INSTALL_DIR
) $(1)/etc
/init.d
208 $(INSTALL_BIN
) .
/files
/unbound.init
$(1)/etc
/init.d
/unbound
209 $(INSTALL_DIR
) $(1)/usr
/lib
/unbound
210 $(INSTALL_DATA
) .
/files
/defaults.sh
$(1)/usr
/lib
/unbound
/defaults.sh
211 $(INSTALL_DATA
) .
/files
/dnsmasq.sh
$(1)/usr
/lib
/unbound
/dnsmasq.sh
212 $(INSTALL_DATA
) .
/files
/iptools.sh
$(1)/usr
/lib
/unbound
/iptools.sh
213 $(INSTALL_BIN
) .
/files
/odhcpd.sh
$(1)/usr
/lib
/unbound
/odhcpd.sh
214 $(INSTALL_DATA
) .
/files
/odhcpd.awk
$(1)/usr
/lib
/unbound
/odhcpd.awk
215 $(INSTALL_DATA
) .
/files
/stopping.sh
$(1)/usr
/lib
/unbound
/stopping.sh
216 $(INSTALL_DATA
) .
/files
/unbound.sh
$(1)/usr
/lib
/unbound
/unbound.sh
219 Package
/unbound-daemon-heavy
/install = $(Package
/unbound-daemon
/install)
221 define Package
/libunbound
/install
222 $(INSTALL_DIR
) $(1)/usr
/lib
223 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libunbound.so.
* $(1)/usr
/lib
/
226 Package
/libunbound-heavy
/install = $(Package
/libunbound
/install)
228 define Package
/unbound-anchor
/install
229 $(INSTALL_DIR
) $(1)/usr
/sbin
230 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound-anchor
$(1)/usr
/sbin
/
233 define Package
/unbound-checkconf
/install
234 $(INSTALL_DIR
) $(1)/usr
/sbin
235 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound-checkconf
$(1)/usr
/sbin
/
238 define Package
/unbound-control
/install
239 $(INSTALL_DIR
) $(1)/usr
/sbin
240 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound-control
$(1)/usr
/sbin
/
243 define Package
/unbound-control-setup
/install
244 $(INSTALL_DIR
) $(1)/usr
/sbin
245 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound-control-setup
$(1)/usr
/sbin
/
248 define Package
/unbound-host
/install
249 $(INSTALL_DIR
) $(1)/usr
/sbin
250 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/unbound-host
$(1)/usr
/sbin
/
253 $(eval
$(call BuildPackage
,unbound-daemon
))
254 $(eval
$(call BuildPackage
,unbound-daemon-heavy
))
255 $(eval
$(call BuildPackage
,libunbound
))
256 $(eval
$(call BuildPackage
,libunbound-heavy
))
257 $(eval
$(call BuildPackage
,unbound-anchor
))
258 $(eval
$(call BuildPackage
,unbound-checkconf
))
259 $(eval
$(call BuildPackage
,unbound-control
))
260 $(eval
$(call BuildPackage
,unbound-control-setup
))
261 $(eval
$(call BuildPackage
,unbound-host
))