summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 66a711c324ac3ccd518c026324038aefcd166cb8 (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
# Maintainer: Dario Ostuni <another.code.996@gmail.com>
pkgname=python-wasmtime
pkgver=0.25.0
pkgrel=1
pkgdesc="Python 3 extension for interface with Wasmtime/Cranelift."
arch=('x86_64' 'aarch64')
url="https://github.com/bytecodealliance/wasmtime-py"
license=('APACHE2')
depends=('python' 'python-setuptools' 'python-wheel' 'wasmtime')
makedepends=('git')
options=(!emptydirs)
source=("${pkgname}-${pkgver}::git+https://github.com/bytecodealliance/wasmtime-py.git#tag=${pkgver}")
sha384sums=('SKIP')

prepare() {
    cd "${srcdir}/${pkgname}-${pkgver}"
    git submodule update --init --recursive
}


package() {
    cd "${srcdir}/${pkgname}-${pkgver}"
    python setup.py install --root="$pkgdir/" --optimize=1
    PP="${pkgdir}/""$(python -c "import setuptools as _; print(_.__path__[0][:-10])")""wasmtime/""linux-$(uname -m)"
    mkdir "${PP}"
    ln -sf "/usr/lib/libwasmtime.so" "${PP}/_libwasmtime.so"
}