1 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
2 # Contributor: Giovanni Scafora <giovanni@archlinux.org>
3 # Contributor: Tom Newsom <Jeepster@gmx.co.uk>
8 pkgdesc='Compiler cache that speeds up recompilation by caching previous compilations'
9 url='https://ccache.dev/'
12 depends=('glibc' 'gcc-libs' 'hiredis' 'zstd' 'libzstd.so')
13 makedepends=('cmake' 'asciidoctor' 'perl')
14 source=(https://github.com/ccache/ccache/releases/download/v${pkgver}/ccache-${pkgver}.tar.xz{,.asc})
15 validpgpkeys=('5A939A71A46792CF57866A51996DDA075594ADB8') # Joel Rosdahl <joel@rosdahl.net>
16 sha512sums=('561424d448a049971742b846429c2fa5f1df43c05f201610dab0a3fab7e4806589c14ca20875cb5733763603c0813fe9350a244b63dda03e9def95d547738d0b'
18 b2sums=('5cca7d49088c5391abf93a2a493ba8e120575ae834abae86f3669e8c883a93ec29d48ab934aa086a87feb6a08d0c0053b3ce7174cec2f342c2d695a93fa3ef9a'
22 cd ${pkgname}-${pkgver}
24 -DCMAKE_INSTALL_PREFIX=/usr \
25 -DCMAKE_BUILD_TYPE=None \
29 make VERBOSE=1 -C build
33 cd ${pkgname}-${pkgver}
34 make VERBOSE=1 check -C build
38 cd ${pkgname}-${pkgver}
40 make DESTDIR="${pkgdir}" install -C build
41 make DESTDIR="${pkgdir}" install -C build/doc
43 install -Dm 644 doc/*.md doc/*.adoc -t "${pkgdir}/usr/share/doc/${pkgname}"
45 install -d "${pkgdir}/usr/lib/ccache/bin"
47 for _prog in gcc g++ c++; do
48 ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/$_prog"
49 ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/${CHOST}-$_prog"
51 for _prog in cc clang clang++; do
52 ln -s /usr/bin/ccache "${pkgdir}/usr/lib/ccache/bin/$_prog"