#!/usr/bin/bash
# JOBoRun		: Jwm OpenBox Obarun RUNit
# Maintainer		: Joe Bo Run <joborun@disroot.org>
# PkgSource		: url="https://gittea.disroot.org/joborun-pkg/jobextra/$pkgname"
#-----------------------------------------| DESCRIPTION |---------------------------------------

pkgname=re2c
pkgver=3.0
pkgrel=01
arch=(x86_64)
depends=(gcc-libs)
makedepends=(cmake)
checkdepends=(python)
pkgdesc='A tool for generating C-based recognizers from regular expressions'
url='https://re2c.org'
source=(re2c-$pkgver.tar.gz::https://github.com/skvadrik/re2c/archive/$pkgver.tar.gz)

build() {
  cd $pkgname-$pkgver
  cmake -B build -DCMAKE_INSTALL_PREFIX=/usr
  cmake --build build
}

check() {
  cd $pkgname-$pkgver
  cmake --build build --target check
}

package() {
  cd $pkgname-$pkgver
  DESTDIR="$pkgdir" cmake --install build
  install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}

#---- license gpg-key sha256sums ----

license=('public domain')

sha1sums=('ce178a2f31ca4ba266be0ba6f1aa346ef764b799')

sha256sums=(acc6e49ec9638d4a75578f161945567d52bfcb85da998212adaef6328f5bdcc5) # re2c-3.0.tar.gz

######## diffs between old and new Arch PKGBUILD
#### systemd crap in new PKGBUILD 
#scan for systemd ipv6 service & socket
#
