Files
LFS-PKGBUILDs/lfs-12.2-systemd/bc-6.7.6.PKGBUILD

30 lines
695 B
Plaintext

pkgname=bc
pkgver=6.7.6
pkgdesc='An arbitrary precision calculator language'
homepage="https://git.gavinhoward.com/gavin/bc"
license=('GPL-3.0-only')
sources=("${pkgname}-${pkgver}.tar.xz")
urls=("https://github.com/gavinhoward/bc/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.xz")
md5sums=("a47aa5e4e7395fbcd159a9228613b97b")
options=(!strip)
src_prepare() {
tar -xf ${DIST_DIR}/${pkgname}-${pkgver}/${sources[0]} --strip-components=1
}
src_build() {
CFLAGS+=" -O3 -flto -Werror=odr -Werror=lto-type-mismatch -Werror=strict-aliasing" \
CC=gcc \
./configure --prefix=/usr -G -r
make
}
src_check() {
make test
}
src_install() {
make DESTDIR="$pkgdir" install
}