desktop/ccache/PKGBUILD
2019-01-10 01:52:49 +01:00

34 lines
1000 B
Bash

pkgname=ccache
pkgver=3.5.1a
pkgrel=1
pkgdesc="A compiler cache."
url="https://ccache.samba.org/"
license=('GPL3')
arch=('x86_64')
depends=('zlib')
source=(https://samba.org/ftp/$pkgname/$pkgname-$pkgver.tar.xz)
sha256sums=('0baea2c5bc4169ed3dad1f895e6d279323c5b8d3c9f0209998fe6da4601d0701')
build() {
cd $srcdir/${pkgname}-${pkgver/a/}
./configure --prefix=/usr --sysconfdir=/etc
make
}
package() {
cd $srcdir/${pkgname}-${pkgver/a/}
install -Dm 755 ccache -t "${pkgdir}/usr/bin"
install -Dm 644 doc/ccache.1 -t "${pkgdir}/usr/share/man/man1"
install -Dm 644 doc/{AUTHORS,MANUAL,NEWS}.adoc README.md -t "${pkgdir}/usr/share/doc/${pkgname}"
install -d "${pkgdir}/usr/lib/ccache/bin"
local _prog
for _prog in gcc g++ c++; do
ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/$_prog"
ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/${CHOST}-$_prog"
done
for _prog in cc clang clang++; do
ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/$_prog"
done
}