summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/dhcp
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-connectivity/dhcp')
-rw-r--r--meta/recipes-connectivity/dhcp/dhcp.inc25
-rw-r--r--meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb2
2 files changed, 25 insertions, 2 deletions
diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
index be256ce280..f66dfba964 100644
--- a/meta/recipes-connectivity/dhcp/dhcp.inc
+++ b/meta/recipes-connectivity/dhcp/dhcp.inc
@@ -66,12 +66,35 @@ FILES_dhcp-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp
66 66
67FILES_dhcp-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay" 67FILES_dhcp-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
68 68
69FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf ${localstatedir}/lib/dhcp/" 69FILES_dhcp-client = "${base_sbindir}/dhclient ${base_sbindir}/dhclient-script ${sysconfdir}/dhcp/dhclient.conf"
70RDEPENDS_dhcp-client = "bash" 70RDEPENDS_dhcp-client = "bash"
71 71
72FILES_dhcp-omshell = "${bindir}/omshell" 72FILES_dhcp-omshell = "${bindir}/omshell"
73 73
74pkg_postinst_dhcp-server() { 74pkg_postinst_dhcp-server() {
75 mkdir -p $D/${localstatedir}/lib/dhcp
75 touch $D/${localstatedir}/lib/dhcp/dhcpd.leases 76 touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
76 touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases 77 touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
77} 78}
79
80pkg_postinst_dhcp-client() {
81 mkdir -p $D/${localstatedir}/lib/dhcp
82}
83
84pkg_postrm_dhcp-server() {
85 rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
86 rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
87
88 if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
89 echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
90 fi
91}
92
93pkg_postrm_dhcp-client() {
94 rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
95 rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
96
97 if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
98 echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
99 fi
100}
diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
index a3a560b991..3b1c0e2dd7 100644
--- a/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
+++ b/meta/recipes-connectivity/dhcp/dhcp_4.2.0.bb
@@ -1,6 +1,6 @@
1require dhcp.inc 1require dhcp.inc
2 2
3PR = "r5" 3PR = "r7"
4 4
5SRC_URI += "file://fixincludes.patch \ 5SRC_URI += "file://fixincludes.patch \
6 file://dhcp-3.0.3-dhclient-dbus.patch;striplevel=0 \ 6 file://dhcp-3.0.3-dhclient-dbus.patch;striplevel=0 \