summaryrefslogtreecommitdiff
path: root/meta-google/recipes-google/networking/gbmc-ip-monitor.bb
blob: 1bf35bc9ca0e157f5fe5b92d521d51f92ad1e8ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
SUMMARY = "Allows hooking netlink events to perform network actions"
PR = "r1"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"

inherit systemd

SRC_URI += " \
  file://gbmc-ip-monitor.service \
  file://gbmc-ip-monitor.sh \
  file://gbmc-ip-monitor-test.sh \
  "

S = "${WORKDIR}"

DEPENDS += "test-sh"

RDEPENDS:${PN} += " \
  bash \
  iproute2 \
  "

SYSTEMD_SERVICE:${PN} += "gbmc-ip-monitor.service"

do_compile() {
  SYSROOT="$PKG_CONFIG_SYSROOT_DIR" bash gbmc-ip-monitor-test.sh || exit
}

do_install:append() {
  install -d -m0755 ${D}${libexecdir}
  install -m0755 gbmc-ip-monitor.sh ${D}${libexecdir}/

  install -d -m0755 ${D}${systemd_system_unitdir}
  install -m0644 gbmc-ip-monitor.service ${D}${systemd_system_unitdir}/
}