diff options
author | Andrej Valek <andrej.valek@siemens.com> | 2022-02-01 16:11:36 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-02-03 09:05:14 +0000 |
commit | f91604daee1b79aa41307a28bf38dd0a2e2c82a4 (patch) | |
tree | e6687a07321264263b5c6884063337ec0ee4b3c5 /meta/recipes-connectivity | |
parent | 6834a3614897105a24bd717acf313b2028a01362 (diff) | |
download | poky-f91604daee1b79aa41307a28bf38dd0a2e2c82a4.tar.gz |
dhcpcd: add option to set DBDIR location
This will allow to use the different DBDIR location, because the /var/lib
could be used as a read-only location.
(From OE-Core rev: 8fe5cff505f4fd942723d6f1526b0461747fc44d)
Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-connectivity')
-rw-r--r-- | meta/recipes-connectivity/dhcpcd/dhcpcd_9.4.1.bb | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/meta/recipes-connectivity/dhcpcd/dhcpcd_9.4.1.bb b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.4.1.bb index 4007a4bd2d..ab6ffe986c 100644 --- a/meta/recipes-connectivity/dhcpcd/dhcpcd_9.4.1.bb +++ b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.4.1.bb | |||
@@ -32,8 +32,11 @@ PACKAGECONFIG[ntp] = "--with-hook=ntp, , ,ntp" | |||
32 | PACKAGECONFIG[chrony] = "--with-hook=ntp, , ,chrony" | 32 | PACKAGECONFIG[chrony] = "--with-hook=ntp, , ,chrony" |
33 | PACKAGECONFIG[ypbind] = "--with-eghook=yp, , ,ypbind-mt" | 33 | PACKAGECONFIG[ypbind] = "--with-eghook=yp, , ,ypbind-mt" |
34 | 34 | ||
35 | # add option to override DBDIR location | ||
36 | DBDIR ?= "${localstatedir}/lib/${BPN}" | ||
37 | |||
35 | EXTRA_OECONF = "--enable-ipv4 \ | 38 | EXTRA_OECONF = "--enable-ipv4 \ |
36 | --dbdir=${localstatedir}/lib/${BPN} \ | 39 | --dbdir=${DBDIR} \ |
37 | --sbindir=${base_sbindir} \ | 40 | --sbindir=${base_sbindir} \ |
38 | --runstatedir=/run \ | 41 | --runstatedir=/run \ |
39 | --enable-privsep \ | 42 | --enable-privsep \ |
@@ -43,15 +46,15 @@ EXTRA_OECONF = "--enable-ipv4 \ | |||
43 | " | 46 | " |
44 | 47 | ||
45 | USERADD_PACKAGES = "${PN}" | 48 | USERADD_PACKAGES = "${PN}" |
46 | USERADD_PARAM:${PN} = "--system -d ${localstatedir}/lib/${BPN} -M -s /bin/false -U dhcpcd" | 49 | USERADD_PARAM:${PN} = "--system -d ${DBDIR} -M -s /bin/false -U dhcpcd" |
47 | 50 | ||
48 | do_install:append () { | 51 | do_install:append () { |
49 | # install systemd unit files | 52 | # install systemd unit files |
50 | install -d ${D}${systemd_system_unitdir} | 53 | install -d ${D}${systemd_system_unitdir} |
51 | install -m 0644 ${WORKDIR}/dhcpcd*.service ${D}${systemd_system_unitdir} | 54 | install -m 0644 ${WORKDIR}/dhcpcd*.service ${D}${systemd_system_unitdir} |
52 | 55 | ||
53 | chmod 700 ${D}${localstatedir}/lib/${BPN} | 56 | chmod 700 ${D}${DBDIR} |
54 | chown dhcpcd:dhcpcd ${D}${localstatedir}/lib/${BPN} | 57 | chown dhcpcd:dhcpcd ${D}${DBDIR} |
55 | } | 58 | } |
56 | 59 | ||
57 | FILES:${PN}-dbg += "${libdir}/dhcpcd/dev/.debug" | 60 | FILES:${PN}-dbg += "${libdir}/dhcpcd/dev/.debug" |