system/ZoneMinder: Updated for version 1.31.1.

Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
This commit is contained in:
Gene Baxter 2018-04-30 01:44:39 +01:00 committed by David Spencer
parent c2e0f21049
commit 215eae93b7
5 changed files with 31 additions and 51 deletions

View file

@ -8,9 +8,9 @@ protocols. It can also be integrated into a home automation system
via X.10 or other protocols. This build includes cambozola and jscalendar.
Optional dependencies are ffmpeg (video streaming and recoding support),
perl-Archive-Zip (automatic event uploading), perl-X10
(integration with X10-based home automation), perl-Device-SerialPort
(RS232/RS485 PTZ camera control), perl-MIME-Lite, and perl-MIME-tools
perl-Archive-Zip (automatic event uploading), perl-X10
(integration with X10-based home automation), perl-Device-SerialPort
(RS232/RS485 PTZ camera control), perl-MIME-Lite, and perl-MIME-Entity
(automatic event mail notification).
See README.SLACKWARE for configuration information.

View file

@ -2,7 +2,7 @@ README.SLACKWARE
This build uses the mmap method for camera access, as opposed to shared memory.
That means, there is no need to configure shared memory limits any more.
You can revert back to the shm method by adding -DSM_NO_MMAP=ON to the build.
You can revert back to the shm method by removing --enable-mmap from the build.
To use ZoneMinder, you need to have Apache, PHP and MySQL.
@ -10,19 +10,8 @@ CONFIGURATION
# Be sure to follow the directions in /etc/rc.d/rc.mysqld before you try and
setup your database.
chmod 755 /etc/rc.d/rc.mysqld
chmod 755 /etc/rc.d/rc.httpd
mysql_install_db --user=mysql
chown -R dmysql:mysql /var/lib/mysql
mysql_install_db --user=mysql
chmod 755 /etc/rc.d/rc.mysqld
/etc/rc.d/rc.mysqld start
mysql_secure_installation
1) Database setup:
# mysql -u root -p
mysql -u root -p
source /usr/share/ZoneMinder/db/zm_create.sql
use mysql;
grant select,insert,update,delete on zm.* to 'zmuser'@localhost identified by 'zmpass';
@ -31,22 +20,13 @@ quit;
Reload the mysql server with "mysqladmin reload -u root -p".
2) Apache configuration:
Edit /etc/httpd/httpd.conf
Uncomment mod_php
Uncomment LoadModule cgid_module
Uncomment AddHandler cgi-script .cgi
Uncomment mod_php at the end of /etc/httpd/httpd.conf.
Add this line to httpd.conf:
Include /etc/httpd/extra/zm.conf# You may need to chmod +x /etc/rc.d/rc.httpd first
Include /etc/zm/zm_apache.conf
# You may need to chmod +x /etc/rc.d/rc.httpd first
Restart apache with "/etc/rc.d/rc.httpd restart".
# I also had to add a line to my php.ini file for my time zone
[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = America/Los_Angeles
To make ZoneMinder launch on system boot:
/etc/rc.d/rc.local:
==================================
@ -68,14 +48,3 @@ on how to counter the massive amount of syslog spam that ZoneMinder generates.
The ZoneMinder web interface shall be available at http://hostname/zm/
Have fun!
If you use sbopkg, use sqg to generate queuefile for dependencies:
sqg -p ZoneMinder
sbopkg -i ZoneMinder (pick Queue)
OPTIONAL
sbopkg -i perl-Mozilla-CA -i perl-IO-Socket-SSL -i Net-SSLeay -i perl-LWP-Protocol-https
If you choose to install ffmpeg, this is the sbopkg build line I used.
sbopkg -i xvidcore -i x264 -i twolame -i lame -i ffmpeg

View file

@ -23,7 +23,7 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=ZoneMinder
VERSION=${VERSION:-1.30.0}
VERSION=${VERSION:-1.31.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@ -91,16 +91,26 @@ cmake -DCMAKE_INSTALL_PREFIX=/usr \
make
make install DESTDIR=$PKG INSTALLDIRS=vendor INSTALLVENDORMAN3DIR=/usr/man/man3
# Strip binaries
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
find $PKG/usr/man -type f -exec gzip -9 {} \;
mv $PKG/usr/share/man/man8 $PKG/usr/man/
# Compress manpages
mkdir -p $PKG/usr/man/man3
mv $PKG/usr/share/man/man3/* $PKG/usr/man/man3/
mkdir -p $PKG/usr/man/man8
mv $PKG/usr/share/man/man8/* $PKG/usr/man/man8/
rm -rf $PKG/usr/share/man
find $PKG/usr/man -type f -exec gzip -9 {} \;
# Remove junk files and dirs
find $PKG -name perllocal.pod \
-o -name ".packlist" \
-o -name "*.bs" \
-o -name ".editorconfig" \
-o -name ".packlist" \
-o -name ".git" \
-o -name "empty" \
| xargs rm -f || true
find $PKG/usr -depth -type d -empty -delete || true
@ -109,7 +119,7 @@ mkdir -p $PKG/var/{log,lock/subsys}
install -d -o $DOCOWN -g $DOCGRP $PKG/var/log/zm
for DIR in events images sound; do
install -d -o $DOCOWN -g $DOCGRP $PKG$DOCROOT/$DIR
install -d -o $DOCOWN -g $DOCGRP $PKG/var/lib/zoneminder/$DIR
done
# Install logrotate script
@ -141,6 +151,7 @@ mkdir -p $PKG/tmp
chmod 777 $PKG/tmp
chmod +t $PKG/tmp
# Copy documentation
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a AUTHORS ChangeLog INSTALL NEWS TODO $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild

View file

@ -1,14 +1,14 @@
PRGNAM="ZoneMinder"
VERSION="1.30.0"
VERSION="1.31.1"
HOMEPAGE="https://www.zoneminder.com"
DOWNLOAD="https://github.com/ZoneMinder/ZoneMinder/releases/download/v1.30.0/ZoneMinder-1.30.0.tar.gz \
DOWNLOAD="http://urchlay.naptime.net/~urchlay/src/ZoneMinder-1.31.1.tar.gz \
http://www.andywilcock.com/code/cambozola/cambozola-0.935.tar.gz \
https://downloads.sourceforge.net/jscalendar/jscalendar-1.0.zip"
MD5SUM="590c5c4ee35cd5677983dc76b391c415 \
6c48fd994685d4d72668850eeb613e24 \
10f2160fe68294013efcd1473cd36f72"
MD5SUM="c4fb54ec542fed09e03e0d5830106c39 \
6c48fd994685d4d72668850eeb613e24 \
10f2160fe68294013efcd1473cd36f72"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="perl-Module-Build perl-Date-Manip perl-Sys-Mmap libwww-perl perl-Sys-CPU perl-Sys-MemInfo"
MAINTAINER="Geno Bob"
EMAIL="geno.bob@gmail.com"
REQUIRES="perl-Date-Manip perl-Sys-Mmap perl-LWP-Protocol-https SDL2"
MAINTAINER="Gene Baxter"
EMAIL="GenoBob@gmail.com"

View file

@ -11,8 +11,8 @@ config() {
# Otherwise, we leave the .new copy for the admin to consider...
}
config etc/zm.conf.new
config etc/httpd/extra/zm.conf.new
config etc/zm.conf.new
config etc/logrotate.d/zm.new
config etc/rc.d/rc.zm.new