pkgname=gc pkgver=8.2.6 _pkgver=8.2.6 pkgrel=1 pkgdesc="A garbage collector for C and C++" arch=('x86_64') url="https://www.hboehm.info/gc/" license=('GPL') depends=('gcc-libs') options=('!libtool') source=("https://github.com/ivmai/bdwgc/releases/download/v${_pkgver}/${pkgname}-${_pkgver}.tar.gz") md5sums=('fc5351214bc2e854070ee3319181a467') build() { cd ${pkgname}-${pkgver} sed -i 's|pkgdata|doc|' doc/doc.am autoreconf -fi ./configure --prefix=/usr --enable-cplusplus --disable-static make } package() { cd ${pkgname}-${pkgver} make DESTDIR=${pkgdir} install sed -i -e 's/GC_MALLOC 1L/gc 3/' doc/gc.man install -m755 -d ${pkgdir}/usr/share/man/man3 install -m644 doc/gc.man ${pkgdir}/usr/share/man/man3/gc.3 }