aboutsummaryrefslogtreecommitdiffstats
path: root/community/cpputest/APKBUILD
blob: 1857e3be3ed1eeca476d66a0b5e8833f719c13f7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Contributor: Shiva Velmurugan <shiv@shiv.me>
# Maintainer: Shiva Velmurugan <shiv@shiv.me>
pkgname=cpputest
pkgver=4.0
pkgrel=0
pkgdesc="A unit testing and mocking framework for C/C++"
url="http://cpputest.github.io/"
arch="all !mips !mips64" # FTBFS on soft-float (mips)
license="BSD-3-Clause"
options="!dbg"
makedepends="cmake"
subpackages="$pkgname-static"
source="https://github.com/cpputest/cpputest/releases/download/v$pkgver/cpputest-$pkgver.tar.gz"

build() {
	cmake -B build . \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	make -C build
}

check() {
	make -C build test
}

package() {
	make -C build DESTDIR="$pkgdir" install

	mkdir -p "$pkgdir"/usr/lib/cmake
	mv "$pkgdir"/usr/lib/CppUTest/cmake \
		"$pkgdir"/usr/lib/cmake/CppUTest
	rmdir "$pkgdir"/usr/lib/CppUTest
}

sha512sums="69f39fffdcd965c871e598118db38ddb74a3e75fd7a7965f8d236029fa891f6fcb6b671147c166ad08482bbd0737537fafe90aa8439a0ab62389f19150cc39d7  cpputest-4.0.tar.gz"