Christoph Reiter 38126d763e makedepend on autotools for packages using configure
In some cases this will introduce cycles which could likely be cleaned
up by only depending on some unix tools instead of the whole autotools.

Rebuilding doesn't make much sense at this point since it just adds a subset
of base-devel which is still installed by default.
2021-12-12 14:20:50 +01:00

46 lines
1.1 KiB
Bash

_realname=byacc
pkgname=btyacc
pkgver=20210619
pkgrel=1
pkgdesc="btyacc - an LALR(1) parser generator with support for backtracking"
arch=('i686' 'x86_64')
url="https://invisible-island.net/byacc"
license=('Public Domain')
groups=('base-devel')
makedepends=('autotools')
source=("${_realname}-${pkgver}.tar.gz::https://github.com/ThomasDickey/byacc-snapshots/archive/t${pkgver}.tar.gz")
sha256sums=('d19fc22dd1d5e5b18a4abfd2470a1513a2b8b2962f7fb94c21e6109ea571bfc0')
prepare() {
cd ${_realname}-snapshots-t${pkgver}
autoreconf -vfi
}
build() {
cd ${_realname}-snapshots-t${pkgver}
mkdir -p build-${MSYSTEM_CHOST}
pushd build-${MSYSTEM_CHOST}
../configure -C \
--enable-btyacc \
--program-prefix=bt \
--with-max-table-size=18000 \
--program-transform-name='s,\^,bt,'
make
}
check() {
cd ${_realname}-snapshots-t${pkgver}/build-${MSYSTEM_CHOST}
make check
}
package() {
cd ${_realname}-snapshots-t${pkgver}
mkdir -p "${pkgdir}/usr/share/licenses/${pkgname}"
cp -pv package/debian/copyright "${pkgdir}/usr/share/licenses/${pkgname}"
cd build-${MSYSTEM_CHOST}
make DESTDIR=${pkgdir} install
}