aboutsummaryrefslogblamecommitdiffstats
path: root/community/bear/APKBUILD
blob: 4e5aa336ba2e7cc9311b246df68159ecc33cd994 (plain) (tree)
1
2
3
4
5
6
7
8
9


                                                              
             
        

                                                                       

                                            
                          
                                                              
                                                                
                              
                          
                                                                             

                               






                                                              




                                             
                                                         

                                       







                                           
                                               

 
            
                                                                                                                                                    
 
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net>
pkgname=bear
pkgver=3.0.18
pkgrel=1
pkgdesc="Tool which generates a compilation database for clang tooling"
url="https://github.com/rizsotto/Bear"
# s390x ppc64le armv7 armhf: Limited by grpc
arch="all !s390x !ppc64le !armv7 !armhf"
license="GPL-3.0-or-later"
makedepends="cmake grpc grpc-dev fmt-dev spdlog-dev sqlite-dev
	nlohmann-json protobuf-dev gtest-dev c-ares-dev re2-dev"
checkdepends="llvm-test-utils"
subpackages="$pkgname-doc"
source="https://github.com/rizsotto/Bear/archive/$pkgver/bear-$pkgver.tar.gz"
builddir="$srcdir/Bear-$pkgver"

prepare() {
	default_prepare
	sed -i "s|/usr/bin/env python|/usr/bin/env python3|" \
		test/bin/assert_compilation \
		test/bin/assert_intercepted
}

build() {
	cmake -B build \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_SHARED_LIBS=True \
		-DCMAKE_INSTALL_LIBEXECDIR=libexec/bear \
		-DCMAKE_BUILD_TYPE=None
	cmake --build build
}

check() {
	cd build
	ctest --verbose --output-on-failure
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
758ee9edac0617caa98d58ea0a3eacf644b9cc5dcd64013475d0a72918f29b37a98793c731d7c885c821c46a7b100fb265a3d4d31e35e9ff2d30bb331265b72b  bear-3.0.18.tar.gz
"