2 # Copyright (C) 2013-2015 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_URL
=$(PROJECT_GIT
)/project
/odhcpd.git
15 PKG_SOURCE_DATE
:=2020-11-15
16 PKG_SOURCE_VERSION
:=fb55e80394c51d7502bb278f57520dec15a11355
17 PKG_MIRROR_HASH
:=631d15fd7c93529fa33433380c4811dbacca9665864e5836c6daca0c7165f25a
19 PKG_MAINTAINER
:=Hans Dedecker
<dedeckeh@gmail.com
>
23 PKG_CONFIG_DEPENDS
:=CONFIG_PACKAGE_odhcpd_
$(BUILD_VARIANT
)_ext_cer_id
24 PKG_ASLR_PIE_REGULAR
:=1
26 include $(INCLUDE_DIR
)/package.mk
27 include $(INCLUDE_DIR
)/cmake.mk
29 define Package
/odhcpd
/default
32 TITLE
:=OpenWrt DHCPv6
(-PD
)/RA Server
& Relay
33 DEPENDS
:=+libubox
+libuci
+libubus
+libnl-tiny
36 define Package
/odhcpd
/default
/description
37 odhcpd is a daemon for serving and relaying IP management protocols to
38 configure clients and downstream routers. It tries to follow the RFC
6204
39 requirements for IPv6 home routers.
42 define Package
/odhcpd
/default
/config
44 depends on PACKAGE_
$(1)
46 config PACKAGE_odhcpd_
$(2)_ext_cer_id
49 prompt
"CER-ID Extension ID (0 = disabled)"
54 $(call Package
/odhcpd
/default
)
55 TITLE
+= and DHCPv4 server
59 Package
/odhcpd
/config
=$(call Package
/odhcpd
/default
/config
,odhcpd
,full
)
61 define Package
/odhcpd
/description
62 $(call Package
/odhcpd
/default
/description
)
64 This is a variant providing server services for DHCPv4
, RA
, stateless and
65 stateful DHCPv6
, prefix delegation and can be used to relay RA
, DHCPv6 and
66 NDP between routed
(non-bridged
) interfaces in case no delegated prefixes
70 define Package
/odhcpd-ipv6only
71 $(call Package
/odhcpd
/default
)
76 Package
/odhcpd-ipv6only
/config
=$(call Package
/odhcpd
/default
/config
,odhcpd-ipv6only
,ipv6only
)
78 define Package
/odhcpd-ipv6only
/description
79 $(call Package
/odhcpd
/default
/description
)
81 This is a variant providing server services for RA
, stateless and stateful
82 DHCPv6
, prefix delegation and can be used to relay RA
, DHCPv6 and NDP between
83 routed
(non-bridged
) interfaces in case no delegated prefixes are available.
86 CMAKE_OPTIONS
+= -DUBUS
=1
88 ifeq ($(BUILD_VARIANT
),full
)
89 CMAKE_OPTIONS
+= -DDHCPV4_SUPPORT
=1
92 ifneq ($(CONFIG_PACKAGE_odhcpd_
$(BUILD_VARIANT
)_ext_cer_id
),0)
93 CMAKE_OPTIONS
+= -DEXT_CER_ID
=$(CONFIG_PACKAGE_odhcpd_
$(BUILD_VARIANT
)_ext_cer_id
)
96 define Package
/odhcpd
/install
97 $(INSTALL_DIR
) $(1)/usr
/sbin
/
98 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/odhcpd
$(1)/usr
/sbin
/
99 $(INSTALL_BIN
) .
/files
/odhcpd-update
$(1)/usr
/sbin
/
100 $(INSTALL_DIR
) $(1)/etc
/init.d
101 $(INSTALL_BIN
) .
/files
/odhcpd.init
$(1)/etc
/init.d
/odhcpd
102 $(INSTALL_DIR
) $(1)/etc
/uci-defaults
103 $(INSTALL_BIN
) .
/files
/odhcpd.defaults
$(1)/etc
/uci-defaults
/15_odhcpd
106 Package
/odhcpd-ipv6only
/install = $(Package
/odhcpd
/install)
108 $(eval
$(call BuildPackage
,odhcpd
))
109 $(eval
$(call BuildPackage
,odhcpd-ipv6only
))