summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: fbb56928ab083fca6430aaf710c720d5889dc203 (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
# Maintainer: Daniel Bermond <dbermond@archlinux.org>

pkgname=cs-string
pkgver=1.4.0
pkgrel=2
pkgdesc='Standalone library for unicode aware string support'
arch=('x86_64')
url='https://www.copperspice.com/'
license=('BSD-2-Clause')
makedepends=('cmake') #'catch2'
source=("https://github.com/copperspice/cs_string/archive/string-${pkgver}/${pkgname}-${pkgver}.tar.gz")
sha256sums=('f264994bb869916f59d356f451c3eecc6171565ae9bf828292bd3d7d14168db3')

build() {
    cmake -B build -S "cs_string-string-${pkgver}" \
        -DCMAKE_BUILD_TYPE:STRING='None' \
        -DCMAKE_INSTALL_PREFIX:PATH='/usr' \
        -DBUILD_TESTS:BOOL='OFF' \
        -Wno-dev
    cmake --build build
}

check() {
    ctest --test-dir build --output-on-failure
}

package() {
    DESTDIR="$pkgdir" cmake --install build
    install -D -m644 "cs_string-string-${pkgver}/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}"
}