Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 1 | SECTION = "console/network" |
| 2 | SUMMARY = "dhcpcd - a DHCP client" |
| 3 | DESCRIPTION = "dhcpcd runs on your machine and silently configures your \ |
| 4 | computer to work on the attached networks without trouble \ |
| 5 | and mostly without configuration." |
| 6 | |
| 7 | HOMEPAGE = "http://roy.marples.name/projects/dhcpcd/" |
| 8 | |
| 9 | LICENSE = "BSD-2-Clause" |
Patrick Williams | e760df8 | 2023-05-26 11:10:49 -0500 | [diff] [blame] | 10 | LIC_FILES_CHKSUM = "file://LICENSE;md5=ba9c7e534853aaf3de76c905b2410ffd" |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 11 | |
Patrick Williams | e760df8 | 2023-05-26 11:10:49 -0500 | [diff] [blame] | 12 | SRC_URI = "git://github.com/NetworkConfiguration/dhcpcd;protocol=https;branch=master \ |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 13 | file://0001-remove-INCLUDEDIR-to-prevent-build-issues.patch \ |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 14 | file://0001-20-resolv.conf-improve-the-sitation-of-working-with-.patch \ |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 15 | file://dhcpcd.service \ |
| 16 | file://dhcpcd@.service \ |
Andrew Geissler | fc113ea | 2023-03-31 09:59:46 -0500 | [diff] [blame] | 17 | file://0001-dhcpcd.8-Fix-conflict-error-when-enable-multilib.patch \ |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 18 | " |
| 19 | |
Patrick Williams | e760df8 | 2023-05-26 11:10:49 -0500 | [diff] [blame] | 20 | SRCREV = "5d9bf80c26b4b7dc9d8aa175d96d5a24e75b4d48" |
Andrew Geissler | 028142b | 2023-05-05 11:29:21 -0500 | [diff] [blame] | 21 | S = "${WORKDIR}/git" |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 22 | |
| 23 | inherit pkgconfig autotools-brokensep systemd useradd |
| 24 | |
| 25 | SYSTEMD_SERVICE:${PN} = "dhcpcd.service" |
| 26 | |
| 27 | PACKAGECONFIG ?= "udev ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}" |
| 28 | |
| 29 | PACKAGECONFIG[udev] = "--with-udev,--without-udev,udev,udev" |
| 30 | PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6" |
| 31 | # ntp conflicts with chrony |
| 32 | PACKAGECONFIG[ntp] = "--with-hook=ntp, , ,ntp" |
| 33 | PACKAGECONFIG[chrony] = "--with-hook=ntp, , ,chrony" |
| 34 | PACKAGECONFIG[ypbind] = "--with-eghook=yp, , ,ypbind-mt" |
| 35 | |
Andrew Geissler | 7e0e3c0 | 2022-02-25 20:34:39 +0000 | [diff] [blame] | 36 | # add option to override DBDIR location |
| 37 | DBDIR ?= "${localstatedir}/lib/${BPN}" |
| 38 | |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 39 | EXTRA_OECONF = "--enable-ipv4 \ |
Andrew Geissler | 7e0e3c0 | 2022-02-25 20:34:39 +0000 | [diff] [blame] | 40 | --dbdir=${DBDIR} \ |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 41 | --sbindir=${base_sbindir} \ |
| 42 | --runstatedir=/run \ |
| 43 | --enable-privsep \ |
| 44 | --privsepuser=dhcpcd \ |
| 45 | --with-hooks \ |
| 46 | --with-eghooks \ |
| 47 | " |
| 48 | |
| 49 | USERADD_PACKAGES = "${PN}" |
Andrew Geissler | 7e0e3c0 | 2022-02-25 20:34:39 +0000 | [diff] [blame] | 50 | USERADD_PARAM:${PN} = "--system -d ${DBDIR} -M -s /bin/false -U dhcpcd" |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 51 | |
| 52 | do_install:append () { |
| 53 | # install systemd unit files |
| 54 | install -d ${D}${systemd_system_unitdir} |
| 55 | install -m 0644 ${WORKDIR}/dhcpcd*.service ${D}${systemd_system_unitdir} |
| 56 | |
Andrew Geissler | 7e0e3c0 | 2022-02-25 20:34:39 +0000 | [diff] [blame] | 57 | chmod 700 ${D}${DBDIR} |
| 58 | chown dhcpcd:dhcpcd ${D}${DBDIR} |
Andrew Geissler | eff2747 | 2021-10-29 15:35:00 -0500 | [diff] [blame] | 59 | } |
| 60 | |
| 61 | FILES:${PN}-dbg += "${libdir}/dhcpcd/dev/.debug" |