aboutsummaryrefslogtreecommitdiffstats
path: root/community/racktables/APKBUILD
blob: 13f0b53ae0a28d6bfb53b1f78d766e6c1fc31789 (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
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=racktables
_realname=RackTables
pkgver=0.20.10
pkgrel=1
pkgdesc="Server room asset management"
url="http://racktables.org"
arch="noarch"
license="GPL2"
depends="php php-bcmath php-gd php-mysql php-pdo_mysql php-json"
depends_dev=
makedepends="$depends_dev"
install=
subpackages="$pkgname-doc"
pkggroups="www-data"
source="http://downloads.sourceforge.net/project/$pkgname/$_realname-${pkgver}.tar.gz
	slow-pages.patch"


_builddir="$srcdir"/$_realname-$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"
	#make DESTDIR="$pkgdir"
	return 0
}

package() {
	cd "$_builddir"
	export prefix="/usr/share/webapps"
	export datadir="${prefix}"
	export docdir="/usr/share/doc/RackTables"
	make DESTDIR="${pkgdir}" install
	make DESTDIR="${pkgdir}" install-docs
	mkdir -p "$pkgdir"/etc/racktables
	chown :www-data "$pkgdir"/etc/racktables
	chmod 770 "$pkgdir"/etc/racktables
	sed -i "s%<?php%<?php\n\n\$racktables_confdir = '/etc/racktables';%" \
	 "$pkgdir"/usr/share/webapps/RackTables/wwwroot/index.php
}

md5sums="0b1d04522216f0ecafe83823f9a56391  RackTables-0.20.10.tar.gz
4dcbd2ed05176ab5767f1c29f8eff8dd  slow-pages.patch"
sha256sums="b418926bc726cebec0f29b6b7c73eae33e474c0ea05aae05f45afe035478d12b  RackTables-0.20.10.tar.gz
c8528768ff3724f66235185e24455479c0169f926c3175f3cf5f88f5170bcb14  slow-pages.patch"
sha512sums="2e985e4fb8aa2ebca0ed17729c918eeecfde09c3962bf6cefff719fb6e9394aca31e585f81eb4e9d201d40710220edccdce5b99967ac0fd630fb47f7906d261e  RackTables-0.20.10.tar.gz
7501e0346e4bc34e950e1e6b90b4f22ec137c2416a973e4ed5ec3280d3811bcc64894f145ee0be988208029ed3524b776b51228b5515995af9f0145a88ada47d  slow-pages.patch"