# PKGBUILD pkgver() { cd "$srcdir/home-lab_watchdog_keepalive" git describe --tags | sed 's/^v//;s/-/+/g' } pkgver=0.0.1_DEV pkgname=arduino_watchdog pkgrel=1 pkgdesc="Arduino based external watchdog to keep server online" arch=('any') license=('MIT') makedepends=('cmake>=4.0.0', 'git>=2.50.0') depends=('systemd>=257.6') source=('git+https://git.server.4zellen.se/Zacharias/home-lab_watchdog_keepalive.git') maintainer="Zacharias Zellén " url="https://git.server.4zellen.se/Zacharias/home-lab_watchdog_keepalive.git" install=arduino_watchdog.install sha256sums=('SKIP') build() { cd "$srcdir/home-lab_watchdog_keepalive" cmake -B build -S . -DVERSION="\"$pkgver\"" make -C build } package() { install -Dm755 "$srcdir/home-lab_watchdog_keepalive/build/home_lab_watchdog_keepalive" "$pkgdir/usr/bin/arduino_watchdog" install -Dm755 "$srcdir/home-lab_watchdog_keepalive/arduino-watchdog-heartbeat.service" "$pkgdir/etc/systemd/system/arduino-watchdog-heartbeat.service" install -Dm755 "$srcdir/home-lab_watchdog_keepalive/arduino-watchdog-heartbeat.timer" "$pkgdir/etc/systemd/system/arduino-watchdog-heartbeat.timer" }