blob: c339be8f4ed900bf39c7eb3c988c378b680499f3 (
plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
|
# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Leo <thinkabit.ukim@gmail.com>
pkgname=spdlog
pkgver=1.5.0
pkgrel=1
pkgdesc="Fast C++ logging library"
url="https://github.com/gabime/spdlog"
arch="all"
license="MIT"
makedepends="cmake fmt-dev"
subpackages="$pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/gabime/spdlog/archive/v$pkgver.tar.gz
cassert.patch
"
build() {
mkdir build
cd build
if [ "$CBUILD" != "$CHOST" ]; then
CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
fi
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
-DSPDLOG_BUILD_BENCH=OFF \
-DSPDLOG_BUILD_TESTS=ON \
-DSPDLOG_SANITIZE_ADDRESS=OFF \
-DSPDLOG_FMT_EXTERNAL=ON \
-DSPDLOG_BUILD_SHARED=ON \
-DSPDLOG_BUILD_EXAMPLE=OFF \
${CMAKE_CROSSOPTS} ..
make
}
check() {
cd build
make test
}
package() {
mkdir -p "$pkgdir"
make -C build DESTDIR="$pkgdir" install
}
sha512sums="78991c943dd95af563c4b29545b9b5d635caf1af5031262dde734ecf70c0b4ae866d954ee77b050f9f0cc089a3bc57ee9583895e51cb00dd1cc6c10ff905ca34 spdlog-1.5.0.tar.gz
f3db0d78bcb6a3e29a061a67cec1583a2f4aee2ecd3309b29315f5c205482dc271eadac49ff186ec36547ab2e7c429b090da73bead82a8bed15b514af53710d8 cassert.patch"
|