blob: f860d4e96d813a37efdd2006b9240d52de7dfe51 (
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
|
pkgname=wasi-sdk-git
pkgver=r121.77ba98a
pkgrel=1
pkgdesc="WASI-enabled WebAssembly C/C++ toolchain (from git repo)"
arch=("x86_64")
license=('Apache')
depends=(clang lld)
makedepends=(cmake git)
source=('git+https://github.com/WebAssembly/wasi-sdk.git'
'git+https://git.savannah.gnu.org/git/config.git'
'git+https://github.com/llvm/llvm-project.git'
'git+https://github.com/WebAssembly/wasi-libc.git')
md5sums=('SKIP'
'SKIP'
'SKIP'
'SKIP')
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
options=('!strip' 'staticlibs')
prepare() {
cd "$srcdir/${pkgname%-git}"
git submodule init
git config submodule.src/config.url "$srcdir/config"
git config submodule.src/llvm-project.url "$srcdir/llvm-project"
git config submodule.src/wasi-libc.url "$srcdir/wasi-libc"
git submodule update
}
pkgver() {
cd "$srcdir/${pkgname%-git}"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
build() {
cd "$srcdir/${pkgname%-git}"
make \
PREFIX=/opt/wasi-sdk \
build/wasi-libc.BUILT \
build/libcxx.BUILT \
build/libcxxabi.BUILT
}
package() {
cd "$srcdir/${pkgname%-git}"
make install INSTALL_DIR="$pkgdir"
}
|