aboutsummaryrefslogtreecommitdiffstats
path: root/main/ninja/APKBUILD
blob: 323d38d7c700e46134cbbb33191954d8489c40b7 (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: k0r10n <k0r10n.dev@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=ninja
pkgver=1.7.2
pkgrel=0
pkgdesc="Small build system with a focus on speed"
url="https://ninja-build.org/"
arch="all"
license="Apache"
depends=""
depends_dev=""
makedepends="$depends_dev asciidoc python2 re2c gtest"
install=""
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/martine/ninja/archive/v$pkgver.tar.gz"

builddir="$srcdir"/${pkgname}-${pkgver}
prepare() {
	local i
	cd "$builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$builddir"
	python2 ./configure.py --bootstrap || return 1
	asciidoc doc/manual.asciidoc || return 1
}

package() {
	cd "$builddir"
	install -m755 -D ninja "$pkgdir/usr/bin/ninja" || return 1
	install -m644 -D doc/manual.asciidoc \
		"$pkgdir/usr/share/doc/ninja/manual.asciidoc" || return 1
	install -m644 -D doc/manual.html \
		"$pkgdir/usr/share/doc/ninja/manual.html" || return 1
	
	install -m644 -D misc/bash-completion \
		"$pkgdir/usr/share/bash-completion/completions/ninja" || return 1
}

md5sums="7b482218757acbaeac4d4d54a3cd94e1  ninja-1.7.2.tar.gz"
sha256sums="2edda0a5421ace3cf428309211270772dd35a91af60c96f93f90df6bc41b16d9  ninja-1.7.2.tar.gz"
sha512sums="29900d07364d87ad8b9614b82bc1b0afda5ca6522563ab73fb228f206ed6b29b70cf034a3caf5a9b2c0b105d1e076c6b425d93b5d14aa3ca3730d75611212a64  ninja-1.7.2.tar.gz"