blob: 0f4df5a7f8d6b9fc3148139d85f49d4197b3649a (
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
77
78
79
80
81
82
83
84
85
86
|
# Contributor: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
# Maintainer: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
pkgname=zoneminder
pkgver=1.27.0
pkgrel=4
pkgdesc="Video camera surveillance system"
url="http://www.zoneminder.com/"
arch="x86_64"
license="GPL2+"
depends="ffmpeg libbz2 libjpeg-turbo pcre perl perl-archive-zip perl-date-manip x264
perl-dbd-mysql perl-dbi perl-device-serialport perl-libwww perl-mail-tools
perl-mime-lite perl-mime-tools perl-sys-mmap perl-time-hires php php-mysql sudo"
makedepends="autoconf automake bash bzip2-dev ffmpeg-dev gnutls-dev
libgcrypt-dev libjpeg-turbo-dev mysql-dev pcre-dev perl-dev
php-cli"
install=$pkgname.post-upgrade
subpackages=$pkgname-doc
source="zoneminder-$pkgver.tar.gz::https://github.com/ZoneMinder/ZoneMinder/archive/v${pkgver}.tar.gz
$pkgname.initd
musl-fix.patch
zm-additional.conf"
_builddir=$srcdir/ZoneMinder-$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"
./bootstrap.sh || return 1
ZM_LOGDIR=/var/log/zoneminder \
ZM_RUNDIR=/var/run \
ZM_TMPDIR=/tmp \
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--enable-mmap=yes \
--enable-crashtrace=no \
--enable-debug=no \
--with-webdir=/usr/share/webapps/$pkgname/htdocs \
--with-cgidir=/usr/share/webapps/$pkgname/cgi-bin \
|| return 1
make || return 1
}
package() {
cd "$_builddir"
local dir
make install DESTDIR=$pkgdir
rmdir "$pkgdir/tmp"
find "$pkgdir" -name perllocal.pod -delete
echo -n $pkgver > "$pkgdir/usr/share/$pkgname/version"
install -D -m 755 "$srcdir/$pkgname.initd" "$pkgdir/etc/init.d/$pkgname"
#move storage to var/lib where it belongs.
for dir in events images; do
install -m 755 -d "$pkgdir"/var/lib/zoneminder/$dir
rmdir "$pkgdir"/usr/share/webapps/zoneminder/htdocs/$dir
ln -sf /var/lib/zoneminder/$dir \
"$pkgdir"/usr/share/webapps/zoneminder/htdocs/$dir || return 1
done
for dir in lib/zoneminder/sock lib/zoneminder/swap spool/zoneminder-upload \
log/zoneminder; do
install -m 755 -d "$pkgdir"/var/"$dir"
done
# update config with new locations
cat "$srcdir"/zm-additional.conf >> "$pkgdir"/etc/zm.conf
}
md5sums="9ff149baa1a0d04931fbafcdb3200fab zoneminder-1.27.0.tar.gz
0a83db1802b960b03bc45763396093e5 zoneminder.initd
d148970bda67b1e257bb3e1f48404f91 musl-fix.patch
72404aa3ebda3f6066b6cdb61fae3b85 zm-additional.conf"
sha256sums="2f31c10e6c5930aedfa9f08edfa074ef1b168e5bdffb77a147d4e631bfb03ef2 zoneminder-1.27.0.tar.gz
a98e9a35a367f89c577ea9e8ca1e4ae63a80e396e46bbd3afc70c7e5e266d580 zoneminder.initd
d5c1ce946c44e1979cc144f36930827da725919b9d53c1aee0e8749c4ff719d9 musl-fix.patch
29907ea8b6703e1b37769edc1d9cbe5e0a613e4fad1bee76285963d33b600cdb zm-additional.conf"
sha512sums="8a349558399381a9062365ddc8bd8f815e3800929914096b2e4ea63e4d6dd12054f7b849fab5bea4bcfc87ea60739479a55734c7075a74aab0622d35f1d2bb14 zoneminder-1.27.0.tar.gz
f4da24fa424d447a917b0f004745bf1014b92494dc33ef1e78e331d70068897feaa173e1bedeae968203569dbd0b90e80d1e3ca19f96b816b09f3da17b24b4e1 zoneminder.initd
b62533a7d025afb9852b9ac6b10b20f030a900f34b16808f655c8e558a2bcf62c1913e278d7a6c8c600d0e4844d846c8cec43a9daf78332da2c1e8816a65776f musl-fix.patch
eb03c96e66e848523482bd64e5f5450b84adc30afe79635187a4631e353bac81a993a5adb9e6d6b2bda76132e864be878d950a593c8d5a7900b23d0204737c47 zm-additional.conf"
|