summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: dd13e1bcb83bd710261875b6e45bf7826728fcbf (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
# Maintainer: Gonzalo Exequiel Pedone <hipersayan DOT x AT gmail DOT com>
# Contributor: David Runge <dvzrv@archlinux.org>

_android_arch=armv7a-eabi

pkgname=android-${_android_arch}-zix
pkgver=0.4.2
pkgrel=1
arch=('any')
pkgdesc="A lightweight C99 portability and data structure library (Android ${_android_arch})"
url="https://gitlab.com/drobilla/zix"
license=('0BSD OR ISC')
depends=('android-ndk')
makedepends=('android-meson')
options=(!strip !buildflags staticlibs !emptydirs)
source=("https://download.drobilla.net/zix-$pkgver.tar.xz"{,.sig})
md5sums=('87999e25b0440789d1a8325b00a02ed4'
         'SKIP')
validpgpkeys=('907D226E7E13FA337F014A083672782A9BF368F3') # David Robillard <d@drobilla.net>

build() {
    cd "${srcdir}/zix-${pkgver}"
    source android-env ${_android_arch}

    mkdir -p build
    cd build
    android-${_android_arch}-meson \
        --default-library both \
        -D benchmarks=disabled  \
        -D docs=disabled \
        -D html=disabled  \
        -D lint=false \
        -D singlehtml=disabled \
        -D tests=disabled \
        -D tests_cpp=disabled
    ninja
}

package() {
    cd "${srcdir}/zix-${pkgver}/build"
    source android-env ${_android_arch}

    DESTDIR="${pkgdir}" ninja install
    ${ANDROID_STRIP} -g "$pkgdir"/${ANDROID_PREFIX_LIB}/*.a || true
    ${ANDROID_STRIP} -g --strip-unneeded "${pkgdir}"/${ANDROID_PREFIX_LIB}/*.so
    ${ANDROID_RANLIB} "$pkgdir"/${ANDROID_PREFIX_LIB}/*.a || true
}