blob: d77f797c1e51f968e54791e77b6d973813051dea (
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
67
68
69
70
71
72
73
74
75
76
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=postgresql
pkgver=9.2.1
pkgrel=1
pkgdesc="A sophisticated object-relational DBMS"
url="http://www.postgresql.org/"
arch="all"
license="BSD"
depends="postgresql-client"
install="$pkgname.pre-upgrade"
depends_dev="readline-dev openssl-dev zlib-dev libxml2-dev"
makedepends="$depends_dev"
subpackages="$pkgname-dev $pkgname-doc libpq $pkgname-client"
patches="initdb.patch"
source="ftp://ftp.$pkgname.org/pub/source/v$pkgver/$pkgname-$pkgver.tar.bz2
$patches
$pkgname.initd
$pkgname.confd
pg-restore.initd
pg-restore.confd
"
_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
cd "$_builddir"
for i in $patches; do
msg $i
patch -p1 -i "$srcdir"/$i || return 1
done
}
build() {
cd "$_builddir"
./configure --prefix=/usr \
--mandir=/usr/share/man \
--with-openssl \
|| return 1
make world || return 1
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install install-docs || return 1
install -D -m755 "$srcdir"/postgresql.initd \
"$pkgdir"/etc/init.d/postgresql || return 1
install -D -m644 "$srcdir"/postgresql.confd \
"$pkgdir"/etc/conf.d/postgresql || return 1
install -D -m755 "$srcdir"/pg-restore.initd \
"$pkgdir"/etc/init.d/pg-restore || return 1
install -D -m644 "$srcdir"/pg-restore.confd \
"$pkgdir"/etc/conf.d/pg-restore || return 1
}
libpq() {
depends=
pkgdesc="PostgreSQL libraries"
mkdir -p "$subpkgdir"/usr/lib
mv "$pkgdir"/usr/lib/libpq.so* "$subpkgdir"/usr/lib/
}
client() {
depends=
pkgdesc="PostgreSQL client"
mkdir -p "$subpkgdir"/usr/bin
mv "$pkgdir"/usr/bin/psql "$subpkgdir"/usr/bin/
}
md5sums="c0b4799ea9850eae3ead14f0a60e9418 postgresql-9.2.1.tar.bz2
de29e4cea00a3318a77587fbbc7b6243 initdb.patch
01cc8d4a4cbc77a7b6f84344155232d5 postgresql.initd
ca9759d29dc86402858821d5fdec48a1 postgresql.confd
d2a51db4436e550d56bb1e96699faef4 pg-restore.initd
bf45384752b320b369f1425939763178 pg-restore.confd"
|