wireguard-tools: Ensure make clean target is run properly

When S is pointing to a level up, it calls clean target which also tries
to clean the module build objects, which causes make clean to misnehave
since the env is not set to build module and it tries to reach out to
/lib/modules dir on host

Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Khem Raj 2020-03-29 20:12:40 -07:00
parent 4cb9812277
commit 75bf0b0e04

View File

@ -1,15 +1,14 @@
require wireguard.inc
LIC_FILES_CHKSUM = "file://../../COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
inherit bash-completion systemd pkgconfig
DEPENDS = "wireguard-module libmnl"
DEPENDS += "wireguard-module libmnl"
do_compile_prepend () {
cd ${S}/tools
}
S = "${WORKDIR}/WireGuard-${PV}/src/tools"
do_install () {
cd ${S}/tools
oe_runmake DESTDIR="${D}" PREFIX="${prefix}" SYSCONFDIR="${sysconfdir}" \
SYSTEMDUNITDIR="${systemd_unitdir}" \
WITH_SYSTEMDUNITS=${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'yes', '', d)} \