# Maintainer: Joćo Guerra <joca.bt@gmail.com>

pkgname="ctags"
pkgver="5.8"
pkgrel="2"
pkgdesc="Generate tag files for source code"
arch=("i686" "x86_64")
url="https://ctags.sourceforge.io/"
license=("GPL")
source=("https://sourceforge.net/projects/ctags/files/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz")
sha256sums=('0e44b45dcabe969e0bbbb11e30c246f81abe5d32012db37395eb57d66e9e99c7')

build () {
  cd "${pkgname}-${pkgver}"
  ./configure --prefix=/usr \
              --enable-etags \
              --enable-macro-patterns \
              --with-readlib
  make
}

package () {
  cd "${pkgname}-${pkgver}"
  make prefix="${pkgdir}/usr" install
  install -Dm0644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
