# Maintainer: Daniel Hejduk <danielhejduk@disroot.org>
pkgname=cc65
pkgver=2.19
pkgrel=0
pkgdesc="Compiler Suite for 6502 based processors"
url="https://cc65.github.io/"
arch="all"
license="Zlib"
makedepends="make git"
options="!check" # FIXME
source="$pkgname-$pkgver.tar.gz::https://github.com/cc65/cc65/archive/V$pkgver.tar.gz"

build() {
	# the build system does not work in parallel
	PREFIX=/usr make -j1
}

check() {
	# parallel tests are broken https://github.com/cc65/cc65/issues/2419
	make -j1 -C test --no-print-directory
}

package() {
	PREFIX="$pkgdir/usr" make install
}

sha512sums="
e893359249588247d262ff19b8b7efbbcb10a274964aaa18cfe21830cce39da53831262bcc8ee4678158c0e0ab56905411b037699d1097aa5fc03edf7d6bea8f  cc65-2.19.tar.gz
"
