c293133b35e4c41c84a74f012f65f1fcd13fa94f
[packages.git] / ipv6 / wide-dhcpv6 / Makefile
1
2 include $(TOPDIR)/rules.mk
3
4 PKG_NAME:=wide-dhcpv6
5 PKG_VERSION:=20080615
6 PKG_RELEASE:=4
7
8 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
9 PKG_SOURCE_URL:=@SF/$(PKG_NAME)
10 PKG_MD5SUM:=1011e165850fe40d3e332dad2bfd30b3
11
12 include $(INCLUDE_DIR)/package.mk
13
14 define Package/wide-dhcpv6/Default
15   SECTION:=ipv6
16   CATEGORY:=IPv6
17   TITLE:=WIDE-DHCPv6
18   SUBMENU:=wide-dhcpv6
19   DEPENDS:=+kmod-ipv6 
20   URL:=https://sourceforge.net/projects/wide-dhcpv6/
21 endef
22
23 define Package/wide-dhcpv6-client
24   $(call Package/wide-dhcpv6/Default)
25   TITLE+= client
26 endef
27
28 define Package/wide-dhcpv6-client/description
29         WIDE-DHCPv6 is an open-source implementation of Dynamic Host Configuration Protocol
30         for IPv6 (DHCPv6) originally developed by the KAME project. The implementation
31         mainly conforms to the following standards: RFC3315,3319,3633,3646,4075,4272,etc.
32
33         This package installs the client component.
34 endef
35
36 define Package/wide-dhcpv6-server
37   $(call Package/wide-dhcpv6/Default)
38   TITLE+= server
39 endef
40
41 define Package/wide-dhcpv6-server/description
42         WIDE-DHCPv6 is an open-source implementation of Dynamic Host Configuration Protocol
43         for IPv6 (DHCPv6) originally developed by the KAME project. The implementation
44         mainly conforms to the following standards: RFC3315,3319,3633,3646,4075,4272,etc.
45
46         This package installs the server component.
47 endef
48
49 define Package/wide-dhcpv6-relay
50   $(call Package/wide-dhcpv6/Default)
51   TITLE+= relay
52 endef
53
54 define Package/wide-dhcpv6-relay/description
55         WIDE-DHCPv6 is an open-source implementation of Dynamic Host Configuration Protocol
56         for IPv6 (DHCPv6) originally developed by the KAME project. The implementation
57         mainly conforms to the following standards: RFC3315,3319,3633,3646,4075,4272,etc.
58
59         This package installs the relay component.
60 endef
61
62 define Package/wide-dhcpv6-control
63   $(call Package/wide-dhcpv6/Default)
64   TITLE+= client and server control utility
65 endef
66
67 define Package/wide-dhcpv6-control/description
68         WIDE-DHCPv6 is an open-source implementation of Dynamic Host Configuration Protocol
69         for IPv6 (DHCPv6) originally developed by the KAME project. The implementation
70         mainly conforms to the following standards: RFC3315,3319,3633,3646,4075,4272,etc.
71
72         This package installs the client and server control utility.
73 endef
74
75 define Build/Configure
76         $(call Build/Configure/Default,--with-localdbdir=/var)
77 endef
78
79 define Build/Compile    
80         $(MAKE) -C $(PKG_BUILD_DIR) \
81                 DESTDIR="$(PKG_INSTALL_DIR)" \
82                 all 
83 endef
84
85 define Package/wide-dhcpv6-client/conffiles
86 /etc/config/dhcp6c
87 endef
88
89 define Package/wide-dhcpv6-client/install
90         $(INSTALL_DIR) $(1)/usr/sbin
91         $(INSTALL_BIN) $(PKG_BUILD_DIR)/dhcp6c $(1)/usr/sbin
92         $(INSTALL_DIR) $(1)/etc/config
93         $(INSTALL_CONF) ./files/dhcp6c.conf $(1)/etc/config/dhcp6c
94         $(INSTALL_DIR) $(1)/etc/init.d
95         $(INSTALL_BIN) ./files/dhcp6c.init $(1)/etc/init.d/dhcp6c
96         $(INSTALL_DIR) $(1)/etc/hotplug.d/iface
97         $(INSTALL_DATA) ./files/dhcp6c.hotplug $(1)/etc/hotplug.d/iface/40-dhcp6c       
98         $(INSTALL_DIR) $(1)/etc/hotplug.d/dhcp6c
99         $(INSTALL_DATA) ./files/dhcp6c-dnsmasq.hotplug $(1)/etc/hotplug.d/dhcp6c/10-dnsmasq
100         $(INSTALL_DATA) ./files/dhcp6c-radvd.hotplug $(1)/etc/hotplug.d/dhcp6c/20-radvd
101         $(INSTALL_DIR) $(1)/usr/bin
102         $(INSTALL_BIN) ./files/dhcp6c-state $(1)/usr/bin/dhcp6c-state
103 endef
104
105 define Package/wide-dhcpv6-server/conffiles
106 /etc/config/dhcp6s
107 endef
108
109 define Package/wide-dhcpv6-server/install
110         $(INSTALL_DIR) $(1)/usr/sbin
111         $(INSTALL_BIN) $(PKG_BUILD_DIR)/dhcp6s $(1)/usr/sbin
112         $(INSTALL_DIR) $(1)/etc
113         $(INSTALL_CONF) $(PKG_BUILD_DIR)/dhcp6s.conf.sample $(1)/etc
114         $(INSTALL_DIR) $(1)/etc/config
115         $(INSTALL_CONF) ./files/dhcp6s.conf $(1)/etc/config/dhcp6s
116         $(INSTALL_DIR) $(1)/etc/init.d
117         $(INSTALL_BIN) ./files/dhcp6s.init $(1)/etc/init.d/dhcp6s
118         $(INSTALL_DIR) $(1)/etc/hotplug.d/iface
119         $(INSTALL_DATA) ./files/dhcp6s.hotplug $(1)/etc/hotplug.d/iface/50-dhcp6s       
120 endef
121
122 define Package/wide-dhcpv6-relay/install
123         $(INSTALL_DIR) $(1)/usr/sbin
124         $(INSTALL_BIN) $(PKG_BUILD_DIR)/dhcp6relay $(1)/usr/sbin
125 endef
126
127 define Package/wide-dhcpv6-control/install
128         $(INSTALL_DIR) $(1)/usr/sbin
129         $(INSTALL_BIN) $(PKG_BUILD_DIR)/dhcp6ctl $(1)/usr/sbin
130 endef
131
132 $(eval $(call BuildPackage,wide-dhcpv6-client))
133 $(eval $(call BuildPackage,wide-dhcpv6-server))
134 $(eval $(call BuildPackage,wide-dhcpv6-relay))
135 $(eval $(call BuildPackage,wide-dhcpv6-control))