blob: 78501cdf4b0f2d4a30f83fdd07921ce458a98a8b (
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
# Contributor: Kiyoshi Aman <kiyoshi.aman@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=protobuf
pkgver=2.6.1
pkgrel=4
pkgdesc="Library for extensible, efficient structure packing"
url="http://code.google.com/p/protobuf/"
arch="all"
license="BSD"
depends=
depends_dev="zlib-dev"
makedepends="$depends_dev autoconf automake libtool"
install=""
subpackages="$pkgname-dev $pkgname-vim"
source="protobuf-$pkgver.tar.gz::https://github.com/google/protobuf/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
./autogen.sh || return 1
}
build() {
cd "$_builddir"
./configure --prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--localstatedir=/var \
|| return 1
make || return 1
make check || return 1
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install || return 1
rm "$pkgdir"/usr/lib/*.la
}
py() {
depends="python"
cd "$_builddir"/python
mkdir -p "$subpkgdir"/usr/lib/python2.6/site-packages/
install -m644 google "$subpkgdir"/usr/lib/python2.6/site-packages
}
vim() {
depends=""
pkgdesc="Vim syntax for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel vim"
arch="noarch"
install -Dm644 "$_builddir"/editors/proto.vim \
"$subpkgdir"/usr/share/vim/vimfiles/syntax/proto.vim
}
md5sums="af05b2cca289f7b86eef2734a0cdc8b9 protobuf-2.6.1.tar.gz"
sha256sums="2667b7cda4a6bc8a09e5463adf3b5984e08d94e72338277affa8594d8b6e5cd1 protobuf-2.6.1.tar.gz"
sha512sums="8a6337e007572b1c5688ad178a18e98e94e62112bbc4ae558b4a3f8fa7f93a9643929ccaf31b94490c9f601328ae3f48dab7b702a2b9c989a5254514c78a4d1e protobuf-2.6.1.tar.gz"
|