Merge branch 'master' into onvif_updated

This commit is contained in:
Isaac Connor 2020-05-09 16:26:29 -04:00
commit 732bb5416f
1532 changed files with 121078 additions and 77951 deletions

10
.gitignore vendored
View File

@ -1,5 +1,6 @@
configure configure
config.h.in config.h.in
config.h.in~
autom4te.cache autom4te.cache
aclocal.m4 aclocal.m4
depcomp depcomp
@ -12,7 +13,7 @@ scripts/ZoneMinder/blib
Makefile.in Makefile.in
Makefile Makefile
docs/_build docs/_build
compile
config.guess config.guess
config.h config.h
config.log config.log
@ -24,6 +25,12 @@ misc/com.zoneminder.systemctl.policy
misc/com.zoneminder.systemctl.rules misc/com.zoneminder.systemctl.rules
misc/logrotate.conf misc/logrotate.conf
misc/syslog.conf misc/syslog.conf
onvif/modules/MYMETA.json
onvif/modules/MYMETA.yml
onvif/proxy/MYMETA.json
onvif/proxy/MYMETA.yml
scripts/ZoneMinder/Makefile.old
scripts/ZoneMinder/MYMETA.json
scripts/ZoneMinder/MYMETA.yml scripts/ZoneMinder/MYMETA.yml
scripts/ZoneMinder/lib/ZoneMinder/Base.pm scripts/ZoneMinder/lib/ZoneMinder/Base.pm
scripts/ZoneMinder/lib/ZoneMinder/Config.pm scripts/ZoneMinder/lib/ZoneMinder/Config.pm
@ -56,7 +63,6 @@ src/zma
src/zmc src/zmc
src/zmf src/zmf
src/zms src/zms
src/zmstreamer
src/zmu src/zmu
web/includes/config.php web/includes/config.php
zm.conf zm.conf

4
.gitmodules vendored Normal file
View File

@ -0,0 +1,4 @@
[submodule "web/api/app/Plugin/Crud"]
path = web/api/app/Plugin/Crud
url = https://github.com/FriendsOfCake/crud.git
branch = 3.0

View File

@ -1,9 +1,15 @@
language: cpp language: cpp
sudo: required
dist: trusty
notifications: notifications:
irc: "chat.freenode.net#zoneminder-dev" irc: "chat.freenode.net#zoneminder-dev"
branches: branches:
except: except:
- modern - modern
addons:
sauce_connect:
username: "zoneminder"
access_key: "046ec7c1-c598-4e7e-949a-f86e725d1722"
env: env:
global: global:
- LD_LIBRARY_PATH="/usr/local/lib:/opt/libjpeg-turbo/lib:$LD_LIBRARY_PATH" - LD_LIBRARY_PATH="/usr/local/lib:/opt/libjpeg-turbo/lib:$LD_LIBRARY_PATH"
@ -13,14 +19,14 @@ env:
- CXXFLAGS="$CFLAGS" - CXXFLAGS="$CFLAGS"
matrix: matrix:
- ZM_BUILDMETHOD=cmake - ZM_BUILDMETHOD=cmake
- ZM_BUILDMETHOD=autotools
compiler: compiler:
- gcc - gcc
- clang
before_install: before_install:
- sudo apt-get update -qq - sudo apt-get update -qq
- sudo apt-get install -y -qq libpolkit-gobject-1-dev zlib1g-dev apache2 mysql-server php5 php5-mysql build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf cmake libjpeg-turbo8-dev apache2-mpm-prefork libapache2-mod-php5 php5-cli libtheora-dev libvorbis-dev libvpx-dev libx264-dev libvlccore-dev libvlc-dev libvlccore5 libvlc5 2>&1 > /dev/null - sudo apt-get install -y -qq libpolkit-gobject-1-dev zlib1g-dev apache2 mysql-server php5 php5-mysql build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf cmake libjpeg-turbo8-dev apache2-mpm-prefork libapache2-mod-php5 php5-cli libtheora-dev libvorbis-dev libvpx-dev libx264-dev libvlccore-dev libvlc-dev 2>&1 > /dev/null
install: install:
- git clone -b n2.4.2 --depth=1 git://source.ffmpeg.org/ffmpeg.git - git clone -b n3.0 --depth=1 git://source.ffmpeg.org/ffmpeg.git
- cd ffmpeg - cd ffmpeg
- ./configure --enable-shared --enable-swscale --enable-gpl --enable-libx264 --enable-libvpx --enable-libvorbis --enable-libtheora - ./configure --enable-shared --enable-swscale --enable-gpl --enable-libx264 --enable-libvpx --enable-libvorbis --enable-libtheora
- make -j `grep processor /proc/cpuinfo|wc -l` - make -j `grep processor /proc/cpuinfo|wc -l`
@ -28,16 +34,10 @@ install:
- sudo make install-libs - sudo make install-libs
before_script: before_script:
- cd $TRAVIS_BUILD_DIR - cd $TRAVIS_BUILD_DIR
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then libtoolize --force; fi
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then aclocal; fi
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then autoheader; fi
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then automake --force-missing --add-missing; fi
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then autoconf; fi
- mysql -uroot -e "CREATE DATABASE IF NOT EXISTS zm" - mysql -uroot -e "CREATE DATABASE IF NOT EXISTS zm"
- mysql -uroot -e "GRANT ALL ON zm.* TO 'zmuser'@'localhost' IDENTIFIED BY 'zmpass'"; - mysql -uroot -e "GRANT ALL ON zm.* TO 'zmuser'@'localhost' IDENTIFIED BY 'zmpass'";
- mysql -uroot -e "FLUSH PRIVILEGES" - mysql -uroot -e "FLUSH PRIVILEGES"
script: script:
- if [ "$ZM_BUILDMETHOD" = "autotools" ]; then ./configure --prefix=/usr --with-libarch=lib/$DEB_HOST_GNU_TYPE --host=$DEB_HOST_GNU_TYPE --build=$DEB_BUILD_GNU_TYPE --with-mysql=/usr --with-ffmpeg=/usr --with-webdir=/usr/share/zoneminder/www --with-cgidir=/usr/libexec/zoneminder/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-crashtrace=yes --disable-debug --enable-mmap=yes ZM_SSL_LIB=openssl; fi
- if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DCMAKE_INSTALL_PREFIX="/usr"; fi - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DCMAKE_INSTALL_PREFIX="/usr"; fi
- make - make
- sudo make install - sudo make install

487
CHANGELOG.md Normal file
View File

@ -0,0 +1,487 @@
# Change Log
## [v1.29.0](https://github.com/ZoneMinder/ZoneMinder/tree/v1.29.0) (2016-02-03)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.29.0-rc2...v1.29.0)
**Merged pull requests:**
- 1253 zms quit cmd [\#1254](https://github.com/ZoneMinder/ZoneMinder/pull/1254) ([pliablepixels](https://github.com/pliablepixels))
- Add Debug/Info lines reporting multi-server status [\#1252](https://github.com/ZoneMinder/ZoneMinder/pull/1252) ([connortechnology](https://github.com/connortechnology))
- Do debian package mods [\#1244](https://github.com/ZoneMinder/ZoneMinder/pull/1244) ([pliablepixels](https://github.com/pliablepixels))
- zmtrigger - process off+time delay condition [\#1240](https://github.com/ZoneMinder/ZoneMinder/pull/1240) ([knnniggett](https://github.com/knnniggett))
- Multi server [\#1233](https://github.com/ZoneMinder/ZoneMinder/pull/1233) ([connortechnology](https://github.com/connortechnology))
- remove Google open Sans external import [\#1232](https://github.com/ZoneMinder/ZoneMinder/pull/1232) ([connortechnology](https://github.com/connortechnology))
- PTZ - Added autostop to Down command on FI8918W [\#1189](https://github.com/ZoneMinder/ZoneMinder/pull/1189) ([marcolino7](https://github.com/marcolino7))
## [v1.29.0-rc2](https://github.com/ZoneMinder/ZoneMinder/tree/v1.29.0-rc2) (2016-01-05)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.29.0-rc1...v1.29.0-rc2)
**Merged pull requests:**
- Multi server [\#1223](https://github.com/ZoneMinder/ZoneMinder/pull/1223) ([connortechnology](https://github.com/connortechnology))
- Multi server [\#1222](https://github.com/ZoneMinder/ZoneMinder/pull/1222) ([connortechnology](https://github.com/connortechnology))
- Multi server [\#1217](https://github.com/ZoneMinder/ZoneMinder/pull/1217) ([connortechnology](https://github.com/connortechnology))
- Multi server [\#1215](https://github.com/ZoneMinder/ZoneMinder/pull/1215) ([connortechnology](https://github.com/connortechnology))
- Change log updates [\#1172](https://github.com/ZoneMinder/ZoneMinder/pull/1172) ([SteveGilvarry](https://github.com/SteveGilvarry))
## [v1.29.0-rc1](https://github.com/ZoneMinder/ZoneMinder/tree/v1.29.0-rc1) (2016-01-01)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.28.1...v1.29.0-rc1)
**Merged pull requests:**
- Bump version to 1.29.0 [\#1213](https://github.com/ZoneMinder/ZoneMinder/pull/1213) ([knnniggett](https://github.com/knnniggett))
- Missing rtd theme [\#1202](https://github.com/ZoneMinder/ZoneMinder/pull/1202) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Skip directories that have non-digits in them [\#1201](https://github.com/ZoneMinder/ZoneMinder/pull/1201) ([connortechnology](https://github.com/connortechnology))
- updated mobile app info [\#1200](https://github.com/ZoneMinder/ZoneMinder/pull/1200) ([pliablepixels](https://github.com/pliablepixels))
- Api more security [\#1196](https://github.com/ZoneMinder/ZoneMinder/pull/1196) ([pliablepixels](https://github.com/pliablepixels))
- Documentation [\#1194](https://github.com/ZoneMinder/ZoneMinder/pull/1194) ([pliablepixels](https://github.com/pliablepixels))
- Documentation updated for ubuntu [\#1193](https://github.com/ZoneMinder/ZoneMinder/pull/1193) ([pliablepixels](https://github.com/pliablepixels))
- Fixes \#1179 Libvlc Live555 Segmentation Fault [\#1190](https://github.com/ZoneMinder/ZoneMinder/pull/1190) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Add code to detect the change in REALM from older to newer firmware [\#1184](https://github.com/ZoneMinder/ZoneMinder/pull/1184) ([connortechnology](https://github.com/connortechnology))
- add a 1/8th scale option, which is useful for 1920x1080 streams [\#1182](https://github.com/ZoneMinder/ZoneMinder/pull/1182) ([connortechnology](https://github.com/connortechnology))
- Zms socket lock [\#1180](https://github.com/ZoneMinder/ZoneMinder/pull/1180) ([connortechnology](https://github.com/connortechnology))
- Check for the presence of CrudControllerTrait.php instead of .git [\#1178](https://github.com/ZoneMinder/ZoneMinder/pull/1178) ([knnniggett](https://github.com/knnniggett))
- Partial fix for \#1167 [\#1176](https://github.com/ZoneMinder/ZoneMinder/pull/1176) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Error on missing submodules [\#1173](https://github.com/ZoneMinder/ZoneMinder/pull/1173) ([knnniggett](https://github.com/knnniggett))
- fix mem alloc fault in zm\_monitor.cpp [\#1168](https://github.com/ZoneMinder/ZoneMinder/pull/1168) ([knnniggett](https://github.com/knnniggett))
- compat for php 5.4 [\#1164](https://github.com/ZoneMinder/ZoneMinder/pull/1164) ([abishai](https://github.com/abishai))
- remove comment at end of line [\#1157](https://github.com/ZoneMinder/ZoneMinder/pull/1157) ([connortechnology](https://github.com/connortechnology))
- Reorder RTSPDescribe to avoid -wreorder warnings [\#1147](https://github.com/ZoneMinder/ZoneMinder/pull/1147) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Update to \#1137 for backward compatibility. [\#1142](https://github.com/ZoneMinder/ZoneMinder/pull/1142) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Update Travis to ffmpeg 2.8.1 for testing [\#1139](https://github.com/ZoneMinder/ZoneMinder/pull/1139) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Replace deprecated FFmpeg API [\#1137](https://github.com/ZoneMinder/ZoneMinder/pull/1137) ([onlyjob](https://github.com/onlyjob))
- added prev/next event ids [\#1136](https://github.com/ZoneMinder/ZoneMinder/pull/1136) ([pliablepixels](https://github.com/pliablepixels))
- Install nph-zms with FILES so it is listed in install\_manifest.txt [\#1124](https://github.com/ZoneMinder/ZoneMinder/pull/1124) ([baffo32](https://github.com/baffo32))
- Stray semicolon causes SQL error [\#1123](https://github.com/ZoneMinder/ZoneMinder/pull/1123) ([baffo32](https://github.com/baffo32))
- Use relative URL's instead of absolute [\#1121](https://github.com/ZoneMinder/ZoneMinder/pull/1121) ([knnniggett](https://github.com/knnniggett))
- Update version check URL [\#1120](https://github.com/ZoneMinder/ZoneMinder/pull/1120) ([kylejohnson](https://github.com/kylejohnson))
- Add index to frames [\#1116](https://github.com/ZoneMinder/ZoneMinder/pull/1116) ([kylejohnson](https://github.com/kylejohnson))
- Fatal if content dirs are unwritable [\#1113](https://github.com/ZoneMinder/ZoneMinder/pull/1113) ([baffo32](https://github.com/baffo32))
- Fatal error if date.timezone is unset [\#1111](https://github.com/ZoneMinder/ZoneMinder/pull/1111) ([baffo32](https://github.com/baffo32))
- Fix faulty zm.conf.new install line [\#1107](https://github.com/ZoneMinder/ZoneMinder/pull/1107) ([baffo32](https://github.com/baffo32))
- Update preinst [\#1103](https://github.com/ZoneMinder/ZoneMinder/pull/1103) ([seebaer1976](https://github.com/seebaer1976))
- Update apache.conf [\#1102](https://github.com/ZoneMinder/ZoneMinder/pull/1102) ([seebaer1976](https://github.com/seebaer1976))
- Update rules [\#1101](https://github.com/ZoneMinder/ZoneMinder/pull/1101) ([seebaer1976](https://github.com/seebaer1976))
- Update links [\#1100](https://github.com/ZoneMinder/ZoneMinder/pull/1100) ([seebaer1976](https://github.com/seebaer1976))
- Update preinst [\#1099](https://github.com/ZoneMinder/ZoneMinder/pull/1099) ([seebaer1976](https://github.com/seebaer1976))
- Fix zmaudit [\#1095](https://github.com/ZoneMinder/ZoneMinder/pull/1095) ([connortechnology](https://github.com/connortechnology))
- fixed version compare logic [\#1094](https://github.com/ZoneMinder/ZoneMinder/pull/1094) ([pliablepixels](https://github.com/pliablepixels))
- Don't install zm.conf if it already exists [\#1090](https://github.com/ZoneMinder/ZoneMinder/pull/1090) ([connortechnology](https://github.com/connortechnology))
- change types and move things around to remove compile warnings [\#1089](https://github.com/ZoneMinder/ZoneMinder/pull/1089) ([connortechnology](https://github.com/connortechnology))
- Tz [\#1084](https://github.com/ZoneMinder/ZoneMinder/pull/1084) ([connortechnology](https://github.com/connortechnology))
- fixed orange display for monitor mode [\#1083](https://github.com/ZoneMinder/ZoneMinder/pull/1083) ([pliablepixels](https://github.com/pliablepixels))
- use deleteAll\(\) vs. delete\(\) when deleting an Event's Frames [\#1080](https://github.com/ZoneMinder/ZoneMinder/pull/1080) ([kylejohnson](https://github.com/kylejohnson))
- Added control script for SunEyes SP-P1802SWPTZ [\#1079](https://github.com/ZoneMinder/ZoneMinder/pull/1079) ([bofhdk](https://github.com/bofhdk))
- Use the 3.0 branch of crud, compatible with cakephp 2.x [\#1078](https://github.com/ZoneMinder/ZoneMinder/pull/1078) ([kylejohnson](https://github.com/kylejohnson))
- 663 frames primary key [\#1075](https://github.com/ZoneMinder/ZoneMinder/pull/1075) ([kylejohnson](https://github.com/kylejohnson))
- Delete fixes for Events [\#1073](https://github.com/ZoneMinder/ZoneMinder/pull/1073) ([pliablepixels](https://github.com/pliablepixels))
- restart monitor when edited via APIs [\#1070](https://github.com/ZoneMinder/ZoneMinder/pull/1070) ([pliablepixels](https://github.com/pliablepixels))
- add debug statements for when LastWriteTime is not defined. [\#1067](https://github.com/ZoneMinder/ZoneMinder/pull/1067) ([connortechnology](https://github.com/connortechnology))
- fixed recaptcha showing up pre DB update [\#1066](https://github.com/ZoneMinder/ZoneMinder/pull/1066) ([pliablepixels](https://github.com/pliablepixels))
- fixed security instructions for curl [\#1062](https://github.com/ZoneMinder/ZoneMinder/pull/1062) ([pliablepixels](https://github.com/pliablepixels))
- header typo corrections [\#1058](https://github.com/ZoneMinder/ZoneMinder/pull/1058) ([onlyjob](https://github.com/onlyjob))
- quick fix for \#1055: make sure our mmap fd is \> 2 [\#1057](https://github.com/ZoneMinder/ZoneMinder/pull/1057) ([connortechnology](https://github.com/connortechnology))
- Fix sgfault caused by the privacy mask stuff [\#1056](https://github.com/ZoneMinder/ZoneMinder/pull/1056) ([connortechnology](https://github.com/connortechnology))
- link to cambozola pacakge, rather than download during build [\#1054](https://github.com/ZoneMinder/ZoneMinder/pull/1054) ([knnniggett](https://github.com/knnniggett))
- redhat rpm packaging modifications [\#1052](https://github.com/ZoneMinder/ZoneMinder/pull/1052) ([knnniggett](https://github.com/knnniggett))
- remove core.php, modify core.php.default [\#1049](https://github.com/ZoneMinder/ZoneMinder/pull/1049) ([knnniggett](https://github.com/knnniggett))
- Google recaptcha [\#1048](https://github.com/ZoneMinder/ZoneMinder/pull/1048) ([pliablepixels](https://github.com/pliablepixels))
- enable/disable RTSP Describe Header [\#1045](https://github.com/ZoneMinder/ZoneMinder/pull/1045) ([knnniggett](https://github.com/knnniggett))
- Add Documentation for Privacy zones [\#1044](https://github.com/ZoneMinder/ZoneMinder/pull/1044) ([schrorg](https://github.com/schrorg))
- added note about potential Perl and PHP time translation conflict wit… [\#1043](https://github.com/ZoneMinder/ZoneMinder/pull/1043) ([pliablepixels](https://github.com/pliablepixels))
- Multi server [\#1040](https://github.com/ZoneMinder/ZoneMinder/pull/1040) ([connortechnology](https://github.com/connortechnology))
- 1038 fixing state mgmt 1030 is active fix [\#1039](https://github.com/ZoneMinder/ZoneMinder/pull/1039) ([pliablepixels](https://github.com/pliablepixels))
- Grey color for disabled buttons [\#1037](https://github.com/ZoneMinder/ZoneMinder/pull/1037) ([pliablepixels](https://github.com/pliablepixels))
- Update filterevents.rst [\#1035](https://github.com/ZoneMinder/ZoneMinder/pull/1035) ([tikismoke](https://github.com/tikismoke))
- add warning and help text for maxfps fields [\#1033](https://github.com/ZoneMinder/ZoneMinder/pull/1033) ([knnniggett](https://github.com/knnniggett))
- update doc [\#1032](https://github.com/ZoneMinder/ZoneMinder/pull/1032) ([tikismoke](https://github.com/tikismoke))
- Remove full path from Logger filename [\#1029](https://github.com/ZoneMinder/ZoneMinder/pull/1029) ([knnniggett](https://github.com/knnniggett))
- Typo in README.md [\#1027](https://github.com/ZoneMinder/ZoneMinder/pull/1027) ([tikismoke](https://github.com/tikismoke))
- Add new zone type - privacy zones [\#1026](https://github.com/ZoneMinder/ZoneMinder/pull/1026) ([schrorg](https://github.com/schrorg))
- Send login activity to the zoneminder event log [\#1021](https://github.com/ZoneMinder/ZoneMinder/pull/1021) ([knnniggett](https://github.com/knnniggett))
- Small dark CSS fixes in frames and timeline view [\#1019](https://github.com/ZoneMinder/ZoneMinder/pull/1019) ([schrorg](https://github.com/schrorg))
- New User Permission "Groups" [\#1018](https://github.com/ZoneMinder/ZoneMinder/pull/1018) ([knnniggett](https://github.com/knnniggett))
- 1013 document migration [\#1017](https://github.com/ZoneMinder/ZoneMinder/pull/1017) ([pliablepixels](https://github.com/pliablepixels))
- Fix issue with score values less than 0 [\#1016](https://github.com/ZoneMinder/ZoneMinder/pull/1016) ([knnniggett](https://github.com/knnniggett))
- Explained a caveat with using relative times [\#1012](https://github.com/ZoneMinder/ZoneMinder/pull/1012) ([pliablepixels](https://github.com/pliablepixels))
- Included logic to not enforce authentication in API layer if ZM auth is off [\#1008](https://github.com/ZoneMinder/ZoneMinder/pull/1008) ([pliablepixels](https://github.com/pliablepixels))
- Update to ffmpeg 2.7.2 in travis build [\#1007](https://github.com/ZoneMinder/ZoneMinder/pull/1007) ([SteveGilvarry](https://github.com/SteveGilvarry))
- I was using the wrong field to check for portal authentication [\#1006](https://github.com/ZoneMinder/ZoneMinder/pull/1006) ([pliablepixels](https://github.com/pliablepixels))
- Demote user auth info message to debug [\#1003](https://github.com/ZoneMinder/ZoneMinder/pull/1003) ([Linwood-F](https://github.com/Linwood-F))
- Add scale as optional feature to image.php [\#1001](https://github.com/ZoneMinder/ZoneMinder/pull/1001) ([Linwood-F](https://github.com/Linwood-F))
- 995 events count per api \(bumps up \# of events reported per API call\) [\#996](https://github.com/ZoneMinder/ZoneMinder/pull/996) ([pliablepixels](https://github.com/pliablepixels))
- APIs will be served only if user is logged into the ZM portal [\#994](https://github.com/ZoneMinder/ZoneMinder/pull/994) ([pliablepixels](https://github.com/pliablepixels))
- Add option to make TimeStamp larger [\#992](https://github.com/ZoneMinder/ZoneMinder/pull/992) ([schrorg](https://github.com/schrorg))
- Implemented \#989 \(highlight current row in tables\) for dark CSS [\#990](https://github.com/ZoneMinder/ZoneMinder/pull/990) ([schrorg](https://github.com/schrorg))
- CSS\[skins/classic\]: highlight current row in tables. [\#989](https://github.com/ZoneMinder/ZoneMinder/pull/989) ([onlyjob](https://github.com/onlyjob))
- quiet error when no Servers in Servers table [\#986](https://github.com/ZoneMinder/ZoneMinder/pull/986) ([connortechnology](https://github.com/connortechnology))
- fix \#948 1 [\#985](https://github.com/ZoneMinder/ZoneMinder/pull/985) ([connortechnology](https://github.com/connortechnology))
- Remove shared data warning for purpose query only [\#984](https://github.com/ZoneMinder/ZoneMinder/pull/984) ([Linwood-F](https://github.com/Linwood-F))
- Change from info to debug [\#983](https://github.com/ZoneMinder/ZoneMinder/pull/983) ([Linwood-F](https://github.com/Linwood-F))
- Fix image dimensions check [\#980](https://github.com/ZoneMinder/ZoneMinder/pull/980) ([connortechnology](https://github.com/connortechnology))
- Apache.conf modifications [\#968](https://github.com/ZoneMinder/ZoneMinder/pull/968) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Dark CSS for classic theme [\#967](https://github.com/ZoneMinder/ZoneMinder/pull/967) ([schrorg](https://github.com/schrorg))
- Auto generated changelog [\#966](https://github.com/ZoneMinder/ZoneMinder/pull/966) ([SteveGilvarry](https://github.com/SteveGilvarry))
- 959 add exif date time to images [\#962](https://github.com/ZoneMinder/ZoneMinder/pull/962) ([Linwood-F](https://github.com/Linwood-F))
- Add analysis interval parameter to monitors settings [\#956](https://github.com/ZoneMinder/ZoneMinder/pull/956) ([manupap1](https://github.com/manupap1))
- Fixed Configs API to return all values [\#955](https://github.com/ZoneMinder/ZoneMinder/pull/955) ([pliablepixels](https://github.com/pliablepixels))
- Change encoding of german language file to UTF-8 [\#952](https://github.com/ZoneMinder/ZoneMinder/pull/952) ([schrorg](https://github.com/schrorg))
- Show correct part of URL \(hostname\) for ffmpeg sources in console [\#951](https://github.com/ZoneMinder/ZoneMinder/pull/951) ([schrorg](https://github.com/schrorg))
- add php-gd to list of dependencies for debian and ubuntu builds [\#944](https://github.com/ZoneMinder/ZoneMinder/pull/944) ([connortechnology](https://github.com/connortechnology))
- rpm packaging - require php-gd [\#943](https://github.com/ZoneMinder/ZoneMinder/pull/943) ([knnniggett](https://github.com/knnniggett))
- add some utility db functions [\#942](https://github.com/ZoneMinder/ZoneMinder/pull/942) ([connortechnology](https://github.com/connortechnology))
- add space instead of + to handle old Axis cameras [\#941](https://github.com/ZoneMinder/ZoneMinder/pull/941) ([connortechnology](https://github.com/connortechnology))
- zmtrigger: POD documentation [\#938](https://github.com/ZoneMinder/ZoneMinder/pull/938) ([onlyjob](https://github.com/onlyjob))
- improve log [\#937](https://github.com/ZoneMinder/ZoneMinder/pull/937) ([connortechnology](https://github.com/connortechnology))
- add error handling on failure to open serial port [\#936](https://github.com/ZoneMinder/ZoneMinder/pull/936) ([connortechnology](https://github.com/connortechnology))
- fix utf8 ' characters [\#934](https://github.com/ZoneMinder/ZoneMinder/pull/934) ([connortechnology](https://github.com/connortechnology))
- roudn up when calculating buffer size for scaled image. Fixes \#932 [\#933](https://github.com/ZoneMinder/ZoneMinder/pull/933) ([connortechnology](https://github.com/connortechnology))
- Added API routing [\#931](https://github.com/ZoneMinder/ZoneMinder/pull/931) ([pliablepixels](https://github.com/pliablepixels))
- don't include .cpp in man [\#930](https://github.com/ZoneMinder/ZoneMinder/pull/930) ([connortechnology](https://github.com/connortechnology))
- fix pod2man generation for out-of-source builds [\#928](https://github.com/ZoneMinder/ZoneMinder/pull/928) ([knnniggett](https://github.com/knnniggett))
- Version to 1.28.99 [\#926](https://github.com/ZoneMinder/ZoneMinder/pull/926) ([connortechnology](https://github.com/connortechnology))
- Introduce a read\_into function in the Buffer. [\#923](https://github.com/ZoneMinder/ZoneMinder/pull/923) ([connortechnology](https://github.com/connortechnology))
- Added "RewriteBase /zm/api" for API routing [\#921](https://github.com/ZoneMinder/ZoneMinder/pull/921) ([pliablepixels](https://github.com/pliablepixels))
- Zms no crash [\#920](https://github.com/ZoneMinder/ZoneMinder/pull/920) ([connortechnology](https://github.com/connortechnology))
- add check for gettime in librt, needed for building on pi [\#919](https://github.com/ZoneMinder/ZoneMinder/pull/919) ([connortechnology](https://github.com/connortechnology))
- Add ServerId to Monitors [\#918](https://github.com/ZoneMinder/ZoneMinder/pull/918) ([connortechnology](https://github.com/connortechnology))
- Dumb down Crud from 4.0 -\> 3.0.10 [\#915](https://github.com/ZoneMinder/ZoneMinder/pull/915) ([knnniggett](https://github.com/knnniggett))
- Add Servers Table and add Id PRIMARY KEY to States [\#910](https://github.com/ZoneMinder/ZoneMinder/pull/910) ([connortechnology](https://github.com/connortechnology))
- fix montage view issue in mobile skin [\#909](https://github.com/ZoneMinder/ZoneMinder/pull/909) ([knnniggett](https://github.com/knnniggett))
- Solaris cmake [\#906](https://github.com/ZoneMinder/ZoneMinder/pull/906) ([knnniggett](https://github.com/knnniggett))
- Fix el7 build [\#902](https://github.com/ZoneMinder/ZoneMinder/pull/902) ([bill-mcgonigle](https://github.com/bill-mcgonigle))
- 898 is running states [\#899](https://github.com/ZoneMinder/ZoneMinder/pull/899) ([pliablepixels](https://github.com/pliablepixels))
- Fixed events API to remove thumbnail code [\#897](https://github.com/ZoneMinder/ZoneMinder/pull/897) ([pliablepixels](https://github.com/pliablepixels))
- Generate man pages for perl scripts & C Binaries in the bin folder [\#896](https://github.com/ZoneMinder/ZoneMinder/pull/896) ([knnniggett](https://github.com/knnniggett))
- 893 foscam 9831 w and other foscams [\#895](https://github.com/ZoneMinder/ZoneMinder/pull/895) ([pliablepixels](https://github.com/pliablepixels))
- 893 foscam 9831 w and other foscams [\#894](https://github.com/ZoneMinder/ZoneMinder/pull/894) ([pliablepixels](https://github.com/pliablepixels))
- Zmwatch cleanup2 [\#891](https://github.com/ZoneMinder/ZoneMinder/pull/891) ([connortechnology](https://github.com/connortechnology))
- reverse the if statement to reduce indenting [\#890](https://github.com/ZoneMinder/ZoneMinder/pull/890) ([connortechnology](https://github.com/connortechnology))
- Updated API document [\#886](https://github.com/ZoneMinder/ZoneMinder/pull/886) ([pliablepixels](https://github.com/pliablepixels))
- Use avconv as alternative to ffmpeg executable [\#884](https://github.com/ZoneMinder/ZoneMinder/pull/884) ([SteveGilvarry](https://github.com/SteveGilvarry))
- 881 bootstrap loading config [\#883](https://github.com/ZoneMinder/ZoneMinder/pull/883) ([pliablepixels](https://github.com/pliablepixels))
- Merged Angular UI branch API to master [\#882](https://github.com/ZoneMinder/ZoneMinder/pull/882) ([pliablepixels](https://github.com/pliablepixels))
- Add version to the startup log line [\#875](https://github.com/ZoneMinder/ZoneMinder/pull/875) ([connortechnology](https://github.com/connortechnology))
- German translation update [\#874](https://github.com/ZoneMinder/ZoneMinder/pull/874) ([seeebek](https://github.com/seeebek))
- reduce the wait to 2/10ths instead of a whole second [\#873](https://github.com/ZoneMinder/ZoneMinder/pull/873) ([connortechnology](https://github.com/connortechnology))
- alter the logic of ReadData. New behaviour is documented. [\#870](https://github.com/ZoneMinder/ZoneMinder/pull/870) ([connortechnology](https://github.com/connortechnology))
- analysis optimisations [\#867](https://github.com/ZoneMinder/ZoneMinder/pull/867) ([connortechnology](https://github.com/connortechnology))
- Don't die if db goes away during logging [\#866](https://github.com/ZoneMinder/ZoneMinder/pull/866) ([connortechnology](https://github.com/connortechnology))
- Move iostream inclusion in zm.h and declare explicitely the namespace [\#859](https://github.com/ZoneMinder/ZoneMinder/pull/859) ([manupap1](https://github.com/manupap1))
- Fix detection of deprecated libav / ffmpeg functions [\#858](https://github.com/ZoneMinder/ZoneMinder/pull/858) ([manupap1](https://github.com/manupap1))
- Correct bareword config entries with newer {} style [\#856](https://github.com/ZoneMinder/ZoneMinder/pull/856) ([connortechnology](https://github.com/connortechnology))
- update german translation [\#854](https://github.com/ZoneMinder/ZoneMinder/pull/854) ([seeebek](https://github.com/seeebek))
- ubuntu 15.04 [\#850](https://github.com/ZoneMinder/ZoneMinder/pull/850) ([seeebek](https://github.com/seeebek))
- faster shutdown [\#847](https://github.com/ZoneMinder/ZoneMinder/pull/847) ([connortechnology](https://github.com/connortechnology))
- Additional SLANG changes [\#845](https://github.com/ZoneMinder/ZoneMinder/pull/845) ([knnniggett](https://github.com/knnniggett))
- Cmake hostos [\#844](https://github.com/ZoneMinder/ZoneMinder/pull/844) ([knnniggett](https://github.com/knnniggett))
- Port to OmniOS/Solaris [\#842](https://github.com/ZoneMinder/ZoneMinder/pull/842) ([whorfin](https://github.com/whorfin))
- Zmaudit update1: Make MIN\_AGE Configurable [\#838](https://github.com/ZoneMinder/ZoneMinder/pull/838) ([connortechnology](https://github.com/connortechnology))
- Update to FI982821W\_Y2k [\#836](https://github.com/ZoneMinder/ZoneMinder/pull/836) ([connortechnology](https://github.com/connortechnology))
- add translate function [\#833](https://github.com/ZoneMinder/ZoneMinder/pull/833) ([knnniggett](https://github.com/knnniggett))
- Separate css window sizes [\#829](https://github.com/ZoneMinder/ZoneMinder/pull/829) ([connortechnology](https://github.com/connortechnology))
- Fix fast forward/reverse in event playback \(\#688\) [\#825](https://github.com/ZoneMinder/ZoneMinder/pull/825) ([rwg0](https://github.com/rwg0))
- Fix: typo in options\_libvlc [\#824](https://github.com/ZoneMinder/ZoneMinder/pull/824) ([Lihis](https://github.com/Lihis))
- close the session before requiring the page contents to fix the concurre... [\#823](https://github.com/ZoneMinder/ZoneMinder/pull/823) ([connortechnology](https://github.com/connortechnology))
- Fix build issues on kFreeBSD. Fixes \#771 [\#822](https://github.com/ZoneMinder/ZoneMinder/pull/822) ([connortechnology](https://github.com/connortechnology))
- beautifying \*.pm [\#821](https://github.com/ZoneMinder/ZoneMinder/pull/821) ([onlyjob](https://github.com/onlyjob))
- Remove hardcoded localized strings in php files and update lang files [\#820](https://github.com/ZoneMinder/ZoneMinder/pull/820) ([manupap1](https://github.com/manupap1))
- Fix french lang file [\#818](https://github.com/ZoneMinder/ZoneMinder/pull/818) ([manupap1](https://github.com/manupap1))
- more perlcritic/PBP corrections [\#816](https://github.com/ZoneMinder/ZoneMinder/pull/816) ([onlyjob](https://github.com/onlyjob))
- last batch of POD and readability conversions for \*.pl scripts [\#815](https://github.com/ZoneMinder/ZoneMinder/pull/815) ([onlyjob](https://github.com/onlyjob))
- Fixes \#760 in part Clean up CMakeLists.txt [\#812](https://github.com/ZoneMinder/ZoneMinder/pull/812) ([SteveGilvarry](https://github.com/SteveGilvarry))
- upgrade bundled jQuery \(Closes: \#785\) [\#809](https://github.com/ZoneMinder/ZoneMinder/pull/809) ([onlyjob](https://github.com/onlyjob))
- Update Mootools [\#803](https://github.com/ZoneMinder/ZoneMinder/pull/803) ([knnniggett](https://github.com/knnniggett))
- hide USE\_DEEP\_STORAGE [\#802](https://github.com/ZoneMinder/ZoneMinder/pull/802) ([knnniggett](https://github.com/knnniggett))
- link zms to nph-zms, rather than build identical [\#801](https://github.com/ZoneMinder/ZoneMinder/pull/801) ([knnniggett](https://github.com/knnniggett))
- \* use pthread\_join instead of pthread\_tryjoin\_np [\#800](https://github.com/ZoneMinder/ZoneMinder/pull/800) ([Sune1337](https://github.com/Sune1337))
- zmcontrol.pl, zmfilter.pl: pod2usage + readability improvements. [\#798](https://github.com/ZoneMinder/ZoneMinder/pull/798) ([onlyjob](https://github.com/onlyjob))
- one small fix for a log line where the 4th parameter wasn't included. T... [\#796](https://github.com/ZoneMinder/ZoneMinder/pull/796) ([connortechnology](https://github.com/connortechnology))
- zmaudit.pl, zmcamtool.pl: pod2usage, PBP/5 + readability [\#795](https://github.com/ZoneMinder/ZoneMinder/pull/795) ([onlyjob](https://github.com/onlyjob))
- as discussed... [\#794](https://github.com/ZoneMinder/ZoneMinder/pull/794) ([onlyjob](https://github.com/onlyjob))
- Leftover short open tags [\#793](https://github.com/ZoneMinder/ZoneMinder/pull/793) ([SteveGilvarry](https://github.com/SteveGilvarry))
- cmake - use perl INSTALLDIRS [\#792](https://github.com/ZoneMinder/ZoneMinder/pull/792) ([knnniggett](https://github.com/knnniggett))
- \#783 - related corrections [\#791](https://github.com/ZoneMinder/ZoneMinder/pull/791) ([onlyjob](https://github.com/onlyjob))
- skins/classic: fix HTML export with USE\_DEEP\_STORAGE \(Closes: \#506\). [\#782](https://github.com/ZoneMinder/ZoneMinder/pull/782) ([onlyjob](https://github.com/onlyjob))
- Check for libv4l1-videodev headers [\#781](https://github.com/ZoneMinder/ZoneMinder/pull/781) ([knnniggett](https://github.com/knnniggett))
- build: add PATH\_MAX definitions \(needed on GNU Hurd\) [\#778](https://github.com/ZoneMinder/ZoneMinder/pull/778) ([onlyjob](https://github.com/onlyjob))
- Freebsd fixes [\#775](https://github.com/ZoneMinder/ZoneMinder/pull/775) ([connortechnology](https://github.com/connortechnology))
- Use tmpfiles.d to manage tmpdir and sockdir [\#774](https://github.com/ZoneMinder/ZoneMinder/pull/774) ([knnniggett](https://github.com/knnniggett))
- Don't trigger linked cameras on new events [\#772](https://github.com/ZoneMinder/ZoneMinder/pull/772) ([balr0g](https://github.com/balr0g))
- POD: zmupdate.pl converted to "pod2usage" [\#763](https://github.com/ZoneMinder/ZoneMinder/pull/763) ([onlyjob](https://github.com/onlyjob))
- build: fix FTBFS with format-hardening \(please review\) [\#761](https://github.com/ZoneMinder/ZoneMinder/pull/761) ([onlyjob](https://github.com/onlyjob))
- fixing POD errors [\#759](https://github.com/ZoneMinder/ZoneMinder/pull/759) ([onlyjob](https://github.com/onlyjob))
- Ignore autogenerated files in git [\#746](https://github.com/ZoneMinder/ZoneMinder/pull/746) ([manupap1](https://github.com/manupap1))
- when auth is needed, try command again before dying. [\#739](https://github.com/ZoneMinder/ZoneMinder/pull/739) ([connortechnology](https://github.com/connortechnology))
- remove NETPBM dependency from autotools [\#737](https://github.com/ZoneMinder/ZoneMinder/pull/737) ([knnniggett](https://github.com/knnniggett))
- fix extra slash when adding trackurl to controlurl [\#732](https://github.com/ZoneMinder/ZoneMinder/pull/732) ([connortechnology](https://github.com/connortechnology))
- Fix image and css import paths for style/skin named "flat" [\#730](https://github.com/ZoneMinder/ZoneMinder/pull/730) ([ljack](https://github.com/ljack))
- Update control.css [\#729](https://github.com/ZoneMinder/ZoneMinder/pull/729) ([ljack](https://github.com/ljack))
- Fix event view [\#728](https://github.com/ZoneMinder/ZoneMinder/pull/728) ([connortechnology](https://github.com/connortechnology))
- User selectable arp tool [\#723](https://github.com/ZoneMinder/ZoneMinder/pull/723) ([knnniggett](https://github.com/knnniggett))
- remove unneeded files [\#722](https://github.com/ZoneMinder/ZoneMinder/pull/722) ([knnniggett](https://github.com/knnniggett))
- add onvif ptz control into update script [\#721](https://github.com/ZoneMinder/ZoneMinder/pull/721) ([knnniggett](https://github.com/knnniggett))
- Don't show ONVIf probe link when ONVIF support is not enabled [\#720](https://github.com/ZoneMinder/ZoneMinder/pull/720) ([knnniggett](https://github.com/knnniggett))
- Allow zm to build w/o ffmpeg [\#719](https://github.com/ZoneMinder/ZoneMinder/pull/719) ([knnniggett](https://github.com/knnniggett))
- Removed el6 from endif arguments [\#718](https://github.com/ZoneMinder/ZoneMinder/pull/718) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Update fr\_fr.php [\#714](https://github.com/ZoneMinder/ZoneMinder/pull/714) ([Jypy](https://github.com/Jypy))
- Check to make sure that skin and css are valid. [\#713](https://github.com/ZoneMinder/ZoneMinder/pull/713) ([connortechnology](https://github.com/connortechnology))
- Fixes \#710 Added libavformat version check around free context functions [\#711](https://github.com/ZoneMinder/ZoneMinder/pull/711) ([SteveGilvarry](https://github.com/SteveGilvarry))
- try harder to find arp. [\#709](https://github.com/ZoneMinder/ZoneMinder/pull/709) ([connortechnology](https://github.com/connortechnology))
- Make el6 and el7 build process a little more automated [\#704](https://github.com/ZoneMinder/ZoneMinder/pull/704) ([clipo1979](https://github.com/clipo1979))
- small improvements: [\#702](https://github.com/ZoneMinder/ZoneMinder/pull/702) ([connortechnology](https://github.com/connortechnology))
- Centos 7 rpm packaging [\#700](https://github.com/ZoneMinder/ZoneMinder/pull/700) ([knnniggett](https://github.com/knnniggett))
- tmpfile.conf for systemd [\#699](https://github.com/ZoneMinder/ZoneMinder/pull/699) ([clipo1979](https://github.com/clipo1979))
- Improve delete event [\#696](https://github.com/ZoneMinder/ZoneMinder/pull/696) ([connortechnology](https://github.com/connortechnology))
- process RTSP DESCRIBE response header [\#687](https://github.com/ZoneMinder/ZoneMinder/pull/687) ([knnniggett](https://github.com/knnniggett))
## [v1.28.1](https://github.com/ZoneMinder/ZoneMinder/tree/v1.28.1) (2015-02-05)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.28.0...v1.28.1)
**Merged pull requests:**
- fix content-type parsing when there are options on it [\#692](https://github.com/ZoneMinder/ZoneMinder/pull/692) ([connortechnology](https://github.com/connortechnology))
- this fixes Digest Auth for the mjpeg stream on a TV-IP302PI [\#691](https://github.com/ZoneMinder/ZoneMinder/pull/691) ([connortechnology](https://github.com/connortechnology))
- small performance improvement when streaming. [\#675](https://github.com/ZoneMinder/ZoneMinder/pull/675) ([connortechnology](https://github.com/connortechnology))
- Kill zmcontrol [\#666](https://github.com/ZoneMinder/ZoneMinder/pull/666) ([connortechnology](https://github.com/connortechnology))
- Don't fail if an unexpected rtp packet type is received [\#665](https://github.com/ZoneMinder/ZoneMinder/pull/665) ([knnniggett](https://github.com/knnniggett))
- Versions command line args [\#664](https://github.com/ZoneMinder/ZoneMinder/pull/664) ([connortechnology](https://github.com/connortechnology))
- Update et\_ee.php [\#662](https://github.com/ZoneMinder/ZoneMinder/pull/662) ([hanzese](https://github.com/hanzese))
- \#658 Fix error message for finding arp path [\#660](https://github.com/ZoneMinder/ZoneMinder/pull/660) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Make the log export use ZM\_PATH\_SWAP and report the full path on error [\#657](https://github.com/ZoneMinder/ZoneMinder/pull/657) ([connortechnology](https://github.com/connortechnology))
- replace getLoad\(\) / getDiskPercent\(\) with PHP native functions [\#654](https://github.com/ZoneMinder/ZoneMinder/pull/654) ([lifeofguenter](https://github.com/lifeofguenter))
- Modified zmfilter.pl.in to fix \#652, crashing while processing backgroun... [\#653](https://github.com/ZoneMinder/ZoneMinder/pull/653) ([thebostik](https://github.com/thebostik))
- Remove no longer needed patch because applied to master [\#651](https://github.com/ZoneMinder/ZoneMinder/pull/651) ([manupap1](https://github.com/manupap1))
- Don't check for zmdc.pl when stopping via systemd [\#647](https://github.com/ZoneMinder/ZoneMinder/pull/647) ([ariscop](https://github.com/ariscop))
- Split the debian package into several packages [\#646](https://github.com/ZoneMinder/ZoneMinder/pull/646) ([manupap1](https://github.com/manupap1))
- Skin css default [\#645](https://github.com/ZoneMinder/ZoneMinder/pull/645) ([connortechnology](https://github.com/connortechnology))
- Offer login prompt instead of throwing error [\#640](https://github.com/ZoneMinder/ZoneMinder/pull/640) ([jrd288](https://github.com/jrd288))
- zmfilter: Send message for events that are still ongoing [\#638](https://github.com/ZoneMinder/ZoneMinder/pull/638) ([KristofRobot](https://github.com/KristofRobot))
- Some fixes to the debian folder [\#636](https://github.com/ZoneMinder/ZoneMinder/pull/636) ([manupap1](https://github.com/manupap1))
- Improve zmcontrol.pl [\#635](https://github.com/ZoneMinder/ZoneMinder/pull/635) ([connortechnology](https://github.com/connortechnology))
- Add debconf / dbconfig support to debian8 folder [\#634](https://github.com/ZoneMinder/ZoneMinder/pull/634) ([manupap1](https://github.com/manupap1))
- better fix for the view=console security flaw. [\#632](https://github.com/ZoneMinder/ZoneMinder/pull/632) ([connortechnology](https://github.com/connortechnology))
- add check to see if user has rights to view this monitor [\#631](https://github.com/ZoneMinder/ZoneMinder/pull/631) ([connortechnology](https://github.com/connortechnology))
- fix auth requirement on view=console by checking for user when AUTH is on [\#628](https://github.com/ZoneMinder/ZoneMinder/pull/628) ([connortechnology](https://github.com/connortechnology))
- Output to stderror when zmu can't read zm.conf [\#627](https://github.com/ZoneMinder/ZoneMinder/pull/627) ([knnniggett](https://github.com/knnniggett))
- Add missing dependency to policykit-1 [\#621](https://github.com/ZoneMinder/ZoneMinder/pull/621) ([manupap1](https://github.com/manupap1))
- Replace PHP Short Open Tags - Fixes \#11 [\#620](https://github.com/ZoneMinder/ZoneMinder/pull/620) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Rtsp [\#615](https://github.com/ZoneMinder/ZoneMinder/pull/615) ([knnniggett](https://github.com/knnniggett))
- Merge flat css to classic [\#614](https://github.com/ZoneMinder/ZoneMinder/pull/614) ([connortechnology](https://github.com/connortechnology))
- echo the URL to the RTSP device during the OPTIONS directive [\#608](https://github.com/ZoneMinder/ZoneMinder/pull/608) ([knnniggett](https://github.com/knnniggett))
- Fix some memory leaks in zma [\#607](https://github.com/ZoneMinder/ZoneMinder/pull/607) ([manupap1](https://github.com/manupap1))
- Fix a mismatched free in zmc binary [\#606](https://github.com/ZoneMinder/ZoneMinder/pull/606) ([manupap1](https://github.com/manupap1))
- New debian folder for jessie release [\#605](https://github.com/ZoneMinder/ZoneMinder/pull/605) ([manupap1](https://github.com/manupap1))
- Css skins for classic [\#602](https://github.com/ZoneMinder/ZoneMinder/pull/602) ([connortechnology](https://github.com/connortechnology))
- Fix package dependency on debian jessie [\#596](https://github.com/ZoneMinder/ZoneMinder/pull/596) ([manupap1](https://github.com/manupap1))
- updated local\_zoneminder type extension file [\#594](https://github.com/ZoneMinder/ZoneMinder/pull/594) ([ndobbs](https://github.com/ndobbs))
- Creating options documentation fixes \#568 [\#591](https://github.com/ZoneMinder/ZoneMinder/pull/591) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Convert french lang file to UTF-8 [\#589](https://github.com/ZoneMinder/ZoneMinder/pull/589) ([manupap1](https://github.com/manupap1))
- Digest auth [\#588](https://github.com/ZoneMinder/ZoneMinder/pull/588) ([connortechnology](https://github.com/connortechnology))
- Zmupdatefixes [\#584](https://github.com/ZoneMinder/ZoneMinder/pull/584) ([connortechnology](https://github.com/connortechnology))
- Update et\_ee.php [\#582](https://github.com/ZoneMinder/ZoneMinder/pull/582) ([hanzese](https://github.com/hanzese))
- Add zmeditconfigdata.sh script to source [\#577](https://github.com/ZoneMinder/ZoneMinder/pull/577) ([knnniggett](https://github.com/knnniggett))
- Close logger and database on exit [\#575](https://github.com/ZoneMinder/ZoneMinder/pull/575) ([manupap1](https://github.com/manupap1))
- Fix memory leaks with rtsp and a bug [\#574](https://github.com/ZoneMinder/ZoneMinder/pull/574) ([manupap1](https://github.com/manupap1))
- Fix a bug when closing RTSP session over TCP [\#573](https://github.com/ZoneMinder/ZoneMinder/pull/573) ([manupap1](https://github.com/manupap1))
- remove the case for level \>= 2. Since level is a bool, this code can ne... [\#572](https://github.com/ZoneMinder/ZoneMinder/pull/572) ([connortechnology](https://github.com/connortechnology))
- Add Control 3S N5071 Dome Ptz Camera [\#570](https://github.com/ZoneMinder/ZoneMinder/pull/570) ([jmcastro2014](https://github.com/jmcastro2014))
- Add the ability to specify the zm configdir at build time. [\#567](https://github.com/ZoneMinder/ZoneMinder/pull/567) ([knnniggett](https://github.com/knnniggett))
- Debian package migration to CMake and some improves with lintian help [\#565](https://github.com/ZoneMinder/ZoneMinder/pull/565) ([cosmedd](https://github.com/cosmedd))
- Use gnutls-openssl instead of gnutls to fix build with CMake. [\#564](https://github.com/ZoneMinder/ZoneMinder/pull/564) ([cosmedd](https://github.com/cosmedd))
- Use our own SSRC when sending packets on the RTP control stream [\#561](https://github.com/ZoneMinder/ZoneMinder/pull/561) ([manupap1](https://github.com/manupap1))
- Send keepalive messages if the rtsp server supports this feature [\#560](https://github.com/ZoneMinder/ZoneMinder/pull/560) ([manupap1](https://github.com/manupap1))
- Fixed bug in rtsp streaming caused by a bad string concatenation [\#557](https://github.com/ZoneMinder/ZoneMinder/pull/557) ([manupap1](https://github.com/manupap1))
- Add a stringVector join function for future use [\#556](https://github.com/ZoneMinder/ZoneMinder/pull/556) ([connortechnology](https://github.com/connortechnology))
- Fixed bug in rtsp streaming caused by a signed - unsigned conversion. [\#555](https://github.com/ZoneMinder/ZoneMinder/pull/555) ([manupap1](https://github.com/manupap1))
- Update Ubuntu install instructions [\#550](https://github.com/ZoneMinder/ZoneMinder/pull/550) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Ignore more files and initial travis framework [\#544](https://github.com/ZoneMinder/ZoneMinder/pull/544) ([kylejohnson](https://github.com/kylejohnson))
- Update Travis to ffmpeg 2.4.2 [\#539](https://github.com/ZoneMinder/ZoneMinder/pull/539) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Add libvlc to Travis [\#535](https://github.com/ZoneMinder/ZoneMinder/pull/535) ([knnniggett](https://github.com/knnniggett))
- 351-Rebase Attempt for ffmpeg stability fixes [\#531](https://github.com/ZoneMinder/ZoneMinder/pull/531) ([SteveGilvarry](https://github.com/SteveGilvarry))
- 478 Basic ONVIF Support [\#479](https://github.com/ZoneMinder/ZoneMinder/pull/479) ([altaroca](https://github.com/altaroca))
## [v1.28.0](https://github.com/ZoneMinder/ZoneMinder/tree/v1.28.0) (2014-10-18)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.27.0...v1.28.0)
**Merged pull requests:**
- fixes ftbs with no ffmpeg support [\#530](https://github.com/ZoneMinder/ZoneMinder/pull/530) ([knnniggett](https://github.com/knnniggett))
- 498-Docker-Container-Broken [\#527](https://github.com/ZoneMinder/ZoneMinder/pull/527) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Changes to handling of tmpdir & related variables [\#524](https://github.com/ZoneMinder/ZoneMinder/pull/524) ([knnniggett](https://github.com/knnniggett))
- Fixes 520 travis build ffmpeg failure [\#521](https://github.com/ZoneMinder/ZoneMinder/pull/521) ([SteveGilvarry](https://github.com/SteveGilvarry))
- full systemd support [\#502](https://github.com/ZoneMinder/ZoneMinder/pull/502) ([knnniggett](https://github.com/knnniggett))
- Minor corrections to README.OpenSuse [\#501](https://github.com/ZoneMinder/ZoneMinder/pull/501) ([PX03AFK](https://github.com/PX03AFK))
- Allow use other webservers than apache. [\#493](https://github.com/ZoneMinder/ZoneMinder/pull/493) ([cosmedd](https://github.com/cosmedd))
- Initial attempt to migrate wiki to readthedocs \#434 [\#492](https://github.com/ZoneMinder/ZoneMinder/pull/492) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Update FI9821W\_Y2k.pm [\#485](https://github.com/ZoneMinder/ZoneMinder/pull/485) ([florian-asche](https://github.com/florian-asche))
- V4l to monitor [\#480](https://github.com/ZoneMinder/ZoneMinder/pull/480) ([connortechnology](https://github.com/connortechnology))
- Modified zmlinkcontent to chown and chmod content folder. Fixes \#463 [\#465](https://github.com/ZoneMinder/ZoneMinder/pull/465) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Fix for shared data size conflict [\#462](https://github.com/ZoneMinder/ZoneMinder/pull/462) ([knnniggett](https://github.com/knnniggett))
- Update rules [\#459](https://github.com/ZoneMinder/ZoneMinder/pull/459) ([whopperg](https://github.com/whopperg))
- Determine full path to arp [\#458](https://github.com/ZoneMinder/ZoneMinder/pull/458) ([knnniggett](https://github.com/knnniggett))
- Fixes errors when opening Filters \(issue \#34\) [\#457](https://github.com/ZoneMinder/ZoneMinder/pull/457) ([knnniggett](https://github.com/knnniggett))
- Fixed missing $ on ARRAY\(event\[id\]\). Fixes \#455 [\#456](https://github.com/ZoneMinder/ZoneMinder/pull/456) ([SteveGilvarry](https://github.com/SteveGilvarry))
- Wrap sort order. Fixes \#450 [\#451](https://github.com/ZoneMinder/ZoneMinder/pull/451) ([SteveGilvarry](https://github.com/SteveGilvarry))
- scripts: BusyBox compatibility [\#445](https://github.com/ZoneMinder/ZoneMinder/pull/445) ([clandmeter](https://github.com/clandmeter))
- Fixed issue DateTime handling in filter queries that broke timeline view... [\#442](https://github.com/ZoneMinder/ZoneMinder/pull/442) ([Tim-Craig](https://github.com/Tim-Craig))
- Cleaning up the Contribution section of the README [\#440](https://github.com/ZoneMinder/ZoneMinder/pull/440) ([kylejohnson](https://github.com/kylejohnson))
- Add Bountysource badge to README [\#438](https://github.com/ZoneMinder/ZoneMinder/pull/438) ([bountysource-support](https://github.com/bountysource-support))
- Add new colums to zm\_create.sql.in [\#426](https://github.com/ZoneMinder/ZoneMinder/pull/426) ([m-bene](https://github.com/m-bene))
- Ffmpegoptions [\#421](https://github.com/ZoneMinder/ZoneMinder/pull/421) ([m-bene](https://github.com/m-bene))
- Update zm\_jpeg.cpp [\#418](https://github.com/ZoneMinder/ZoneMinder/pull/418) ([ghost](https://github.com/ghost))
- Added an FAQ for AlarmCheckMethod [\#416](https://github.com/ZoneMinder/ZoneMinder/pull/416) ([kylejohnson](https://github.com/kylejohnson))
- make skin selection persistent [\#415](https://github.com/ZoneMinder/ZoneMinder/pull/415) ([m-bene](https://github.com/m-bene))
- Added a doc for contributing to the project [\#413](https://github.com/ZoneMinder/ZoneMinder/pull/413) ([kylejohnson](https://github.com/kylejohnson))
- Update zmtrigger.pl.in [\#411](https://github.com/ZoneMinder/ZoneMinder/pull/411) ([martin67](https://github.com/martin67))
- Add the web/api folder to cmake [\#409](https://github.com/ZoneMinder/ZoneMinder/pull/409) ([mastertheknife](https://github.com/mastertheknife))
- Move API to under web dir [\#408](https://github.com/ZoneMinder/ZoneMinder/pull/408) ([kylejohnson](https://github.com/kylejohnson))
- Rtsp digest [\#407](https://github.com/ZoneMinder/ZoneMinder/pull/407) ([m-bene](https://github.com/m-bene))
- focus popup windows [\#406](https://github.com/ZoneMinder/ZoneMinder/pull/406) ([m-bene](https://github.com/m-bene))
- remove call of undefined "fixDevices" function [\#405](https://github.com/ZoneMinder/ZoneMinder/pull/405) ([m-bene](https://github.com/m-bene))
- Zms/videostream improvements [\#404](https://github.com/ZoneMinder/ZoneMinder/pull/404) ([Sune1337](https://github.com/Sune1337))
- RESTful API in CakePHP, and docs [\#403](https://github.com/ZoneMinder/ZoneMinder/pull/403) ([kylejohnson](https://github.com/kylejohnson))
- Remove SVN install from Travis CI [\#395](https://github.com/ZoneMinder/ZoneMinder/pull/395) ([hamiltont](https://github.com/hamiltont))
- Remove Subversion from prerequesite lists [\#393](https://github.com/ZoneMinder/ZoneMinder/pull/393) ([hamiltont](https://github.com/hamiltont))
- Dockerfile works properly, documentation updated [\#392](https://github.com/ZoneMinder/ZoneMinder/pull/392) ([hamiltont](https://github.com/hamiltont))
- Remove apt-get upgrade [\#390](https://github.com/ZoneMinder/ZoneMinder/pull/390) ([hamiltont](https://github.com/hamiltont))
- Update README.OpenSuse [\#389](https://github.com/ZoneMinder/ZoneMinder/pull/389) ([PX03AFK](https://github.com/PX03AFK))
- Update CMakeLists.txt [\#388](https://github.com/ZoneMinder/ZoneMinder/pull/388) ([PX03AFK](https://github.com/PX03AFK))
- Update zoneminder.cmake.OS13.spec - minor corrections [\#387](https://github.com/ZoneMinder/ZoneMinder/pull/387) ([PX03AFK](https://github.com/PX03AFK))
- fix sql error which prevents remote login from working [\#385](https://github.com/ZoneMinder/ZoneMinder/pull/385) ([maciekczwa](https://github.com/maciekczwa))
- Fix window sizes and input field sizes for flat skin [\#381](https://github.com/ZoneMinder/ZoneMinder/pull/381) ([m-bene](https://github.com/m-bene))
- Fix reload loop on switching skins [\#380](https://github.com/ZoneMinder/ZoneMinder/pull/380) ([m-bene](https://github.com/m-bene))
- Ability to skip frames in motion detection. [\#377](https://github.com/ZoneMinder/ZoneMinder/pull/377) ([Sune1337](https://github.com/Sune1337))
- same dvr controls in event as in monitor [\#375](https://github.com/ZoneMinder/ZoneMinder/pull/375) ([m-bene](https://github.com/m-bene))
- do not quote column names in parse filter [\#374](https://github.com/ZoneMinder/ZoneMinder/pull/374) ([m-bene](https://github.com/m-bene))
- Fix 'Undefined index: filter' php warnings for filter view when [\#373](https://github.com/ZoneMinder/ZoneMinder/pull/373) ([m-bene](https://github.com/m-bene))
- Reduce window size to exclude task bar area [\#371](https://github.com/ZoneMinder/ZoneMinder/pull/371) ([m-bene](https://github.com/m-bene))
- Update zoneminder.tmpfiles [\#367](https://github.com/ZoneMinder/ZoneMinder/pull/367) ([PX03AFK](https://github.com/PX03AFK))
- Update zoneminder.cmake.OS13.spec [\#362](https://github.com/ZoneMinder/ZoneMinder/pull/362) ([PX03AFK](https://github.com/PX03AFK))
- Update README.OpenSuse [\#361](https://github.com/ZoneMinder/ZoneMinder/pull/361) ([PX03AFK](https://github.com/PX03AFK))
- fix eyezm authentication issue [\#359](https://github.com/ZoneMinder/ZoneMinder/pull/359) ([knnniggett](https://github.com/knnniggett))
- Fix prev button while in gapless mode. All buttons tested and working. [\#358](https://github.com/ZoneMinder/ZoneMinder/pull/358) ([knnniggett](https://github.com/knnniggett))
- Update zmupdate.pl.in [\#353](https://github.com/ZoneMinder/ZoneMinder/pull/353) ([barjac](https://github.com/barjac))
- make curl header check case insensitive [\#352](https://github.com/ZoneMinder/ZoneMinder/pull/352) ([m-bene](https://github.com/m-bene))
- tie distro/opensuse folder into cmake build process [\#349](https://github.com/ZoneMinder/ZoneMinder/pull/349) ([knnniggett](https://github.com/knnniggett))
- Initial upload for opensuse rpm [\#348](https://github.com/ZoneMinder/ZoneMinder/pull/348) ([PX03AFK](https://github.com/PX03AFK))
- Patch for Debian bug 736516 - FTBFS on powerpc arch. [\#346](https://github.com/ZoneMinder/ZoneMinder/pull/346) ([knnniggett](https://github.com/knnniggett))
- Nagyrobi [\#342](https://github.com/ZoneMinder/ZoneMinder/pull/342) ([knnniggett](https://github.com/knnniggett))
- add feature to extend preclusive zone alarm state by x frames [\#338](https://github.com/ZoneMinder/ZoneMinder/pull/338) ([m-bene](https://github.com/m-bene))
- Support building with new libavcodec versions. [\#325](https://github.com/ZoneMinder/ZoneMinder/pull/325) ([elenril](https://github.com/elenril))
- Mysql2 pdo [\#231](https://github.com/ZoneMinder/ZoneMinder/pull/231) ([connortechnology](https://github.com/connortechnology))
## [v1.27.0](https://github.com/ZoneMinder/ZoneMinder/tree/v1.27.0) (2014-03-15)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.5...v1.27.0)
**Merged pull requests:**
- zmcamtool.pl - import and export ptz camera controls & camera presets [\#318](https://github.com/ZoneMinder/ZoneMinder/pull/318) ([kylejohnson](https://github.com/kylejohnson))
- Example script to react to monitor alarms [\#317](https://github.com/ZoneMinder/ZoneMinder/pull/317) ([kylejohnson](https://github.com/kylejohnson))
- Change comments for many Camera subclasses [\#316](https://github.com/ZoneMinder/ZoneMinder/pull/316) ([nereocystis](https://github.com/nereocystis))
- Enable universe in the Docker container \[ci skip\] [\#310](https://github.com/ZoneMinder/ZoneMinder/pull/310) ([kylejohnson](https://github.com/kylejohnson))
- Add wget to Dockerfile prereq [\#309](https://github.com/ZoneMinder/ZoneMinder/pull/309) ([kylejohnson](https://github.com/kylejohnson))
- Add paths to flat skin in configure.ac and Makefile.am [\#308](https://github.com/ZoneMinder/ZoneMinder/pull/308) ([kylejohnson](https://github.com/kylejohnson))
- Zoneminder - flat theme. [\#303](https://github.com/ZoneMinder/ZoneMinder/pull/303) ([justinlawrence](https://github.com/justinlawrence))
- Additional compile guards to allow compilation on non-x86 archs [\#302](https://github.com/ZoneMinder/ZoneMinder/pull/302) ([pjhacnau](https://github.com/pjhacnau))
- Adding PTZ module for Toshiba IK-WB11A [\#300](https://github.com/ZoneMinder/ZoneMinder/pull/300) ([Tim-Craig](https://github.com/Tim-Craig))
- Add cURL source type [\#297](https://github.com/ZoneMinder/ZoneMinder/pull/297) ([mastertheknife](https://github.com/mastertheknife))
- glob ptz scripts under control folder [\#294](https://github.com/ZoneMinder/ZoneMinder/pull/294) ([knnniggett](https://github.com/knnniggett))
- Enclose value of the Notes attribute with quotes. [\#293](https://github.com/ZoneMinder/ZoneMinder/pull/293) ([hankintosh](https://github.com/hankintosh))
- Fix for few problems in Debian packaging [\#290](https://github.com/ZoneMinder/ZoneMinder/pull/290) ([dmak](https://github.com/dmak))
- Foscam IP cameras control script [\#289](https://github.com/ZoneMinder/ZoneMinder/pull/289) ([dmak](https://github.com/dmak))
- Specfile changes related to zmfix [\#284](https://github.com/ZoneMinder/ZoneMinder/pull/284) ([knnniggett](https://github.com/knnniggett))
- Remove references to zmfix in /distros [\#283](https://github.com/ZoneMinder/ZoneMinder/pull/283) ([nkwood](https://github.com/nkwood))
- Add zmMontageScale so montage scale is also 'saved' [\#282](https://github.com/ZoneMinder/ZoneMinder/pull/282) ([scottgrobinson](https://github.com/scottgrobinson))
- In the web/includes/functions.php there were some html formatting errors... [\#281](https://github.com/ZoneMinder/ZoneMinder/pull/281) ([martonmiklos](https://github.com/martonmiklos))
- Remove zmfix [\#280](https://github.com/ZoneMinder/ZoneMinder/pull/280) ([mastertheknife](https://github.com/mastertheknife))
- Add libVLC monitor type [\#277](https://github.com/ZoneMinder/ZoneMinder/pull/277) ([ebarnard](https://github.com/ebarnard))
- Disables non-POSIX warning when using gnu wildcard [\#276](https://github.com/ZoneMinder/ZoneMinder/pull/276) ([knnniggett](https://github.com/knnniggett))
- remove embedded jquery. \(fixes \#274\) [\#275](https://github.com/ZoneMinder/ZoneMinder/pull/275) ([kylejohnson](https://github.com/kylejohnson))
- Fixes \#313, initial commit of 'working' dockerfile [\#314](https://github.com/ZoneMinder/ZoneMinder/pull/314) ([kylejohnson](https://github.com/kylejohnson))
## [v1.26.5](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.5) (2013-12-16)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.4...v1.26.5)
**Merged pull requests:**
- Add reference to zm\_update-1.26.5.sql in Makefile.am [\#269](https://github.com/ZoneMinder/ZoneMinder/pull/269) ([knnniggett](https://github.com/knnniggett))
- Detection Support for WansView Cams [\#268](https://github.com/ZoneMinder/ZoneMinder/pull/268) ([Phhere](https://github.com/Phhere))
- use proper DBI parameter passing to improve security [\#264](https://github.com/ZoneMinder/ZoneMinder/pull/264) ([connortechnology](https://github.com/connortechnology))
- Fix RTSP decoding errors in 1.26.4 \(addresses \#221\) [\#259](https://github.com/ZoneMinder/ZoneMinder/pull/259) ([ebarnard](https://github.com/ebarnard))
- Network Detection Support for Wansview [\#257](https://github.com/ZoneMinder/ZoneMinder/pull/257) ([Phhere](https://github.com/Phhere))
- Fix checkJsonError messages [\#256](https://github.com/ZoneMinder/ZoneMinder/pull/256) ([Phhere](https://github.com/Phhere))
- Update README.md [\#255](https://github.com/ZoneMinder/ZoneMinder/pull/255) ([zdanek](https://github.com/zdanek))
- ipv6 support [\#252](https://github.com/ZoneMinder/ZoneMinder/pull/252) ([guotie](https://github.com/guotie))
- Better inno d bupdate [\#251](https://github.com/ZoneMinder/ZoneMinder/pull/251) ([connortechnology](https://github.com/connortechnology))
- Fix shared memory errors on centos 6.4 [\#250](https://github.com/ZoneMinder/ZoneMinder/pull/250) ([insidenothing](https://github.com/insidenothing))
- Update zoneminder.service [\#246](https://github.com/ZoneMinder/ZoneMinder/pull/246) ([dtmf](https://github.com/dtmf))
- remove extra stuff that I don't think we need because we are the source. Opinions? [\#240](https://github.com/ZoneMinder/ZoneMinder/pull/240) ([connortechnology](https://github.com/connortechnology))
- Cast content\_length to signed int for error-check comparison [\#232](https://github.com/ZoneMinder/ZoneMinder/pull/232) ([josephevans](https://github.com/josephevans))
- Apply INSERTs in Event::AddFrames in batches to fix issue \#222 [\#223](https://github.com/ZoneMinder/ZoneMinder/pull/223) ([fastolfe](https://github.com/fastolfe))
- ffmpeg detection improvements [\#218](https://github.com/ZoneMinder/ZoneMinder/pull/218) ([mastertheknife](https://github.com/mastertheknife))
- ZoneMinder Dutch Translation updates by Alco \(a.k. nightcrawler\) [\#211](https://github.com/ZoneMinder/ZoneMinder/pull/211) ([kylejohnson](https://github.com/kylejohnson))
- Change Prev Button functionality [\#207](https://github.com/ZoneMinder/ZoneMinder/pull/207) ([knnniggett](https://github.com/knnniggett))
- Delete PATH\_BUILD and TIME\_BUILD from zm.conf and fix ZM\_DB\_TYPE [\#243](https://github.com/ZoneMinder/ZoneMinder/pull/243) ([mastertheknife](https://github.com/mastertheknife))
- Removeversionnumberfromzm.conf [\#242](https://github.com/ZoneMinder/ZoneMinder/pull/242) ([connortechnology](https://github.com/connortechnology))
- Add alarm reference image blend percentage option and replace the text field if fast blends are enabled [\#241](https://github.com/ZoneMinder/ZoneMinder/pull/241) ([mastertheknife](https://github.com/mastertheknife))
- Fix marker-out-of-bounds crash when defining zone points [\#233](https://github.com/ZoneMinder/ZoneMinder/pull/233) ([fastolfe](https://github.com/fastolfe))
## [v1.26.4](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.4) (2013-10-08)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.3...v1.26.4)
**Merged pull requests:**
- Change frameserver warnings to debug level 2 [\#205](https://github.com/ZoneMinder/ZoneMinder/pull/205) ([knnniggett](https://github.com/knnniggett))
- Create pkgdatadir in make [\#203](https://github.com/ZoneMinder/ZoneMinder/pull/203) ([knnniggett](https://github.com/knnniggett))
- Signal improvements and fixes [\#201](https://github.com/ZoneMinder/ZoneMinder/pull/201) ([mastertheknife](https://github.com/mastertheknife))
- Create ZM\_PATH\_DATA and point zmupdate to ZM\_PATH\_DATA/db [\#200](https://github.com/ZoneMinder/ZoneMinder/pull/200) ([knnniggett](https://github.com/knnniggett))
- remove ${CMAKE\_CURRENT\_SOURCE\_DIR} from add\_custom\_target [\#199](https://github.com/ZoneMinder/ZoneMinder/pull/199) ([knnniggett](https://github.com/knnniggett))
- Added missing word in readme [\#194](https://github.com/ZoneMinder/ZoneMinder/pull/194) ([WDKevin](https://github.com/WDKevin))
- Add cmake to ZoneMinder [\#178](https://github.com/ZoneMinder/ZoneMinder/pull/178) ([mastertheknife](https://github.com/mastertheknife))
- Rtsp updates [\#174](https://github.com/ZoneMinder/ZoneMinder/pull/174) ([POKKAHOH](https://github.com/POKKAHOH))
- Solution for Issue \#170 [\#172](https://github.com/ZoneMinder/ZoneMinder/pull/172) ([raulcaj](https://github.com/raulcaj))
- Fixing debian build files including automated database setup [\#164](https://github.com/ZoneMinder/ZoneMinder/pull/164) ([jaydio](https://github.com/jaydio))
- Add fedora rpm development files to zoneminder source tree [\#163](https://github.com/ZoneMinder/ZoneMinder/pull/163) ([knnniggett](https://github.com/knnniggett))
- Improve Chrome browser support & log streaming events [\#162](https://github.com/ZoneMinder/ZoneMinder/pull/162) ([knnniggett](https://github.com/knnniggett))
- Can't seem to catch a break tonight. Moving debian files into correct folder [\#149](https://github.com/ZoneMinder/ZoneMinder/pull/149) ([knnniggett](https://github.com/knnniggett))
- Move debian folder under distros [\#148](https://github.com/ZoneMinder/ZoneMinder/pull/148) ([knnniggett](https://github.com/knnniggett))
- Removing the redhat folder from the root for real this time [\#141](https://github.com/ZoneMinder/ZoneMinder/pull/141) ([knnniggett](https://github.com/knnniggett))
- Redhat [\#136](https://github.com/ZoneMinder/ZoneMinder/pull/136) ([knnniggett](https://github.com/knnniggett))
- Error correction in database creation script [\#122](https://github.com/ZoneMinder/ZoneMinder/pull/122) ([dukess](https://github.com/dukess))
- Rewritten the query to allow mysql to use indexes [\#121](https://github.com/ZoneMinder/ZoneMinder/pull/121) ([rkojedzinszky](https://github.com/rkojedzinszky))
- Update zmupdate.pl.in for 1.26.3 release [\#119](https://github.com/ZoneMinder/ZoneMinder/pull/119) ([knnniggett](https://github.com/knnniggett))
## [v1.26.3](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.3) (2013-09-10)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.2...v1.26.3)
**Merged pull requests:**
- Add 1.26.1 and 1.26.2 releases to zmupdate [\#116](https://github.com/ZoneMinder/ZoneMinder/pull/116) ([knnniggett](https://github.com/knnniggett))
## [v1.26.2](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.2) (2013-09-06)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.1...v1.26.2)
**Merged pull requests:**
- Use GitHub repo for version check [\#111](https://github.com/ZoneMinder/ZoneMinder/pull/111) ([chriswiggins](https://github.com/chriswiggins))
## [v1.26.1](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.1) (2013-09-06)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26.0...v1.26.1)
## [v1.26.0](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26.0) (2013-09-05)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26-beta.3...v1.26.0)
## [v1.26-beta.3](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26-beta.3) (2013-08-28)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26-beta.2...v1.26-beta.3)
## [v1.26-beta.2](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26-beta.2) (2013-08-15)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.26-beta.1...v1.26-beta.2)
## [v1.26-beta.1](https://github.com/ZoneMinder/ZoneMinder/tree/v1.26-beta.1) (2013-08-13)
[Full Changelog](https://github.com/ZoneMinder/ZoneMinder/compare/v1.25...v1.26-beta.1)
## [v1.25](https://github.com/ZoneMinder/ZoneMinder/tree/v1.25) (2013-04-12)
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*

View File

@ -1,31 +1,63 @@
# Main CMake file for the ZoneMinder project. # Main CMake file for the ZoneMinder project.
# Created by mastertheknife (Kfir Itzhak) # Created by mastertheknife (Kfir Itzhak)
# The goal is to ease up the installation of zoneminder.
# Our current installation method (using autotools) is outdated, slow and breaks now and then.
# The CMake installation method will require no parameters at all, default should sufficient and reliable.
# It will be still possible to install ZoneMinder using autotools, they don't conflict with each other. The cmake way is a complete re-write (different syntax) and aims to be identical to the autotools way,
# by having options using the same name and leaving ZM totally unmodified, while providing exactly the same things that ZM expects (config.h, configuration in *.in files, etc).
#
# For more information and installation, see the INSTALL file # For more information and installation, see the INSTALL file
# #
cmake_minimum_required (VERSION 2.6) cmake_minimum_required (VERSION 2.6)
project (zoneminder) project (zoneminder)
set(zoneminder_VERSION "1.28.0") file (STRINGS "version" zoneminder_VERSION)
# make API version a minor of ZM version
set(zoneminder_API_VERSION "${zoneminder_VERSION}.1")
# CMake does not allow out-of-source build if CMakeCache.exists in the source folder. Abort and notify the user to save him from headache why it doesn't work. # Make sure the submodules are there
if((NOT (CMAKE_BINARY_DIR STREQUAL CMAKE_SOURCE_DIR)) AND (EXISTS "${CMAKE_SOURCE_DIR}/CMakeCache.txt")) if( NOT EXISTS "${CMAKE_SOURCE_DIR}/web/api/app/Plugin/Crud/Lib/CrudControllerTrait.php" )
message(FATAL_ERROR " You are attempting to do an out-of-source build, but a cmake cache file for an in-source build exists. Please delete the file CMakeCache.txt from the source folder to proceed.") message( SEND_ERROR "The git submodules are not available. Please run
endif((NOT (CMAKE_BINARY_DIR STREQUAL CMAKE_SOURCE_DIR)) AND (EXISTS "${CMAKE_SOURCE_DIR}/CMakeCache.txt")) git submodule update --init --recursive")
endif( NOT EXISTS "${CMAKE_SOURCE_DIR}/web/api/app/Plugin/Crud/Lib/CrudControllerTrait.php" )
# Default build type. To change the build type, use the CMAKE_BUILD_TYPE configuration option. # CMake does not allow out-of-source build if CMakeCache.exists
# in the source folder. Abort and notify the user
if(
(NOT (CMAKE_BINARY_DIR STREQUAL CMAKE_SOURCE_DIR))
AND (EXISTS "${CMAKE_SOURCE_DIR}/CMakeCache.txt"))
message(FATAL_ERROR " You are attempting to do an out-of-source build,
but a cmake cache file for an in-source build exists. Please delete
the file CMakeCache.txt from the source folder to proceed.")
endif(
(NOT (CMAKE_BINARY_DIR STREQUAL CMAKE_SOURCE_DIR))
AND (EXISTS "${CMAKE_SOURCE_DIR}/CMakeCache.txt"))
# Default build type. To change the build type,
# use the CMAKE_BUILD_TYPE configuration option.
if(NOT CMAKE_BUILD_TYPE) if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release CACHE STRING "Build type: Release or Debug" FORCE) set(CMAKE_BUILD_TYPE
Release CACHE STRING "Build type: Release or Debug" FORCE)
endif(NOT CMAKE_BUILD_TYPE) endif(NOT CMAKE_BUILD_TYPE)
# Can assist in troubleshooting # Can assist in troubleshooting
#set(CMAKE_VERBOSE_MAKEFILE ON) #set(CMAKE_VERBOSE_MAKEFILE ON)
#set(CMAKE_INSTALL_ALWAYS ON) #set(CMAKE_INSTALL_ALWAYS ON)
# Host OS Check
set(HOST_OS "")
if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
set(HOST_OS "linux")
endif(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
if(${CMAKE_SYSTEM_NAME} MATCHES ".*(SunOS|Solaris).*")
set(HOST_OS "solaris")
set(SOLARIS 1)
endif(${CMAKE_SYSTEM_NAME} MATCHES ".*(SunOS|Solaris).*")
if(${CMAKE_SYSTEM_NAME} MATCHES ".*BSD.*")
set(HOST_OS "BSD")
set(BSD 1)
endif(${CMAKE_SYSTEM_NAME} MATCHES ".*BSD.*")
if(${CMAKE_SYSTEM_NAME} STREQUAL "Darwin")
set(HOST_OS "darwin")
endif(${CMAKE_SYSTEM_NAME} STREQUAL "Darwin")
if(NOT HOST_OS)
message(FATAL_ERROR
"ZoneMinder was unable to deterimine the host OS. Please report this. Value of CMAKE_SYSTEM_NAME: ${CMAKE_SYSTEM_NAME}")
endif(NOT HOST_OS)
# Default CLFAGS and CXXFLAGS: # Default CLFAGS and CXXFLAGS:
set(CMAKE_C_FLAGS_RELEASE "-Wall -D__STDC_CONSTANT_MACROS -O2") set(CMAKE_C_FLAGS_RELEASE "-Wall -D__STDC_CONSTANT_MACROS -O2")
set(CMAKE_CXX_FLAGS_RELEASE "-Wall -D__STDC_CONSTANT_MACROS -O2") set(CMAKE_CXX_FLAGS_RELEASE "-Wall -D__STDC_CONSTANT_MACROS -O2")
@ -42,40 +74,105 @@ include (CheckFunctionExists)
include (CheckPrototypeDefinition_fixed) include (CheckPrototypeDefinition_fixed)
include (CheckTypeSize) include (CheckTypeSize)
include (CheckStructHasMember) include (CheckStructHasMember)
include (CheckSendfile)
# Configuration options # Configuration options
mark_as_advanced(FORCE ZM_EXTRA_LIBS ZM_MYSQL_ENGINE ZM_NO_MMAP CMAKE_INSTALL_FULL_BINDIR ZM_PERL_SUBPREFIX ZM_PERL_USE_PATH ZM_TARGET_DISTRO) mark_as_advanced(
set(ZM_RUNDIR "/var/run/zm" CACHE PATH "Location of transient process files, default: /var/run/zm") FORCE ZM_EXTRA_LIBS
set(ZM_SOCKDIR "/var/run/zm" CACHE PATH "Location of Unix domain socket files, default /var/run/zm") ZM_MYSQL_ENGINE
set(ZM_TMPDIR "/var/tmp/zm" CACHE PATH "Location of temporary files, default: /tmp/zm") ZM_NO_MMAP
set(ZM_LOGDIR "/var/log/zm" CACHE PATH "Location of generated log files, default: /var/log/zm") CMAKE_INSTALL_FULL_BINDIR
set(ZM_WEBDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder/www" CACHE PATH "Location of the web files, default: <prefix>/${CMAKE_INSTALL_DATADIR}/zoneminder/www") ZM_PERL_MM_PARMS
set(ZM_CGIDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/cgi-bin" CACHE PATH "Location of the cgi-bin files, default: <prefix>/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/cgi-bin") ZM_PERL_SEARCH_PATH
set(ZM_CONTENTDIR "/var/lib/zoneminder" CACHE PATH "Location of dynamic content (events and images), default: /var/lib/zoneminder") ZM_TARGET_DISTRO
set(ZM_DB_HOST "localhost" CACHE STRING "Hostname where ZoneMinder database located, default: localhost") ZM_CONFIG_DIR)
set(ZM_DB_NAME "zm" CACHE STRING "Name of ZoneMinder database, default: zm")
set(ZM_DB_USER "zmuser" CACHE STRING "Name of ZoneMinder database user, default: zmuser") set(ZM_RUNDIR "/var/run/zm" CACHE PATH
set(ZM_DB_PASS "zmpass" CACHE STRING "Password of ZoneMinder database user, default: zmpass") "Location of transient process files, default: /var/run/zm")
set(ZM_WEB_USER "" CACHE STRING "The user apache or the local web server runs on. Leave empty for automatic detection. If that fails, you can use this variable to force") set(ZM_SOCKDIR "/var/run/zm" CACHE PATH
set(ZM_WEB_GROUP "" CACHE STRING "The group apache or the local web server runs on, Leave empty to be the same as the web user") "Location of Unix domain socket files, default /var/run/zm")
set(ZM_TMPDIR "/var/tmp/zm" CACHE PATH
"Location of temporary files, default: /tmp/zm")
set(ZM_LOGDIR "/var/log/zm" CACHE PATH
"Location of generated log files, default: /var/log/zm")
set(ZM_WEBDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder/www" CACHE PATH
"Location of the web files, default: <prefix>/${CMAKE_INSTALL_DATADIR}/zoneminder/www")
set(ZM_CGIDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/cgi-bin" CACHE PATH
"Location of the cgi-bin files, default: <prefix>/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/cgi-bin")
set(ZM_CONTENTDIR "/var/lib/zoneminder" CACHE PATH
"Location of dynamic content (events and images), default: /var/lib/zoneminder")
set(ZM_DB_HOST "localhost" CACHE STRING
"Hostname where ZoneMinder database located, default: localhost")
set(ZM_DB_NAME "zm" CACHE STRING
"Name of ZoneMinder database, default: zm")
set(ZM_DB_USER "zmuser" CACHE STRING
"Name of ZoneMinder database user, default: zmuser")
set(ZM_DB_PASS "zmpass" CACHE STRING
"Password of ZoneMinder database user, default: zmpass")
set(ZM_WEB_USER "" CACHE STRING
"The user apache or the local web server runs on. Leave empty for automatic detection.
If that fails, you can use this variable to force")
set(ZM_WEB_GROUP "" CACHE STRING
"The group apache or the local web server runs on,
Leave empty to be the same as the web user")
# Advanced # Advanced
set(ZM_EXTRA_LIBS "" CACHE STRING "A list of optional libraries, separated by semicolons, e.g. ssl;theora") set(ZM_CONFIG_DIR "/${CMAKE_INSTALL_SYSCONFDIR}" CACHE PATH
set(ZM_MYSQL_ENGINE "InnoDB" CACHE STRING "MySQL engine to use with database, default: InnoDB") "Location of ZoneMinder configuration, default system config directory")
set(ZM_NO_MMAP "OFF" CACHE BOOL "Set to ON to not use mmap shared memory. Shouldn't be enabled unless you experience problems with the shared memory. default: OFF") set(ZM_EXTRA_LIBS "" CACHE STRING
set(ZM_NO_FFMPEG "OFF" CACHE BOOL "Set to ON to skip ffmpeg checks and force building ZM without ffmpeg. default: OFF") "A list of optional libraries, separated by semicolons, e.g. ssl;theora")
set(ZM_NO_LIBVLC "OFF" CACHE BOOL "Set to ON to skip libvlc checks and force building ZM without libvlc. default: OFF") set(ZM_MYSQL_ENGINE "InnoDB" CACHE STRING
set(ZM_NO_CURL "OFF" CACHE BOOL "Set to ON to skip cURL checks and force building ZM without cURL. default: OFF") "MySQL engine to use with database, default: InnoDB")
set(ZM_NO_X10 "OFF" CACHE BOOL "Set to ON to build ZoneMinder without X10 support. default: OFF") set(ZM_NO_MMAP "OFF" CACHE BOOL
set(ZM_PERL_SUBPREFIX "${CMAKE_INSTALL_LIBDIR}/perl5" CACHE PATH "Use a different directory for the zm perl modules. NOTE: This is a subprefix, e.g. lib will be turned into <prefix>/lib, default: <libdir>/perl5") "Set to ON to not use mmap shared memory. Shouldn't be enabled unless you
set(ZM_PERL_USE_PATH "${CMAKE_INSTALL_PREFIX}/${ZM_PERL_SUBPREFIX}" CACHE PATH "Override the include path for zm perl modules. Useful if you are moving the perl modules without using the ZM_PERL_SUBPREFIX option. default: <prefix>/<zmperlsubprefix>") experience problems with the shared memory. default: OFF")
set(ZM_TARGET_DISTRO "" CACHE STRING "Build ZoneMinder for a specific distribution. Currently, valid names are: f19, f20, el6, OS13") set(ZM_NO_FFMPEG "OFF" CACHE BOOL
"Set to ON to skip ffmpeg checks and force building ZM without ffmpeg. default: OFF")
set(ZM_NO_LIBVLC "OFF" CACHE BOOL
"Set to ON to skip libvlc checks and force building ZM without libvlc. default: OFF")
set(ZM_NO_CURL "OFF" CACHE BOOL
"Set to ON to skip cURL checks and force building ZM without cURL. default: OFF")
set(ZM_NO_X10 "OFF" CACHE BOOL
"Set to ON to build ZoneMinder without X10 support. default: OFF")
set(ZM_ONVIF "ON" CACHE BOOL
"Set to ON to enable basic ONVIF support. This is EXPERIMENTAL and may not
work with all cameras claiming to be ONVIF compliant. default: ON")
set(ZM_PERL_MM_PARMS INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 CACHE STRING
"By default, ZoneMinder's Perl modules are installed into the Vendor folders,
as defined by your installation of Perl. You can change that here. Consult Perl's
MakeMaker documentation for a definition of acceptable parameters. If you set this
to something that causes the modules to be installed outside Perl's normal search
path, then you will also need to set ZM_PERL_SEARCH_PATH accordingly.")
set(ZM_PERL_SEARCH_PATH "" CACHE PATH
"Use to add a folder to your Perl's search path. This will need to be set in cases
where ZM_PERL_MM_PARMS has been modified such that ZoneMinder's Perl modules are
installed outside Perl's default search path.")
set(ZM_TARGET_DISTRO "" CACHE STRING
"Build ZoneMinder for a specific distribution. Currently, valid names are: f22, f23, el6, el7, OS13")
# Reassign some variables if a target distro has been specified # Reassign some variables if a target distro has been specified
if((ZM_TARGET_DISTRO STREQUAL "f19") OR (ZM_TARGET_DISTRO STREQUAL "f20") OR (ZM_TARGET_DISTRO STREQUAL "el6")) if((ZM_TARGET_DISTRO STREQUAL "f22") OR (ZM_TARGET_DISTRO STREQUAL "f23"))
set(ZM_RUNDIR "/var/run/zoneminder") set(ZM_RUNDIR "/var/run/zoneminder")
set(ZM_SOCKDIR "/var/lib/zoneminder/sock") set(ZM_SOCKDIR "/var/lib/zoneminder/sock")
set(ZM_TMPDIR "/var/lib/zoneminder/temp") set(ZM_TMPDIR "/var/lib/zoneminder/temp")
set(ZM_LOGDIR "/var/log/zoneminder") set(ZM_LOGDIR "/var/log/zoneminder")
set(ZM_CONFIG_DIR "/etc/zm")
set(ZM_WEBDIR "/usr/share/zoneminder/www")
set(ZM_CGIDIR "/usr/libexec/zoneminder/cgi-bin")
elseif(ZM_TARGET_DISTRO STREQUAL "el6")
set(ZM_RUNDIR "/var/run/zoneminder")
set(ZM_SOCKDIR "/var/lib/zoneminder/sock")
set(ZM_TMPDIR "/var/lib/zoneminder/temp")
set(ZM_LOGDIR "/var/log/zoneminder")
set(ZM_WEBDIR "/usr/share/zoneminder/www")
set(ZM_CGIDIR "/usr/libexec/zoneminder/cgi-bin")
elseif(ZM_TARGET_DISTRO STREQUAL "el7")
set(ZM_RUNDIR "/var/run/zoneminder")
set(ZM_SOCKDIR "/var/lib/zoneminder/sock")
set(ZM_TMPDIR "/var/lib/zoneminder/temp")
set(ZM_LOGDIR "/var/log/zoneminder")
set(ZM_CONFIG_DIR "/etc/zm")
set(ZM_WEBDIR "/usr/share/zoneminder/www")
set(ZM_CGIDIR "/usr/libexec/zoneminder/cgi-bin")
elseif(ZM_TARGET_DISTRO STREQUAL "OS13") elseif(ZM_TARGET_DISTRO STREQUAL "OS13")
set(ZM_RUNDIR "/var/run/zoneminder") set(ZM_RUNDIR "/var/run/zoneminder")
set(ZM_TMPDIR "/var/run/zoneminder") set(ZM_TMPDIR "/var/run/zoneminder")
@ -85,32 +182,66 @@ elseif(ZM_TARGET_DISTRO STREQUAL "OS13")
set(ZM_WEB_GROUP "www") set(ZM_WEB_GROUP "www")
set(ZM_WEBDIR "/srv/www/htdocs/zoneminder") set(ZM_WEBDIR "/srv/www/htdocs/zoneminder")
set(ZM_CGIDIR "/srv/www/cgi-bin") set(ZM_CGIDIR "/srv/www/cgi-bin")
endif((ZM_TARGET_DISTRO STREQUAL "f19") OR (ZM_TARGET_DISTRO STREQUAL "f20") OR (ZM_TARGET_DISTRO STREQUAL "el6")) elseif(ZM_TARGET_DISTRO STREQUAL "FreeBSD")
set(ZM_RUNDIR "/var/run/zm")
set(ZM_SOCKDIR "/var/run/zm")
set(ZM_TMPDIR "/var/tmp/zm")
set(ZM_CONTENTDIR "/usr/local/var/lib/zoneminder")
set(ZM_WEB_USER "www")
set(ZM_WEB_GROUP "www")
set(ZM_CONFIG_DIR "/usr/local/etc/zm")
set(ZM_WEBDIR "/usr/local/share/zoneminder/www")
set(ZM_CGIDIR "/usr/local/libexec/zoneminder/cgi-bin")
set(ZM_PERL_MM_PARMS "INSTALLDIRS=site")
endif((ZM_TARGET_DISTRO STREQUAL "f22") OR (ZM_TARGET_DISTRO STREQUAL "f23"))
# Required for certain checks to work # Required for certain checks to work
set(CMAKE_EXTRA_INCLUDE_FILES ${CMAKE_EXTRA_INCLUDE_FILES} stdio.h stdlib.h math.h signal.h) set(CMAKE_EXTRA_INCLUDE_FILES
${CMAKE_EXTRA_INCLUDE_FILES} stdio.h stdlib.h math.h signal.h
)
# Required for including headers from the this folder # Required for including headers from the this folder
include_directories("${CMAKE_BINARY_DIR}") include_directories("${CMAKE_BINARY_DIR}")
# This is required to enable searching in lib64 (if exists), do not change # This is required to enable searching in lib64 (if exists), do not change
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS ON) set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS ON)
# System checks # System checks
check_include_file("linux/videodev.h" HAVE_LINUX_VIDEODEV_H) check_include_file("libv4l1-videodev.h" HAVE_LIBV4L1_VIDEODEV_H)
if(NOT HAVE_LIBV4L1_VIDEODEV_H)
check_include_file("linux/videodev.h" HAVE_LINUX_VIDEODEV_H)
endif(NOT HAVE_LIBV4L1_VIDEODEV_H)
check_include_file("linux/videodev2.h" HAVE_LINUX_VIDEODEV2_H) check_include_file("linux/videodev2.h" HAVE_LINUX_VIDEODEV2_H)
check_include_file("execinfo.h" HAVE_EXECINFO_H) check_include_file("execinfo.h" HAVE_EXECINFO_H)
if (HAVE_EXECINFO_H)
check_function_exists("backtrace" HAVE_DECL_BACKTRACE)
if (NOT HAVE_DECL_BACKTRACE)
find_library (EXECINFO_LIBRARY NAMES execinfo)
if (EXECINFO_LIBRARY)
list(APPEND ZM_BIN_LIBS "-lexecinfo")
endif (EXECINFO_LIBRARY)
endif (NOT HAVE_DECL_BACKTRACE)
check_function_exists("backtrace_symbols" HAVE_DECL_BACKTRACE_SYMBOLS)
endif (HAVE_EXECINFO_H)
check_include_file("ucontext.h" HAVE_UCONTEXT_H) check_include_file("ucontext.h" HAVE_UCONTEXT_H)
check_include_file("sys/sendfile.h" HAVE_SYS_SENDFILE_H) check_include_file("sys/sendfile.h" HAVE_SYS_SENDFILE_H)
check_include_file("sys/syscall.h" HAVE_SYS_SYSCALL_H) check_include_file("sys/syscall.h" HAVE_SYS_SYSCALL_H)
check_function_exists("syscall" HAVE_SYSCALL) check_function_exists("syscall" HAVE_SYSCALL)
check_function_exists("sendfile" HAVE_SENDFILE) check_function_exists("sendfile" HAVE_SENDFILE)
check_function_exists("backtrace" HAVE_DECL_BACKTRACE)
check_function_exists("backtrace_symbols" HAVE_DECL_BACKTRACE_SYMBOLS)
check_function_exists("posix_memalign" HAVE_POSIX_MEMALIGN) check_function_exists("posix_memalign" HAVE_POSIX_MEMALIGN)
check_type_size("siginfo_t" HAVE_SIGINFO_T) check_type_size("siginfo_t" HAVE_SIGINFO_T)
check_type_size("ucontext_t" HAVE_UCONTEXT_T) check_type_size("ucontext_t" HAVE_UCONTEXT_T)
# *** LIBRARY CHECKS *** # *** LIBRARY CHECKS ***
if (UNIX)
include (CheckLibraryExists)
CHECK_LIBRARY_EXISTS(rt clock_gettime "time.h" HAVE_CLOCK_GETTIME)
if(NOT HAVE_CLOCK_GETTIME)
message(FATAL_ERROR "clock_gettime not found")
else(NOT HAVE_CLOCK_GETTIME)
list(APPEND ZM_BIN_LIBS "-lrt")
endif(NOT HAVE_CLOCK_GETTIME)
endif(UNIX)
# zlib # zlib
find_package(ZLIB) find_package(ZLIB)
if(ZLIB_FOUND) if(ZLIB_FOUND)
@ -150,10 +281,12 @@ if(JPEG_FOUND)
set(CMAKE_REQUIRED_INCLUDES "${JPEG_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${JPEG_INCLUDE_DIR}")
check_include_files("stdio.h;jpeglib.h" HAVE_JPEGLIB_H) check_include_files("stdio.h;jpeglib.h" HAVE_JPEGLIB_H)
if(NOT HAVE_JPEGLIB_H) if(NOT HAVE_JPEGLIB_H)
message(FATAL_ERROR " zm requires libjpeg headers - check that libjpeg development packages are installed") message(FATAL_ERROR
"ZoneMinder requires libjpeg headers - check that libjpeg development packages are installed")
endif(NOT HAVE_JPEGLIB_H) endif(NOT HAVE_JPEGLIB_H)
else(JPEG_FOUND) else(JPEG_FOUND)
message(FATAL_ERROR "zm requires jpeg but it was not found on your system") message(FATAL_ERROR
"ZoneMinder requires jpeg but it was not found on your system")
endif(JPEG_FOUND) endif(JPEG_FOUND)
# OpenSSL # OpenSSL
@ -183,10 +316,12 @@ if(PTHREAD_LIBRARIES)
mark_as_advanced(FORCE PTHREAD_LIBRARIES PTHREAD_INCLUDE_DIR) mark_as_advanced(FORCE PTHREAD_LIBRARIES PTHREAD_INCLUDE_DIR)
check_include_file("pthread.h" HAVE_PTHREAD_H) check_include_file("pthread.h" HAVE_PTHREAD_H)
if(NOT HAVE_PTHREAD_H) if(NOT HAVE_PTHREAD_H)
message(FATAL_ERROR " zm requires pthread headers - check that pthread development packages are installed") message(FATAL_ERROR
"ZoneMinder requires pthread headers - check that pthread development packages are installed")
endif(NOT HAVE_PTHREAD_H) endif(NOT HAVE_PTHREAD_H)
else(PTHREAD_LIBRARIES) else(PTHREAD_LIBRARIES)
message(FATAL_ERROR "zm requires pthread but it was not found on your system") message(FATAL_ERROR
"ZoneMinder requires pthread but it was not found on your system")
endif(PTHREAD_LIBRARIES) endif(PTHREAD_LIBRARIES)
# pcre (using find_library and find_path) # pcre (using find_library and find_path)
@ -258,10 +393,12 @@ if(MYSQLCLIENT_LIBRARIES)
mark_as_advanced(FORCE MYSQLCLIENT_LIBRARIES MYSQLCLIENT_INCLUDE_DIR) mark_as_advanced(FORCE MYSQLCLIENT_LIBRARIES MYSQLCLIENT_INCLUDE_DIR)
check_include_file("mysql/mysql.h" HAVE_MYSQL_H) check_include_file("mysql/mysql.h" HAVE_MYSQL_H)
if(NOT HAVE_MYSQL_H) if(NOT HAVE_MYSQL_H)
message(FATAL_ERROR "zm requires MySQL headers - check that MySQL development packages are installed") message(FATAL_ERROR
"ZoneMinder requires MySQL headers - check that MySQL development packages are installed")
endif(NOT HAVE_MYSQL_H) endif(NOT HAVE_MYSQL_H)
else(MYSQLCLIENT_LIBRARIES) else(MYSQLCLIENT_LIBRARIES)
message(FATAL_ERROR "zm requires mysqlclient but it was not found on your system") message(FATAL_ERROR
"ZoneMinder requires mysqlclient but it was not found on your system")
endif(MYSQLCLIENT_LIBRARIES) endif(MYSQLCLIENT_LIBRARIES)
set(PATH_FFMPEG "") set(PATH_FFMPEG "")
@ -273,7 +410,7 @@ if(NOT ZM_NO_FFMPEG)
if(AVFORMAT_LIBRARIES) if(AVFORMAT_LIBRARIES)
set(HAVE_LIBAVFORMAT 1) set(HAVE_LIBAVFORMAT 1)
list(APPEND ZM_BIN_LIBS "${AVFORMAT_LIBRARIES}") list(APPEND ZM_BIN_LIBS "${AVFORMAT_LIBRARIES}")
find_path(AVFORMAT_INCLUDE_DIR "libavformat/avformat.h") find_path(AVFORMAT_INCLUDE_DIR "libavformat/avformat.h" /usr/include/ffmpeg)
if(AVFORMAT_INCLUDE_DIR) if(AVFORMAT_INCLUDE_DIR)
include_directories("${AVFORMAT_INCLUDE_DIR}") include_directories("${AVFORMAT_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVFORMAT_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${AVFORMAT_INCLUDE_DIR}")
@ -290,7 +427,7 @@ if(NOT ZM_NO_FFMPEG)
if(AVCODEC_LIBRARIES) if(AVCODEC_LIBRARIES)
set(HAVE_LIBAVCODEC 1) set(HAVE_LIBAVCODEC 1)
list(APPEND ZM_BIN_LIBS "${AVCODEC_LIBRARIES}") list(APPEND ZM_BIN_LIBS "${AVCODEC_LIBRARIES}")
find_path(AVCODEC_INCLUDE_DIR "libavcodec/avcodec.h") find_path(AVCODEC_INCLUDE_DIR "libavcodec/avcodec.h" /usr/include/ffmpeg)
if(AVCODEC_INCLUDE_DIR) if(AVCODEC_INCLUDE_DIR)
include_directories("${AVCODEC_INCLUDE_DIR}") include_directories("${AVCODEC_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVCODEC_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${AVCODEC_INCLUDE_DIR}")
@ -307,7 +444,7 @@ if(NOT ZM_NO_FFMPEG)
if(AVDEVICE_LIBRARIES) if(AVDEVICE_LIBRARIES)
set(HAVE_LIBAVDEVICE 1) set(HAVE_LIBAVDEVICE 1)
list(APPEND ZM_BIN_LIBS "${AVDEVICE_LIBRARIES}") list(APPEND ZM_BIN_LIBS "${AVDEVICE_LIBRARIES}")
find_path(AVDEVICE_INCLUDE_DIR "libavdevice/avdevice.h") find_path(AVDEVICE_INCLUDE_DIR "libavdevice/avdevice.h" /usr/include/ffmpeg)
if(AVDEVICE_INCLUDE_DIR) if(AVDEVICE_INCLUDE_DIR)
include_directories("${AVDEVICE_INCLUDE_DIR}") include_directories("${AVDEVICE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVDEVICE_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${AVDEVICE_INCLUDE_DIR}")
@ -324,7 +461,7 @@ if(NOT ZM_NO_FFMPEG)
if(AVUTIL_LIBRARIES) if(AVUTIL_LIBRARIES)
set(HAVE_LIBAVUTIL 1) set(HAVE_LIBAVUTIL 1)
list(APPEND ZM_BIN_LIBS "${AVUTIL_LIBRARIES}") list(APPEND ZM_BIN_LIBS "${AVUTIL_LIBRARIES}")
find_path(AVUTIL_INCLUDE_DIR "libavutil/avutil.h") find_path(AVUTIL_INCLUDE_DIR "libavutil/avutil.h" /usr/include/ffmpeg)
if(AVUTIL_INCLUDE_DIR) if(AVUTIL_INCLUDE_DIR)
include_directories("${AVUTIL_INCLUDE_DIR}") include_directories("${AVUTIL_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVUTIL_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${AVUTIL_INCLUDE_DIR}")
@ -342,7 +479,7 @@ if(NOT ZM_NO_FFMPEG)
if(SWSCALE_LIBRARIES) if(SWSCALE_LIBRARIES)
set(HAVE_LIBSWSCALE 1) set(HAVE_LIBSWSCALE 1)
list(APPEND ZM_BIN_LIBS "${SWSCALE_LIBRARIES}") list(APPEND ZM_BIN_LIBS "${SWSCALE_LIBRARIES}")
find_path(SWSCALE_INCLUDE_DIR "libswscale/swscale.h") find_path(SWSCALE_INCLUDE_DIR "libswscale/swscale.h" /usr/include/ffmpeg)
if(SWSCALE_INCLUDE_DIR) if(SWSCALE_INCLUDE_DIR)
include_directories("${SWSCALE_INCLUDE_DIR}") include_directories("${SWSCALE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${SWSCALE_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${SWSCALE_INCLUDE_DIR}")
@ -355,7 +492,9 @@ if(NOT ZM_NO_FFMPEG)
endif(SWSCALE_LIBRARIES) endif(SWSCALE_LIBRARIES)
# Find the path to the ffmpeg executable # Find the path to the ffmpeg executable
find_program(FFMPEG_EXECUTABLE ffmpeg PATH_SUFFIXES ffmpeg) find_program(FFMPEG_EXECUTABLE
NAMES ffmpeg avconv
PATH_SUFFIXES ffmpeg)
if(FFMPEG_EXECUTABLE) if(FFMPEG_EXECUTABLE)
set(PATH_FFMPEG "${FFMPEG_EXECUTABLE}") set(PATH_FFMPEG "${FFMPEG_EXECUTABLE}")
set(OPT_FFMPEG "yes") set(OPT_FFMPEG "yes")
@ -388,7 +527,8 @@ endif(NOT ZM_NO_LIBVLC)
# Check for gnutls or crypto # Check for gnutls or crypto
if((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS)) if((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS))
message(FATAL_ERROR " zm requires crypto or gnutls but none were found on your system") message(FATAL_ERROR
"ZoneMinder requires crypto or gnutls but none were found on your system")
endif((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS)) endif((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS))
# Check for V4L header files and enable ZM_HAS_V4L, ZM_HAS_V4L1, ZM_HAS_V4L2 accordingly # Check for V4L header files and enable ZM_HAS_V4L, ZM_HAS_V4L1, ZM_HAS_V4L2 accordingly
@ -396,17 +536,22 @@ endif((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS))
set(ZM_HAS_V4L 0) set(ZM_HAS_V4L 0)
set(ZM_HAS_V4L1 0) set(ZM_HAS_V4L1 0)
set(ZM_HAS_V4L2 0) set(ZM_HAS_V4L2 0)
if(HAVE_LINUX_VIDEODEV_H) if(HAVE_LINUX_VIDEODEV_H OR HAVE_LIBV4L1_VIDEODEV_H)
set(ZM_HAS_V4L 1) set(ZM_HAS_V4L 1)
set(ZM_HAS_V4L1 1) set(ZM_HAS_V4L1 1)
endif(HAVE_LINUX_VIDEODEV_H) endif(HAVE_LINUX_VIDEODEV_H OR HAVE_LIBV4L1_VIDEODEV_H)
if(HAVE_LINUX_VIDEODEV2_H) if(HAVE_LINUX_VIDEODEV2_H)
set(ZM_HAS_V4L 1) set(ZM_HAS_V4L 1)
set(ZM_HAS_V4L2 1) set(ZM_HAS_V4L2 1)
endif(HAVE_LINUX_VIDEODEV2_H) endif(HAVE_LINUX_VIDEODEV2_H)
if((NOT HAVE_LINUX_VIDEODEV_H) AND (NOT HAVE_LINUX_VIDEODEV2_H)) if((NOT HAVE_LINUX_VIDEODEV_H)
message(AUTHOR_WARNING " Video 4 Linux headers weren't found - Analog and USB camera support will not be available") AND (NOT HAVE_LIBV4L1_VIDEODEV_H)
endif((NOT HAVE_LINUX_VIDEODEV_H) AND (NOT HAVE_LINUX_VIDEODEV2_H)) AND (NOT HAVE_LINUX_VIDEODEV2_H))
message(AUTHOR_WARNING
"Video 4 Linux headers weren't found - Analog and USB camera support will not be available")
endif((NOT HAVE_LINUX_VIDEODEV_H)
AND (NOT HAVE_LIBV4L1_VIDEODEV_H)
AND (NOT HAVE_LINUX_VIDEODEV2_H))
# Check for PCRE and enable ZM_PCRE accordingly # Check for PCRE and enable ZM_PCRE accordingly
set(ZM_PCRE 0) set(ZM_PCRE 0)
if(HAVE_LIBPCRE AND HAVE_PCRE_H) if(HAVE_LIBPCRE AND HAVE_PCRE_H)
@ -421,26 +566,43 @@ if(NOT ZM_NO_MMAP)
set(ZM_MMAP_PERLPACKAGE "Sys::Mmap") set(ZM_MMAP_PERLPACKAGE "Sys::Mmap")
endif(NOT ZM_NO_MMAP) endif(NOT ZM_NO_MMAP)
# Check for authenication functions # Check for the ONVIF flag and enable ZM_HAS_ONVIF accordingly
set(ZM_HAS_ONVIF 0)
if(ZM_ONVIF)
set(ZM_HAS_ONVIF 1)
endif(ZM_ONVIF)
# Check for authentication functions
if(HAVE_OPENSSL_MD5_H) if(HAVE_OPENSSL_MD5_H)
set(CMAKE_REQUIRED_LIBRARIES "${OPENSSL_LIBRARIES}") set(CMAKE_REQUIRED_LIBRARIES "${OPENSSL_LIBRARIES}")
set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}")
check_prototype_definition(MD5 "unsigned char *MD5(const unsigned char *d, size_t n, unsigned char *md)" "NULL" "openssl/md5.h" HAVE_MD5_OPENSSL) check_prototype_definition(
MD5
"unsigned char *MD5(const unsigned char *d, size_t n, unsigned char *md)" "NULL" "openssl/md5.h"
HAVE_MD5_OPENSSL)
endif(HAVE_OPENSSL_MD5_H) endif(HAVE_OPENSSL_MD5_H)
if(HAVE_GNUTLS_OPENSSL_H) if(HAVE_GNUTLS_OPENSSL_H)
set(CMAKE_REQUIRED_LIBRARIES "${GNUTLS_LIBRARIES}") set(CMAKE_REQUIRED_LIBRARIES "${GNUTLS_LIBRARIES}")
set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}")
check_prototype_definition(MD5 "unsigned char *MD5 (const unsigned char *buf, unsigned long len, unsigned char *md)" "NULL" "gnutls/openssl.h" HAVE_MD5_GNUTLS) check_prototype_definition(
MD5
"unsigned char *MD5 (const unsigned char *buf, unsigned long len, unsigned char *md)" "NULL" "gnutls/openssl.h"
HAVE_MD5_GNUTLS)
endif(HAVE_GNUTLS_OPENSSL_H) endif(HAVE_GNUTLS_OPENSSL_H)
if(HAVE_GNUTLS_GNUTLS_H) if(HAVE_GNUTLS_GNUTLS_H)
set(CMAKE_REQUIRED_LIBRARIES "${GNUTLS_LIBRARIES}") set(CMAKE_REQUIRED_LIBRARIES "${GNUTLS_LIBRARIES}")
set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}") set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}")
check_prototype_definition(gnutls_fingerprint "int gnutls_fingerprint (gnutls_digest_algorithm_t algo, const gnutls_datum_t * data, void *result, size_t * result_size)" "0" "stdlib.h;gnutls/gnutls.h" HAVE_DECL_GNUTLS_FINGERPRINT) check_prototype_definition(
gnutls_fingerprint
"int gnutls_fingerprint (gnutls_digest_algorithm_t algo, const gnutls_datum_t * data, void *result, size_t * result_size)" "0" "stdlib.h;gnutls/gnutls.h"
HAVE_DECL_GNUTLS_FINGERPRINT)
endif(HAVE_GNUTLS_GNUTLS_H) endif(HAVE_GNUTLS_GNUTLS_H)
if(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS) if(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS)
set(HAVE_DECL_MD5 1) set(HAVE_DECL_MD5 1)
else(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS) else(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS)
message(AUTHOR_WARNING " ZM requires a working MD5 function for hashed authenication but none were found - hashed authenication will not be available") message(AUTHOR_WARNING
"ZoneMinder requires a working MD5 function for hashed authenication but
none were found - hashed authenication will not be available")
endif(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS) endif(HAVE_MD5_OPENSSL OR HAVE_MD5_GNUTLS)
# Dirty fix for zm_user only using openssl's md5 if gnutls and gcrypt are not available. # Dirty fix for zm_user only using openssl's md5 if gnutls and gcrypt are not available.
# This needs to be fixed in zm_user.[h,cpp] but such fix will also require changes to configure.ac # This needs to be fixed in zm_user.[h,cpp] but such fix will also require changes to configure.ac
@ -452,26 +614,40 @@ endif(HAVE_LIBCRYPTO AND HAVE_OPENSSL_MD5_H AND HAVE_MD5_OPENSSL)
# Check for Perl # Check for Perl
find_package(Perl) find_package(Perl)
if(NOT PERL_FOUND) if(NOT PERL_FOUND)
message(FATAL_ERROR "zm requires Perl 5.6.0 or newer but it was not found on your system") message(FATAL_ERROR
"ZoneMinder requires Perl 5.6.0 or newer but it was not found on your system")
endif(NOT PERL_FOUND) endif(NOT PERL_FOUND)
# Checking for perl modules requires FindPerlModules.cmake # Checking for perl modules requires FindPerlModules.cmake
# Check all required modules at once # Check all required modules at once
# TODO: Add checking for the optional modules # TODO: Add checking for the optional modules
find_package(PerlModules COMPONENTS Sys::Syslog DBI DBD::mysql Getopt::Long Time::HiRes Date::Manip LWP::UserAgent ExtUtils::MakeMaker ${ZM_MMAP_PERLPACKAGE}) find_package(
PerlModules COMPONENTS Sys::Syslog DBI DBD::mysql
Getopt::Long Time::HiRes Date::Manip LWP::UserAgent
ExtUtils::MakeMaker ${ZM_MMAP_PERLPACKAGE})
if(NOT PERLMODULES_FOUND) if(NOT PERLMODULES_FOUND)
message(FATAL_ERROR "Not all required perl modules were found on your system") message(FATAL_ERROR
"Not all required perl modules were found on your system")
endif(NOT PERLMODULES_FOUND) endif(NOT PERLMODULES_FOUND)
# Attempt to check which user apache (or other web server) runs on by searching for a user beginning with apache or www and then cutting the user from the first matching user line # Attempt to check which user apache (or other web server) runs on by
# searching for a user beginning with apache or www and then cutting the user
# from the first matching user line
if(ZM_WEB_USER STREQUAL "") if(ZM_WEB_USER STREQUAL "")
# Check for a user matching ^apache and cut the username from the userline in the first match # Check for a user matching ^apache and cut the username from the
# userline in the first match
file(STRINGS "/etc/passwd" userline_apache REGEX "^apache") file(STRINGS "/etc/passwd" userline_apache REGEX "^apache")
file(STRINGS "/etc/passwd" userline_www REGEX "^www") file(STRINGS "/etc/passwd" userline_www REGEX "^www")
if(NOT (userline_apache STREQUAL "")) if(NOT (userline_apache STREQUAL ""))
execute_process(COMMAND echo ${userline_apache} COMMAND cut -d: -f1 OUTPUT_VARIABLE ZM_WEB_USER OUTPUT_STRIP_TRAILING_WHITESPACE) execute_process(
COMMAND echo ${userline_apache}
COMMAND cut -d: -f1 OUTPUT_VARIABLE ZM_WEB_USER
OUTPUT_STRIP_TRAILING_WHITESPACE)
elseif(NOT (userline_www STREQUAL "")) elseif(NOT (userline_www STREQUAL ""))
execute_process(COMMAND echo ${userline_www} COMMAND cut -d: -f1 OUTPUT_VARIABLE ZM_WEB_USER OUTPUT_STRIP_TRAILING_WHITESPACE) execute_process(
COMMAND echo ${userline_www}
COMMAND cut -d: -f1 OUTPUT_VARIABLE ZM_WEB_USER
OUTPUT_STRIP_TRAILING_WHITESPACE)
endif(NOT (userline_apache STREQUAL "")) endif(NOT (userline_apache STREQUAL ""))
message(STATUS "Detected web server user: ${ZM_WEB_USER}") message(STATUS "Detected web server user: ${ZM_WEB_USER}")
endif(ZM_WEB_USER STREQUAL "") endif(ZM_WEB_USER STREQUAL "")
@ -485,13 +661,15 @@ message(STATUS "Using web group: ${ZM_WEB_GROUP}")
# Check for polkit # Check for polkit
find_package(Polkit) find_package(Polkit)
if(NOT POLKIT_FOUND) if(NOT POLKIT_FOUND)
message(FATAL_ERROR "Running ZoneMinder requires polkit. Building ZoneMinder requires the polkit development package.") message(FATAL_ERROR
"Running ZoneMinder requires polkit. Building ZoneMinder requires the polkit development package.")
endif(NOT POLKIT_FOUND) endif(NOT POLKIT_FOUND)
# Some variables that zm expects # Some variables that zm expects
set(ZM_PID "${ZM_RUNDIR}/zm.pid") set(ZM_PID "${ZM_RUNDIR}/zm.pid")
set(ZM_CONFIG "/${CMAKE_INSTALL_SYSCONFDIR}/zm.conf") set(ZM_CONFIG "${ZM_CONFIG_DIR}/zm.conf")
set(VERSION "${zoneminder_VERSION}") set(VERSION "${zoneminder_VERSION}")
set(API_VERSION "${zoneminder_API_VERSION}")
set(PKGDATADIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder") set(PKGDATADIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder")
set(BINDIR "${CMAKE_INSTALL_FULL_BINDIR}") set(BINDIR "${CMAKE_INSTALL_FULL_BINDIR}")
set(LIBDIR "${CMAKE_INSTALL_FULL_LIBDIR}") set(LIBDIR "${CMAKE_INSTALL_FULL_LIBDIR}")
@ -501,7 +679,11 @@ set(CGI_PREFIX "${ZM_CGIDIR}")
set(WEB_USER "${ZM_WEB_USER}") set(WEB_USER "${ZM_WEB_USER}")
set(WEB_GROUP "${ZM_WEB_GROUP}") set(WEB_GROUP "${ZM_WEB_GROUP}")
set(ZM_DB_TYPE "mysql") set(ZM_DB_TYPE "mysql")
set(EXTRA_PERL_LIB "use lib '${ZM_PERL_USE_PATH}';") if(ZM_PERL_SEARCH_PATH)
set(EXTRA_PERL_LIB "use lib '${ZM_PERL_SEARCH_PATH}'; # Include custom perl install path")
else(ZM_PERL_SEARCH_PATH)
set(EXTRA_PERL_LIB "# Include from system perl paths only")
endif(ZM_PERL_SEARCH_PATH)
# Generate files from the .in files # Generate files from the .in files
configure_file(zm.conf.in "${CMAKE_CURRENT_BINARY_DIR}/zm.conf" @ONLY) configure_file(zm.conf.in "${CMAKE_CURRENT_BINARY_DIR}/zm.conf" @ONLY)
@ -509,6 +691,10 @@ configure_file(zoneminder-config.cmake "${CMAKE_CURRENT_BINARY_DIR}/config.h" @O
configure_file(zmconfgen.pl.in "${CMAKE_CURRENT_BINARY_DIR}/zmconfgen.pl" @ONLY) configure_file(zmconfgen.pl.in "${CMAKE_CURRENT_BINARY_DIR}/zmconfgen.pl" @ONLY)
configure_file(zmlinkcontent.sh.in "${CMAKE_CURRENT_BINARY_DIR}/zmlinkcontent.sh" @ONLY) configure_file(zmlinkcontent.sh.in "${CMAKE_CURRENT_BINARY_DIR}/zmlinkcontent.sh" @ONLY)
# Create a target for man pages
include(Pod2Man)
ADD_MANPAGE_TARGET()
# Process subdirectories # Process subdirectories
add_subdirectory(src) add_subdirectory(src)
add_subdirectory(scripts) add_subdirectory(scripts)
@ -517,14 +703,19 @@ add_subdirectory(web)
add_subdirectory(misc) add_subdirectory(misc)
add_subdirectory(onvif) add_subdirectory(onvif)
# Enable ONVIF support
if(ZM_ONVIF)
add_subdirectory(onvif)
endif(ZM_ONVIF)
# Process distro subdirectories # Process distro subdirectories
if((ZM_TARGET_DISTRO STREQUAL "f19") OR (ZM_TARGET_DISTRO STREQUAL "f20")) if((ZM_TARGET_DISTRO STREQUAL "f22") OR (ZM_TARGET_DISTRO STREQUAL "f23"))
add_subdirectory(distros/fedora) add_subdirectory(distros/fedora)
elseif(ZM_TARGET_DISTRO STREQUAL "el6") elseif((ZM_TARGET_DISTRO STREQUAL "el6") OR (ZM_TARGET_DISTRO STREQUAL "el7"))
add_subdirectory(distros/redhat) add_subdirectory(distros/redhat)
elseif(ZM_TARGET_DISTRO STREQUAL "OS13") elseif(ZM_TARGET_DISTRO STREQUAL "OS13")
add_subdirectory(distros/opensuse) add_subdirectory(distros/opensuse)
endif((ZM_TARGET_DISTRO STREQUAL "f19") OR (ZM_TARGET_DISTRO STREQUAL "f20")) endif((ZM_TARGET_DISTRO STREQUAL "f22") OR (ZM_TARGET_DISTRO STREQUAL "f23"))
# Print optional libraries detection status # Print optional libraries detection status
message(STATUS "Optional libraries found:${optlibsfound}") message(STATUS "Optional libraries found:${optlibsfound}")
@ -534,13 +725,15 @@ message(STATUS "Optional libraries not found:${optlibsnotfound}")
message(STATUS "Running ZoneMinder configuration generator") message(STATUS "Running ZoneMinder configuration generator")
execute_process(COMMAND perl ./zmconfgen.pl RESULT_VARIABLE zmconfgen_result) execute_process(COMMAND perl ./zmconfgen.pl RESULT_VARIABLE zmconfgen_result)
if(zmconfgen_result EQUAL 0) if(zmconfgen_result EQUAL 0)
message(STATUS "ZoneMinder configuration generator completed successfully") message(STATUS
"ZoneMinder configuration generator completed successfully")
else(zmconfgen_result EQUAL 0) else(zmconfgen_result EQUAL 0)
message(FATAL_ERROR "ZoneMinder configuration generator failed. Exit code: ${zmconfgen_result}") message(FATAL_ERROR
"ZoneMinder configuration generator failed. Exit code: ${zmconfgen_result}")
endif(zmconfgen_result EQUAL 0) endif(zmconfgen_result EQUAL 0)
# Install zm.conf # Install zm.conf
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm.conf" DESTINATION "/${CMAKE_INSTALL_SYSCONFDIR}") install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm.conf" DESTINATION "${ZM_CONFIG_DIR}")
# Uninstall target # Uninstall target
configure_file( configure_file(

17
CONTRIBUTING.md Normal file
View File

@ -0,0 +1,17 @@
# Contributing
The ZoneMinder project was originally written by Philip Coombes in 2001. It has since moved to Github and is maintained by just a few who volunteer their spare time.
Over the years, ZoneMinder has accumulated a rather large user base. This presents a challenge to the development team when it comes to managing communications. Welcome to the world of software development, right?
In order to keep the kinds of issues, which require changes to the source code, separate from all other questions and comments, our methods of communication are organized in the following manner:
- The ZoneMinder Github forum is intended for bug reports and serious feature requests only
- The ZoneMinder user forum is intended for general questions and tech support
- The ZoneMinder IRC channel is intended for general questions and tech support
More details can be found in our [Github Posting Rules](https://github.com/ZoneMinder/ZoneMinder/wiki/Github-Posting-Rules). Please read this before creating an issue in our Github forum.
Knowledge of Github is a necessary first step to contribute to the project. To contribute, one must generate a pull request. For those just starting out, [this guide](https://github.com/ZoneMinder/ZoneMinder/wiki/Understanding-Github-and-Pull-Requests) will step you through the process.
Note that pasting code into our Github forum, with the expectation we will do the work for you, is not acceptable.

View File

@ -1,6 +1,6 @@
# ZoneMinder # ZoneMinder
FROM ubuntu:precise FROM ubuntu:trusty
MAINTAINER Kyle Johnson <kjohnson@gnulnx.net> MAINTAINER Kyle Johnson <kjohnson@gnulnx.net>
# Let the container know that there is no tty # Let the container know that there is no tty
@ -10,10 +10,13 @@ ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get install -y \ RUN apt-get update && apt-get install -y \
libpolkit-gobject-1-dev build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev \ libpolkit-gobject-1-dev build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev \
libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libpcre3 \ libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libpcre3 \
libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf libjpeg-turbo8-dev \ libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm cmake libjpeg-turbo8-dev \
libjpeg-turbo8 libtheora-dev libvorbis-dev libvpx-dev libx264-dev libmp4v2-dev ffmpeg mysql-client \ libjpeg-turbo8 libtheora-dev libvorbis-dev libvpx-dev libx264-dev libmp4v2-dev libav-tools mysql-client \
apache2 php5 php5-mysql apache2-mpm-prefork libapache2-mod-php5 php5-cli openssh-server \ apache2 php5 php5-mysql apache2-mpm-prefork libapache2-mod-php5 php5-cli openssh-server \
mysql-server libvlc-dev libvlc5 libvlccore-dev libvlccore5 vlc-data vlc libcurl4-openssl-dev mysql-server libvlc-dev libvlc5 libvlccore-dev libvlccore7 vlc-data libcurl4-openssl-dev \
libavformat-dev libswscale-dev libavutil-dev libavcodec-dev libavfilter-dev \
libavresample-dev libavdevice-dev libpostproc-dev libv4l-dev libtool libnetpbm10-dev \
libmime-lite-perl dh-autoreconf dpatch
# Copy local code into our container # Copy local code into our container
ADD . /ZoneMinder ADD . /ZoneMinder
@ -22,10 +25,11 @@ ADD . /ZoneMinder
WORKDIR /ZoneMinder WORKDIR /ZoneMinder
# Setup the ZoneMinder build environment # Setup the ZoneMinder build environment
RUN aclocal && autoheader && automake --force-missing --add-missing && autoconf #RUN aclocal && autoheader && automake --force-missing --add-missing && autoconf
# Configure ZoneMinder # Configure ZoneMinder
RUN ./configure --with-libarch=lib/$DEB_HOST_GNU_TYPE --disable-debug --host=$DEB_HOST_GNU_TYPE --build=$DEB_BUILD_GNU_TYPE --with-mysql=/usr --with-webdir=/var/www/zm --with-ffmpeg=/usr --with-cgidir=/usr/lib/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-mmap=yes ZM_SSL_LIB=openssl ZM_DB_USER=zm ZM_DB_PASS=zm #RUN ./configure --with-libarch=lib/$DEB_HOST_GNU_TYPE --disable-debug --host=$DEB_HOST_GNU_TYPE --build=$DEB_BUILD_GNU_TYPE --with-mysql=/usr --with-webdir=/var/www/zm --with-ffmpeg=/usr --with-cgidir=/usr/lib/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-mmap=yes --enable-onvif ZM_SSL_LIB=openssl ZM_DB_USER=zm ZM_DB_PASS=zm
RUN cmake .
# Build ZoneMinder # Build ZoneMinder
RUN make RUN make
@ -33,6 +37,9 @@ RUN make
# Install ZoneMinder # Install ZoneMinder
RUN make install RUN make install
# ensure writable folders
RUN ./zmlinkcontent.sh
# Adding the start script # Adding the start script
ADD utils/docker/start.sh /tmp/start.sh ADD utils/docker/start.sh /tmp/start.sh
@ -40,15 +47,23 @@ ADD utils/docker/start.sh /tmp/start.sh
# TODO - Files ADD'ed have 755 already...why do we need this? # TODO - Files ADD'ed have 755 already...why do we need this?
RUN chmod 755 /tmp/start.sh RUN chmod 755 /tmp/start.sh
# Creating SSH privledge escalation dir # give files in /usr/local/share/zoneminder/
RUN chown -R www-data:www-data /usr/local/share/zoneminder/
# Creating SSH privilege escalation dir
RUN mkdir /var/run/sshd RUN mkdir /var/run/sshd
# Adding apache virtual hosts file # Adding apache virtual hosts file
ADD utils/docker/apache-vhost /etc/apache2/sites-enabled/000-default ADD utils/docker/apache-vhost /etc/apache2/sites-available/000-default.conf
ADD utils/docker/phpdate.ini /etc/php5/apache2/conf.d/25-phpdate.ini
# Set the root passwd # Set the root passwd
RUN echo 'root:root' | chpasswd RUN echo 'root:root' | chpasswd
# Add a user we can actually login with
RUN useradd -m -s /bin/bash -G sudo zoneminder
RUN echo 'zoneminder:zoneminder' | chpasswd
# Expose ssh and http ports # Expose ssh and http ports
EXPOSE 80 EXPOSE 80
EXPOSE 22 EXPOSE 22

31
INSTALL
View File

@ -18,7 +18,7 @@ Important differences
--------------------- ---------------------
* Unlike the autotools way, the cmake way does not require any options. It attempts to detect some things by its own (system directories, libarch, web user and group) and uses defaults for others (installation paths and such). * Unlike the autotools way, the cmake way does not require any options. It attempts to detect some things by its own (system directories, libarch, web user and group) and uses defaults for others (installation paths and such).
* Unlike the autotools way, which links the binaries to a fixed list of libraries, the cmake way only links to libraries that it found on the system. If a library is not found, but required, a fatal error will be shown during the configuration step. * Unlike the autotools way, which links the binaries to a fixed list of libraries, the cmake way only links to libraries that it found on the system. If a library is not found, but required, a fatal error will be shown during the configuration step.
* Unlike the autotools way, the cmake way does not modify the system in any way it shouldnt. It only does what its supposed to do: Install files to your system. Nothing else and nothing leaks out of the DESTDIR environment variable (if used). This means that depending on your configuration, there might be an extra required step after installation: to link WEB_PATH/events and WEB_PATH/images folders to the correct places. * Unlike the autotools way, the cmake way does not modify the system in any way it shouldn't. It only does what its supposed to do: Install files to your system. Nothing else and nothing leaks out of the DESTDIR environment variable (if used). This means that depending on your configuration, there might be an extra required step after installation: to link WEB_PATH/events and WEB_PATH/images folders to the correct places.
Configuration Configuration
------------- -------------
@ -27,11 +27,15 @@ cmake by default does not require any parameters, but its possible to override t
Configuration can be done in 4 ways: Configuration can be done in 4 ways:
1) As a command line parameter, e.g. cmake -DCMAKE_VERBOSE_MAKEFILE=ON . 1) As a command line parameter, e.g. cmake -DCMAKE_VERBOSE_MAKEFILE=ON .
2) Using cmake-gui 2) Using cmake-gui
4) Providing cmake with an initial cache file with the -C option 3) Providing cmake with an initial cache file with the -C option
IMPORTANT: Do not use the -C option if any major part of your system, excluding the version of zoneminder, has changed.
For example, do not use this option if: you have upgraded your distro to a new version, have gone from 32 to 64 bits,
or have migrated from one machine to another.
4) By editing the cache file CMakeCache.txt (after it has been generated) - Not recommended 4) By editing the cache file CMakeCache.txt (after it has been generated) - Not recommended
Possible configuration options: Possible configuration options:
ZM_RUNDIR Location of transient process files, default: /var/run/zm ZM_RUNDIR Location of transient process files, default: /var/run/zm
ZM_SOCKDIR Location of Unix domain socket files, default /var/run/zm
ZM_TMPDIR Location of temporary files, default: /tmp/zm ZM_TMPDIR Location of temporary files, default: /tmp/zm
ZM_LOGDIR Location of generated log files, default: /var/log/zm ZM_LOGDIR Location of generated log files, default: /var/log/zm
ZM_WEBDIR Location of the web files, default: <prefix>/share/zoneminder/www ZM_WEBDIR Location of the web files, default: <prefix>/share/zoneminder/www
@ -49,9 +53,8 @@ Advanced:
ZM_NO_MMAP Set to ON to not use mmap shared memory. Shouldn't be enabled unless you experience problems with the shared memory. default: OFF ZM_NO_MMAP Set to ON to not use mmap shared memory. Shouldn't be enabled unless you experience problems with the shared memory. default: OFF
ZM_NO_FFMPEG Set to ON to skip ffmpeg checks and force building ZM without ffmpeg. default: OFF ZM_NO_FFMPEG Set to ON to skip ffmpeg checks and force building ZM without ffmpeg. default: OFF
ZM_NO_X10 Set to ON to build ZoneMinder without X10 support. default: OFF ZM_NO_X10 Set to ON to build ZoneMinder without X10 support. default: OFF
ZM_PERL_SUBPREFIX Use a different directory for the zm perl modules. NOTE: This is a subprefix, e.g. lib will be turned into <prefix>/lib, default: <libarch>/perl5 ZM_PERL_MM_PARMS By default, ZoneMinder's Perl modules are installed into the Vendor folders, as defined by your installation of Perl. You can change that here. Consult Perl's MakeMaker documentation for a definition of acceptable parameters. If you set this to something that causes the modules to be installed outside Perl's normal serach path, then you will also need to set ZM_PERL_SEARCH_PATH accordingly. default: "INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1"
ZM_PERL_USE_PATH Override the include path for zm perl modules. Useful if you are moving the perl modules without using the ZM_PERL_SUBPREFIX option. default: <prefix>/<zmperlsubprefix> ZM_PERL_SEARCH_PATH Use to add a folder to your Perl's search path. This will need to be set in cases where ZM_PERL_MM_PARMS has been modified such that ZoneMinder's Perl modules are installed outside Perl's default search path. default: ""
Useful configuration options provided by cmake: Useful configuration options provided by cmake:
CMAKE_VERBOSE_MAKEFILE - Set this to ON (default OFF) to see what cmake is doing. Very useful for troubleshooting. CMAKE_VERBOSE_MAKEFILE - Set this to ON (default OFF) to see what cmake is doing. Very useful for troubleshooting.
@ -79,6 +82,7 @@ Basic steps for installing ZoneMinder on a fresh system
------------------------------------------------------- -------------------------------------------------------
1) After installing all the required dependencies, in the project directory, run "cmake [extra options] ." 1) After installing all the required dependencies, in the project directory, run "cmake [extra options] ."
This behaves like ./configure. It is also possible to supply configuration options, e.g. cmake -DZM_DB_PASS="mypass" . This behaves like ./configure. It is also possible to supply configuration options, e.g. cmake -DZM_DB_PASS="mypass" .
IMPORTANT: Don't forget the dot "." at the end.
2) Run "make" to compile ZoneMinder 2) Run "make" to compile ZoneMinder
3) Run "make install" (as root, or use sudo) to install ZoneMinder to your system. 3) Run "make install" (as root, or use sudo) to install ZoneMinder to your system.
4) Create a directory for the content and the necessary symlinks by running zmlinkcontent.sh with the directory you want to use. e.g. ./zmlinkcontent.sh /nfs/zm 4) Create a directory for the content and the necessary symlinks by running zmlinkcontent.sh with the directory you want to use. e.g. ./zmlinkcontent.sh /nfs/zm
@ -88,8 +92,21 @@ NOTE: The database server, database name, user and password can be different and
7) Populate the zoneminder database using the script zm_create.sql. This should be found in <prefix>/share/zoneminder/db or in the project/db directory. 7) Populate the zoneminder database using the script zm_create.sql. This should be found in <prefix>/share/zoneminder/db or in the project/db directory.
8) Create an apache virtual host for ZoneMinder. Make sure to use the same paths as ZM_WEBDIR and ZM_CGIDIR in /etc/zm.conf 8) Create an apache virtual host for ZoneMinder. Make sure to use the same paths as ZM_WEBDIR and ZM_CGIDIR in /etc/zm.conf
9) Create other config if desired (e.g. rsyslog, logrotate and such). Some of this can be found in <prefix>/share/zoneminder/misc or project/misc directory 9) Verify date.timezone is set to your timezone. This parameter is often found inside the system php.ini file. Consult your distribution's documentation for the proper way to set this value.
10) Setup an init script for your system. Its also possible to use "zmpkg.pl start" and "zmpkg.pl stop" if you can't find a one. 10) Create other config if desired (e.g. rsyslog, logrotate and such). Some of this can be found in <prefix>/share/zoneminder/misc or project/misc directory
11) Setup an appropriate startup script for your system. Two generic startup scripts have been provided, a legacy Sys V Init script and a Systemd service file.
*Sys V Init Setup*
- Copy the sys v init script /scripts/zm from the build folder to /etc/init.
- Inspect the contents to make sure they apply to your distro.
*SystemD Setup*
- Copy the zoneminder systemd service file /misc/zoneminder.service from the build folder to the systemd service file location.
For Redhat based distros, that folder is /usr/lib/systemd/system.
- Inspect the contents to make sure they apply to your distro.
- Tell systemd to load the new service file: "sudo systemctl daemon-reload".
- Copy /misc/zoneminder-tmpfiles.conf to /etc/tmpfiles.d
- Tell systemd to process this file: "sudo /usr/bin/systemd-tmpfiles --create /etc/tmpfiles.d/zoneminder.conf".
Basic steps for upgrading ZoneMinder Basic steps for upgrading ZoneMinder
------------------------------------ ------------------------------------

View File

@ -1,34 +0,0 @@
AUTOMAKE_OPTIONS = foreign
# And these to the user and group of your webserver
webuser = @WEB_USER@
webgroup = @WEB_GROUP@
sysconf_DATA = \
zm.conf
SUBDIRS = \
src \
web \
scripts \
db \
misc \
onvif
EXTRA_DIST = \
zm.conf.in \
zmconfgen.pl.in
# Yes, you are correct. This is a HACK!
install-data-hook:
( cd $(DESTDIR)$(sysconfdir); chown $(webuser):$(webgroup) $(sysconf_DATA); chmod 600 $(sysconf_DATA) )
( if ! test -e $(DESTDIR)$(ZM_RUNDIR); then mkdir -p $(DESTDIR)$(ZM_RUNDIR); fi; if test "$(DESTDIR)$(ZM_RUNDIR)" != "/var/run"; then chown $(webuser):$(webgroup) $(DESTDIR)$(ZM_RUNDIR); chmod u+w $(DESTDIR)$(ZM_RUNDIR); fi )
( if ! test -e $(DESTDIR)$(ZM_SOCKDIR); then mkdir -p $(DESTDIR)$(ZM_SOCKDIR); fi; if test "$(DESTDIR)$(ZM_SOCKDIR)" != "/var/run"; then chown $(webuser):$(webgroup) $(DESTDIR)$(ZM_SOCKDIR); chmod u+w $(DESTDIR)$(ZM_SOCKDIR); fi )
( if ! test -e $(DESTDIR)$(ZM_TMPDIR); then mkdir -m 700 -p $(DESTDIR)$(ZM_TMPDIR); fi; if test "$(DESTDIR)$(ZM_TMPDIR)" != "/tmp" && test "$(DESTDIR)$(ZM_TMPDIR)" != "/var/tmp"; then chown $(webuser):$(webgroup) $(DESTDIR)$(ZM_TMPDIR); chmod u+w $(DESTDIR)$(ZM_TMPDIR); fi )
uninstall-hook:
@-( cd $(DESTDIR)$(webdir); rm -rf events graphics images sounds temp )
@-( if test "$(DESTDIR)$(ZM_RUNDIR)" != "/var/run"; then rm -rf $(DESTDIR)$(ZM_RUNDIR); fi )
@-( if test "$(DESTDIR)$(ZM_SOCKDIR)" != "/var/run"; then rm -rf $(DESTDIR)$(ZM_SOCKDIR); fi )
@-( if test "$(DESTDIR)$(ZM_TMPDIR)" != "/tmp" && test "$(DESTDIR)$(ZM_TMPDIR)" != "/var/tmp"; then rm -rf $(DESTDIR)$(ZM_TMPDIR); fi )
@-( if test "$(DESTDIR)$(ZM_LOGDIR)" != "/var/log"; then rm -rf $(DESTDIR)$(ZM_LOGDIR); fi )

151
README.md
View File

@ -3,130 +3,56 @@ ZoneMinder
[![Build Status](https://travis-ci.org/ZoneMinder/ZoneMinder.png)](https://travis-ci.org/ZoneMinder/ZoneMinder) [![Bountysource](https://api.bountysource.com/badge/team?team_id=204&style=bounties_received)](https://www.bountysource.com/teams/zoneminder/issues?utm_source=ZoneMinder&utm_medium=shield&utm_campaign=bounties_received) [![Build Status](https://travis-ci.org/ZoneMinder/ZoneMinder.png)](https://travis-ci.org/ZoneMinder/ZoneMinder) [![Bountysource](https://api.bountysource.com/badge/team?team_id=204&style=bounties_received)](https://www.bountysource.com/teams/zoneminder/issues?utm_source=ZoneMinder&utm_medium=shield&utm_campaign=bounties_received)
All documentation for ZoneMinder is now online at http://www.zoneminder.com/wiki/index.php/Documentation All documentation for ZoneMinder is now online at https://zoneminder.readthedocs.org
## Overview ## Overview
ZoneMinder is an integrated set of applications which provide a complete surveillance solution allowing capture, analysis, recording and monitoring of any CCTV or security cameras attached to a Linux based machine. It is designed to run on distributions which support the Video For Linux (V4L) interface and has been tested with video cameras attached to BTTV cards, various USB cameras and also supports most IP network cameras. ZoneMinder is an integrated set of applications which provide a complete surveillance solution allowing capture, analysis, recording and monitoring of any CCTV or security cameras attached to a Linux based machine. It is designed to run on distributions which support the Video For Linux (V4L) interface and has been tested with video cameras attached to BTTV cards, various USB cameras and also supports most IP network cameras.
## Requirements ## Contacting the Development Team
Before creating an issue in our github forum, please read our posting rules:
https://github.com/ZoneMinder/ZoneMinder/wiki/Github-Posting-Rules
If you are installing ZoneMinder from a package, that package should provide all of the needed core components. ## Installation Methods
### Packages ### Building from Source is Discouraged
If you are compiling ZoneMinder from source, the below list contains the packages needed to get ZoneMinder built: Historically, installing ZoneMinder onto your system required building from source code by issuing the traditional configure, make, make install commands. To get ZoneMinder to build, all of its dependencies had to be determined and installed beforehand. Init and logrotate scripts had to be manually copied into place following the build. Optional packages such as jscalendar and Cambozola had to be manually installed. Uninstalls could leave stale files around, which could cause problems during an upgrade. Speaking of upgrades, when it comes time to upgrade all these manual steps must be repeated again.
#### Ubuntu Better methods exist today that do much of this for you. The current development team, along with other volunteers, have taken great strides in providing the resources necessary to avoid building from source.
A fresh build based on master branch running Ubuntu 1204 LTS. Will likely work for other versions as well. ### Install from a Package Repository
This is the recommended method to install ZoneMinder onto your system. ZoneMinder packages are maintained for the following distros:
- Ubuntu via [Iconnor's PPA](https://launchpad.net/~iconnor/+archive/ubuntu/zoneminder)
- Debian from their [default repository](https://packages.debian.org/search?searchon=names&keywords=zoneminder)
- RHEL/CentOS and clones via [zmrepo](http://zmrepo.zoneminder.com/)
- Fedora via [zmrepo](http://zmrepo.zoneminder.com/)
- OpenSuse via [third party repository](http://www.zoneminder.com/wiki/index.php/Installing_using_ZoneMinder_RPMs_for_SuSE)
- Maegia from their default repository
If a repository that hosts ZoneMinder packages is not available for your distro, then you are encouraged to build your own package, rather than build from source. While each distro is different in ways that set it apart from all the others, they are often similar enough to allow you to adapt another distro's package building instructions to your own.
### Building a ZoneMinder Package
Building ZoneMinder into a package is not any harder than building from source. As a matter of fact, if you have successfully built ZoneMinder from source in the past, then you may find these steps to be easier.
When building a package, it is best to do this work in a separate environment, dedicated to development purposes. This could be as simple as creating a virtual machine, using Docker, or using mock. All it takes is one “Oops” to regret doing this work on your production server.
Lastly, if you desire to build a development snapshot from the master branch, it is recommended you first build your package using an official release of ZoneMinder. This will help identify whether any problems you may encounter are caused by the build process or is a new issue in the master branch.
Please visit our [ReadtheDocs site](https://zoneminder.readthedocs.org/en/stable/installationguide/index.html) for distro specific instructions.
### Package Maintainers
Many of the ZoneMinder configration variable default values are not configurable at build time through autotools or cmake. A new tool called *zmeditconfigdata.sh* has been added to allow package maintainers to manipulate any variable stored in ConfigData.pm without patching the source.
For example, let's say I have created a new ZoneMinder package that contains the cambolzola javascript file. However, by default cambozola support is turned off. To fix that, add this to the pacakging script:
```bash ```bash
root@host:~# aptitude install -y apache2 mysql-server php5 php5-mysql build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libpcre3 libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf libjpeg8-dev libjpeg8 apache2-mpm-prefork libapache2-mod-php5 php5-cli libphp-serialization-perl libgnutls-dev libjpeg8-dev libavcodec-dev libavformat-dev libswscale-dev libavutil-dev libv4l-dev libtool ffmpeg libnetpbm10-dev libavdevice-dev libmime-lite-perl dh-autoreconf dpatch; ./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
root@host:~# git clone https://github.com/ZoneMinder/ZoneMinder.git zoneminder;
root@host:~# cd zoneminder;
root@host:~# ln -s distros/ubuntu1204 debian;
root@host:~# dpkg-checkbuilddeps;
root@host:~# dpkg-buildpackage;
``` ```
One level above you'll now find a deb package matching the architecture of the build host: Note that zmeditconfigdata.sh is intended to be called, from the root build folder, prior to running cmake or configure.
```bash
root@host:~# ls -1 ~/zoneminder*;
/root/zoneminder_1.26.4-1_amd64.changes
/root/zoneminder_1.26.4-1_amd64.deb
/root/zoneminder_1.26.4-1.dsc
/root/zoneminder_1.26.4-1.tar.gz
```
The dpkg command itself does not resolve dependencies. That's what high-level interfaces like aptitude and apt-get are normally for. Unfortunately, unlike RPM, there's no easy way to install a separate deb package not contained with any repository.
To overcome this "limitation" we'll use dpkg only to install the zoneminder package and apt-get to fetch all needed dependencies afterwards. Running dpkg-reconfigure in the end will ensure that the setup scripts e.g. for database provisioning were executed.
```bash
root@host:~# dpkg -i /root/zoneminder_1.26.4-1_amd64.deb; apt-get install -f;
root@host:~# dpkg-reconfigure zoneminder;
```
Alternatively you may also use gdebi to automatically resolve dependencies during installation:
```bash
root@host:~# aptitude install -y gdebi;
root@host:~# gdebi /root/zoneminder_1.26.4-1_amd64.deb;
```
```bash
sudo apt-get install apache2 mysql-server php5 php5-mysql build-essential libmysqlclient-dev libssl-dev libbz2-dev \
libpcre3-dev libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libpcre3 \
libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf libjpeg-turbo8-dev libjpeg-turbo8 \
apache2-mpm-prefork libapache2-mod-php5 php5-cli
```
#### Debian
A fresh build based on master branch running Debian 7 (wheezy):
```bash
root@host:~# aptitude install -y apache2 mysql-server php5 php5-mysql build-essential libmysqlclient-dev libssl-dev libbz2-dev libpcre3-dev libdbi-perl libarchive-zip-perl libdate-manip-perl libdevice-serialport-perl libmime-perl libpcre3 libwww-perl libdbd-mysql-perl libsys-mmap-perl yasm automake autoconf libjpeg8-dev libjpeg8 apache2-mpm-prefork libapache2-mod-php5 php5-cli libphp-serialization-perl libgnutls-dev libjpeg8-dev libavcodec-dev libavformat-dev libswscale-dev libavutil-dev libv4l-dev libtool ffmpeg libnetpbm10-dev libavdevice-dev libmime-lite-perl dh-autoreconf dpatch;
root@host:~# git clone https://github.com/ZoneMinder/ZoneMinder.git zoneminder;
root@host:~# cd zoneminder;
root@host:~# ln -s distros/debian;
root@host:~# dpkg-checkbuilddeps;
root@host:~# dpkg-buildpackage;
```
One level above you'll now find a deb package matching the architecture of the build host:
```bash
root@host:~# ls -1 ~/zoneminder*;
/root/zoneminder_1.26.4-1_amd64.changes
/root/zoneminder_1.26.4-1_amd64.deb
/root/zoneminder_1.26.4-1.dsc
/root/zoneminder_1.26.4-1.tar.gz
```
The dpkg command itself does not resolve dependencies. That's what high-level interfaces like aptitude and apt-get are normally for. Unfortunately, unlike RPM, there's no easy way to install a separate deb package not contained with any repository.
To overcome this "limitation" we'll use dpkg only to install the zoneminder package and apt-get to fetch all needed dependencies afterwards. Running dpkg-reconfigure in the end will ensure that the setup scripts e.g. for database provisioning were executed.
```bash
root@host:~# dpkg -i /root/zoneminder_1.26.4-1_amd64.deb; apt-get install -f;
root@host:~# dpkg-reconfigure zoneminder;
```
Alternatively you may also use gdebi to automatically resolve dependencies during installation:
```bash
root@host:~# aptitude install -y gdebi;
root@host:~# gdebi /root/zoneminder_1.26.4-1_amd64.deb;
```
#### CentOS / RHEL
Additional repositories must be added before one can build zoneminder on CentOS or RHEL:
1. RepoForge (formerly RPMForge) http://repoforge.org/use/
2. EPEL https://fedoraproject.org/wiki/EPEL
3. Optional RPMFusion: http://rpmfusion.org/ [SEE NOTE]
[NOTE]<br>
The RPMFusion repo contains significantly newer versions of ffmpeg and vlc. This leads to significantly better camera support. However, the RPMFusion repo contains packages that conflict with the other two repos. In order to resolve this, one must also install the yum priorities pacakge and use that to prioritize your repos in the following order:
1. Base
2. RPMFusion
3. EPEL
4. RPMForge
For instructions on yum priorities, visit this page:
http://wiki.centos.org/PackageManagement/Yum/Priorities
Once your repos are in order, install the following:
```bash
sudo yum install automake bzip2-devel ffmpeg ffmpeg-devel gnutls-devel httpd libjpeg-turbo libjpeg-turbo-devel mysql-devel mysql-server pcre-devel \
perl-Archive-Tar perl-Archive-Zip perl-Convert-BinHex perl-Date-Manip perl-DBD-MySQL perl-DBI perl-Device-SerialPort perl-Email-Date-Format perl-IO-stringy \
perl-IO-Zlib perl-MailTools perl-MIME-Lite perl-MIME-tools perl-MIME-Types perl-Module-Load perl-Package-Constants perl-Sys-Mmap perl-Time-HiRes \
perl-TimeDate perl-YAML-Syck php php-cli php-mysql x264 vlc-devel vlc-core libcurl libcurl-devel
```
#### Docker #### Docker
@ -134,11 +60,6 @@ Docker is a system to run applications inside isolated containers. ZoneMinder, a
Dockerfile contained in this repository. However, there is still work needed to ensure that the main ZM features work Dockerfile contained in this repository. However, there is still work needed to ensure that the main ZM features work
properly and are documented. properly and are documented.
### ffmpeg
This release of ZoneMinder has been tested on and works with ffmpeg version N-55540-g93f4277.
## Contribution Model and Development ## Contribution Model and Development
* Source hosted at [GitHub](https://github.com/ZoneMinder/ZoneMinder/) * Source hosted at [GitHub](https://github.com/ZoneMinder/ZoneMinder/)

View File

@ -1,74 +0,0 @@
AC_DEFUN([AC_DEFINE_DIR], [
prefix_NONE=
exec_prefix_NONE=
test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
dnl In Autoconf 2.60, ${datadir} refers to ${datarootdir}, which in turn
dnl refers to ${prefix}. Thus we have to use `eval' twice.
eval ac_define_dir="\"[$]$2\""
eval ac_define_dir="\"$ac_define_dir\""
AC_SUBST($1, "$ac_define_dir")
AC_DEFINE_UNQUOTED($1, "$ac_define_dir", [$3])
test "$prefix_NONE" && prefix=NONE
test "$exec_prefix_NONE" && exec_prefix=NONE
])
AC_DEFUN([AC_PROG_PERL_VERSION],[dnl
# Make sure we have perl
if test -z "$PERL"; then
AC_CHECK_PROG(PERL,perl,perl)
fi
# Check if version of Perl is sufficient
ac_perl_version="$1"
if test "x$PERL" != "x"; then
AC_MSG_CHECKING(for perl version greater than or equal to $ac_perl_version)
# NB: It would be nice to log the error if there is one, but we cannot rely
# on autoconf internals
$PERL -e "use $ac_perl_version;" > /dev/null 2>&1
if test $? -ne 0; then
AC_MSG_RESULT(no);
$3
else
AC_MSG_RESULT(ok);
$2
fi
else
AC_MSG_WARN(could not find perl)
fi
])dnl
AC_DEFUN([AC_PROG_PERL_MODULES],[dnl
ac_perl_modules="$1"
# Make sure we have perl
if test -z "$PERL"; then
AC_CHECK_PROG(PERL,perl,perl)
fi
if test "x$PERL" != x; then
ac_perl_modules_failed=0
for ac_perl_module in $ac_perl_modules; do
AC_MSG_CHECKING(for perl module $ac_perl_module)
# Would be nice to log result here, but can't rely on autoconf internals
$PERL "-M$ac_perl_module" -e exit > /dev/null 2>&1
if test $? -ne 0; then
AC_MSG_RESULT(no);
ac_perl_modules_failed=1
else
AC_MSG_RESULT(ok);
fi
done
# Run optional shell commands
if test "$ac_perl_modules_failed" = 0; then
:
$2
else
:
$3
fi
else
AC_MSG_WARN(could not find perl)
fi])dnl

View File

@ -1,5 +0,0 @@
#!/bin/bash
aclocal
autoheader
automake --add-missing
autoconf

View File

@ -0,0 +1,58 @@
# Check whether sendfile() is supported and what prototype it has
include(CheckCSourceCompiles)
if (UNIX OR MINGW)
SET(CMAKE_REQUIRED_DEFINITIONS -Werror-implicit-function-declaration)
endif()
check_c_source_compiles("#include <sys/sendfile.h>
#include <stdio.h>
int main()
{
sendfile(1, 1, NULL, 0);
return 0;
}" HAVE_SENDFILE4_SUPPORT)
if(HAVE_SENDFILE4_SUPPORT)
add_definitions(-DHAVE_SENDFILE4_SUPPORT=1)
unset(CMAKE_REQUIRED_DEFINITIONS)
message(STATUS "Sendfile support: Linux/Solaris sendfile()")
return()
endif()
find_library(SENDFILE_LIBRARIES NAMES sendfile)
if(SENDFILE_LIBRARIES)
include(CheckLibraryExists)
check_library_exists(sendfile sendfile ${SENDFILE_LIBRARIES} HAVE_SENDFILE4_SUPPORT)
if(HAVE_SENDFILE4_SUPPORT)
add_definitions(-DHAVE_SENDFILE4_SUPPORT=1)
unset(CMAKE_REQUIRED_DEFINITIONS)
message(STATUS "Sendfile support: Solaris sendfile()")
return()
endif()
endif()
set(SENDFILE_LIBRARIES "")
check_c_source_compiles("#include <sys/socket.h>
#include <stdio.h>
int main()
{
sendfile(1, 1, 0, 0, NULL, NULL, 0);
return 0;
}" HAVE_SENDFILE7_SUPPORT)
if(HAVE_SENDFILE7_SUPPORT)
add_definitions(-DHAVE_SENDFILE7_SUPPORT=1)
unset(CMAKE_REQUIRED_DEFINITIONS)
message(STATUS "Sendfile support: FreeBSD sendfile()")
return()
endif()
check_c_source_compiles("#include <sys/socket.h>
#include <stdio.h>
#include <sys/uio.h>
int main()
{
sendfile(1, 1, 0, NULL, NULL, 0);
return 0;
}" HAVE_SENDFILE6_SUPPORT)
if(HAVE_SENDFILE6_SUPPORT)
add_definitions(-DHAVE_SENDFILE6_SUPPORT=1)
unset(CMAKE_REQUIRED_DEFINITIONS)
message(STATUS "Sendfile support: MacOS sendfile()")
return()
endif()

View File

@ -19,7 +19,7 @@
# use pkg-config to get the directories and then use these values # use pkg-config to get the directories and then use these values
# in the FIND_PATH() and FIND_LIBRARY() calls # in the FIND_PATH() and FIND_LIBRARY() calls
find_package(PkgConfig) find_package(PkgConfig)
pkg_check_modules(PC_POLKIT polkit-gobject-1) pkg_search_module(PC_POLKIT polkit-gobject-1 polkit)
#pkg_check_modules(PC_POLKIT_AGENT polkit-agent-1) #pkg_check_modules(PC_POLKIT_AGENT polkit-agent-1)
set(POLKIT_DEFINITIONS ${PC_POLKIT_CFLAGS_OTHER}) set(POLKIT_DEFINITIONS ${PC_POLKIT_CFLAGS_OTHER})
endif (NOT WIN32) endif (NOT WIN32)
@ -31,8 +31,8 @@
HINTS ${PC_POLKIT_INCLUDE_DIRS} HINTS ${PC_POLKIT_INCLUDE_DIRS}
) )
find_path( POLKIT_INCLUDE_DIR find_path( POLKIT_INCLUDE_DIR
NAMES polkit/polkit.h NAMES polkit/polkit.h libpolkit/libpolkit.h
PATH_SUFFIXES polkit-1 PATH_SUFFIXES polkit-1 polkit
HINTS ${PC_POLKIT_INCLUDE_DIRS} HINTS ${PC_POLKIT_INCLUDE_DIRS}
) )
#find_path( POLKIT_AGENT_INCLUDE_DIR #find_path( POLKIT_AGENT_INCLUDE_DIR
@ -43,7 +43,7 @@
#set(POLKIT_INCLUDE_DIRS ${GLIB2_INCLUDE_DIR} ${_POLKIT_INCLUDE_DIR}) #set(POLKIT_INCLUDE_DIRS ${GLIB2_INCLUDE_DIR} ${_POLKIT_INCLUDE_DIR})
#set(POLKIT_AGENT_INCLUDE_DIRS ${GLIB2_INCLUDE_DIR} ${_POLKIT_AGENT_INCLUDE_DIR}) #set(POLKIT_AGENT_INCLUDE_DIRS ${GLIB2_INCLUDE_DIR} ${_POLKIT_AGENT_INCLUDE_DIR})
find_library( POLKIT_LIBRARIES find_library( POLKIT_LIBRARIES
NAMES polkit-gobject-1 NAMES polkit-gobject-1 polkit
HINTS ${PC_POLKIT_LIBDIR} HINTS ${PC_POLKIT_LIBDIR}
) )
#find_library( POLKIT_AGENT_LIBRARY #find_library( POLKIT_AGENT_LIBRARY

View File

@ -0,0 +1,71 @@
#
# Copyright (C) 2012 Emmanuel Roullit <emmanuel.roullit@gmail.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or (at
# your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
#
# Generate man pages of the project by using the
# POD header written in the tool source code.
# To use it, include this file in CMakeLists.txt and
# invoke POD2MAN(<podfile> <manfile> <section>)
MACRO(POD2MAN PODFILE MANFILE SECTION)
FIND_PROGRAM(POD2MAN pod2man)
FIND_PROGRAM(GZIP gzip)
IF(NOT POD2MAN)
MESSAGE(FATAL ERROR "Need pod2man installed to generate man page")
ENDIF(NOT POD2MAN)
IF(NOT GZIP)
MESSAGE(FATAL ERROR "Need gzip installed to compress man page")
ENDIF(NOT GZIP)
IF(NOT EXISTS ${PODFILE})
MESSAGE(FATAL ERROR "Could not find pod file ${PODFILE} to generate man page")
ENDIF(NOT EXISTS ${PODFILE})
ADD_CUSTOM_COMMAND(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}
DEPENDS ${PODFILE}
COMMAND ${POD2MAN}
ARGS --section ${SECTION} --center ${CMAKE_PROJECT_NAME} --release --stderr --name ${MANFILE}
${PODFILE} > ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}
)
ADD_CUSTOM_COMMAND(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}.gz
COMMAND ${GZIP} --best -c ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION} > ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}.gz
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}
)
SET(MANPAGE_TARGET "man-${MANFILE}")
ADD_CUSTOM_TARGET(${MANPAGE_TARGET} DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}.gz)
ADD_DEPENDENCIES(man ${MANPAGE_TARGET})
INSTALL(
FILES ${CMAKE_CURRENT_BINARY_DIR}/${MANFILE}.${SECTION}.gz
DESTINATION share/man/man${SECTION}
)
ENDMACRO(POD2MAN PODFILE MANFILE SECTION)
MACRO(ADD_MANPAGE_TARGET)
# It is not possible add a dependency to target 'install'
# Run hard-coded 'make man' when 'make install' is invoked
INSTALL(CODE "EXECUTE_PROCESS(COMMAND make man)")
ADD_CUSTOM_TARGET(man)
ENDMACRO(ADD_MANPAGE_TARGET)

View File

@ -1,457 +0,0 @@
AC_PREREQ(2.59)
AC_INIT(zm,1.28.0,[http://www.zoneminder.com/forums/ - Please check FAQ first],zoneminder,http://www.zoneminder.com/downloads.html)
AM_INIT_AUTOMAKE
AC_CONFIG_SRCDIR(src/zm.h)
AC_CONFIG_HEADERS(config.h)
AC_SUBST([AM_CXXFLAGS], [-D__STDC_CONSTANT_MACROS])
AC_SUBST(VERSION)
#
# Platform specific setup
#
#############################
AC_CANONICAL_HOST
# Check for which host we are on and setup a few things
# specifically based on the host
case $host_os in
darwin* )
# Do something specific for mac
HOST_OS='darwin'
;;
linux*)
# Do something specific for linux
HOST_OS='linux'
;;
*BSD*)
# Do something specific for BSD
HOST_OS='BSD'
;;
*)
#Default Case
AC_MSG_ERROR([Your platform is not currently supported])
;;
esac
AC_SUBST(HOST_OS)
AC_ARG_VAR(ZM_DB_TYPE,[Type of the ZoneMinder database, default mysql])
AC_ARG_VAR(ZM_DB_HOST,[Hostname where ZoneMinder database located, default localhost])
AC_ARG_VAR(ZM_DB_NAME,[Name of ZoneMinder database, default zm])
AC_ARG_VAR(ZM_DB_USER,[Name of ZoneMinder database user, default zmuser])
AC_ARG_VAR(ZM_DB_PASS,[Password of ZoneMinder database user, default zmpass])
AC_ARG_VAR(ZM_SSL_LIB,[Library to use for ssl functions, default gnutls])
AC_ARG_VAR(ZM_MYSQL_ENGINE,[MySQL engine to use with database, default InnoDB])
AC_ARG_VAR(ZM_RUNDIR,[Location of transient process files, default /var/run/zm])
AC_ARG_VAR(ZM_SOCKDIR,[Location of Unix domain socket files, default /var/run/zm])
AC_ARG_VAR(ZM_TMPDIR,[Location of temporary files, default /var/tmp/zm])
AC_ARG_VAR(ZM_LOGDIR,[Location of generated log files, default /var/log/zm])
if test "$ZM_DB_TYPE" == ""; then
AC_SUBST(ZM_DB_TYPE,[mysql])
fi
if test "$ZM_DB_HOST" == ""; then
AC_SUBST(ZM_DB_HOST,[localhost])
fi
if test "$ZM_DB_NAME" == ""; then
AC_SUBST(ZM_DB_NAME,[zm])
fi
if test "$ZM_DB_USER" == ""; then
AC_SUBST(ZM_DB_USER,[zmuser])
fi
if test "$ZM_DB_PASS" == ""; then
AC_SUBST(ZM_DB_PASS,[zmpass])
fi
if test "$ZM_SSL_LIB" == ""; then
AC_SUBST(ZM_SSL_LIB,gnutls)
fi
if test "$ZM_MYSQL_ENGINE" == ""; then
AC_SUBST(ZM_MYSQL_ENGINE,InnoDB)
fi
if test "$ZM_RUNDIR" == ""; then
AC_SUBST(ZM_RUNDIR,[/var/run/zm])
fi
if test "$ZM_SOCKDIR" == ""; then
AC_SUBST(ZM_SOCKDIR,[/var/run/zm])
fi
if test "$ZM_TMPDIR" == ""; then
AC_SUBST(ZM_TMPDIR,[/tmp/zm])
fi
if test "$ZM_LOGDIR" == ""; then
AC_SUBST(ZM_LOGDIR,[/var/log/zm])
fi
LIB_ARCH=lib
AC_ARG_WITH(libarch,
[ --with-libarch=<lib> architecture library path to use, default lib],
[LIB_ARCH=$with_libarch],
AC_MSG_WARN([You can call configure with the --with-libarch option.
This tells configure where to find architecture specific libraries.
The default of 'lib' is usually ok but 64 bit machines may require lib64.
e.g. --with-libarch=lib or --with-libarch=lib64])
)
AC_SUBST(LIB_ARCH)
LDFLAGS="-L/usr/lib/${build_alias} ${LDFLAGS}"
MYSQL_PREFIX=/usr
AC_ARG_WITH(mysql,
[ --with-mysql=<path> prefix of MySQL installation, default /usr],
[MYSQL_PREFIX=$with_mysql],
AC_MSG_WARN([You can call configure with the --with-mysql option.
This tells configure where to find the MySql C library and headers if configure cannot
locate them automatically.
e.g. --with-mysql=/usr/local or --with-mysql=/usr])
)
AC_SUBST(MYSQL_PREFIX)
MYSQL_LIBS="-L${MYSQL_PREFIX}/${LIB_ARCH}/mysql"
MYSQL_CFLAGS="-I${MYSQL_PREFIX}/include"
AC_SUBST(MYSQL_LIBS)
AC_SUBST(MYSQL_CFLAGS)
LDFLAGS="$LDFLAGS ${MYSQL_LIBS}"
MARIADB_PREFIX=/usr
AC_ARG_WITH(mariadb,
[ --with-mariadb=<path> prefix of MariaDB installation, default /usr],
[MYSQL_PREFIX=$with_mariadb],
AC_MSG_WARN([You can call configure with the --with-mariadb option.
This tells configure where to find the mariaDB C library and headers if configure cannot
locate them automatically.
e.g. --with-mariadb=/usr/local or --with-mariadb=/usr])
)
AC_SUBST(MARIADB_PREFIX)
MARIADB_LIBS="-L${MARIADB_PREFIX}/${LIB_ARCH}/mariadb"
MARIADB_CFLAGS="-I${MARIADB_PREFIX}/include"
AC_SUBST(MARIADB_LIBS)
AC_SUBST(MARIADB_CFLAGS)
LDFLAGS="$LDFLAGS ${MARIADB_LIBS}"
POLKIT_PREFIX=/usr
AC_ARG_WITH(polkit,
[ --with-polkit=<path> prefix of polkit root directory, default /usr],
[POLKIT_PREFIX=$with_polkit],
AC_MSG_WARN([You can call configure with the --with-polkit option.
This tells configure where to place the polkit policy files.])
)
AC_SUBST(POLKIT_PREFIX)
PKG_CHECK_MODULES(POLKIT, polkit-gobject-1)
FFMPEG_PREFIX=/usr
AC_ARG_WITH(ffmpeg,
[ --with-ffmpeg=<path> prefix of ffmpeg root directory for libavcodec etc, default /usr],
[FFMPEG_PREFIX=$with_ffmpeg],
AC_MSG_WARN([You can call configure with the --with-ffmpeg option.
This tells configure where to find the ffmpeg root directory within which are the libavcodec
and libavformat files that can be used to build true MPEG streaming into ZoneMinder. Ensure that
your copy of ffmpeg has installed libraries as well as binaries (use 'make installlib'). If you
are using a local install of ffmpeg you may have to remove or rename a previous real installation
as the headers and libraries from that will probably be picked up before your local copy.
e.g. --with-ffmpeg=/usr/local])
)
AC_SUBST(FFMPEG_PREFIX)
FFMPEG_LIBS="-L${FFMPEG_PREFIX}/${LIB_ARCH}"
FFMPEG_CFLAGS="-I${FFMPEG_PREFIX}/include -D__STDC_CONSTANT_MACROS"
AC_SUBST(FFMPEG_LIBS)
AC_SUBST(FFMPEG_CFLAGS)
LDFLAGS="${FFMPEG_LIBS} $LDFLAGS"
CFLAGS="${FFMPEG_CFLAGS} $CFLAGS"
CPPFLAGS="${FFMPEG_CFLAGS} $CPPFLAGS"
EXTRA_LIBS=
AC_ARG_WITH(extralibs,
[ --with-extralibs="<libs>" string containing extra libraries to pass to link, default empty],
[EXTRA_LIBS=$with_extralibs],
AC_MSG_WARN([You can call configure with the --with-extralibs option.
Ordinarily you will need to use this option only when your copy of ffmpeg has been built
with support for additional formats and you would use this option to detail which additional
libraries ffmpeg was built with so that it is able to link successfully with ZoneMinder.
You will need to wrap this option in quotes if it contains any spaces.
e.g. --with-extralibs="-lmp3lame"])
)
AC_SUBST(EXTRA_LIBS)
LDFLAGS="$LDFLAGS ${EXTRA_LIBS}"
AC_ARG_WITH(webdir,
[ --with-webdir=<path> prefix of web directory],
[WEB_PREFIX=$with_webdir],
AC_MSG_ERROR([You must call configure with the --with-webdir option.
This tells configure where to install PHP and web files and scripts.
e.g. --with-webdir=/var/www/html or --with-webdir=/www/vhtdocs/<site>])
)
AC_SUBST(WEB_PREFIX)
AC_ARG_WITH(cgidir,
[ --with-cgidir=<path> prefix of cgi directory],
[CGI_PREFIX=$with_cgidir],
AC_MSG_ERROR([You must call configure with the --with-cgidir option.
This tells configure where to install cgi files and scripts.
e.g. --with-cgidir=/var/www/cgi-bin or --with-webdir=/www/vhtdocs/<site>/cgi-bin])
)
AC_SUBST(CGI_PREFIX)
WEB_USER=apache
AC_ARG_WITH(webuser,
[ --with-webuser=<user> name of web user, default apache],
[WEB_USER=$with_webuser],
AC_MSG_WARN([You can call configure with the --with-webuser option.
This tells configure what the user name of the web user is if it is not the default of 'apache'.
e.g. --with-webuser=apache or --with-webuser=web])
)
AC_SUBST(WEB_USER)
WEB_GROUP=apache
AC_ARG_WITH(webgroup,
[ --with-webgroup=<group> name of web group, default apache],
[WEB_GROUP=$with_webgroup],
AC_MSG_WARN([You can call configure with the --with-webgroup option.
This tells configure what the group name of the web group is if it is not the default of 'apache'.
e.g. --with-webgroup=apache or --with-webgroup=web])
)
AC_SUBST(WEB_GROUP)
WEB_HOST=zm.local
AC_ARG_WITH(webhost,
[ --with-webhost=<hostname> name of web hostname, default zm.local],
[WEB_HOST=$with_webhost],
AC_MSG_WARN([You can call configure with the --with-webhost option.
This tells configure what the host name is for name based virtual hosting. This is only used to populate the sample web/zmHttpd.conf file.
e.g. --with-webhost=zm.localdomain])
)
AC_SUBST(WEB_HOST)
ENABLE_DEBUG=yes
AC_ARG_ENABLE(debug,
[ --enable-debug=<yes|no> enable or disable debug, default enabled],
[ENABLE_DEBUG=$enable_debug],
AC_MSG_WARN([You can call configure with the --enable-debug=<yes|no> or --disable-debug option.
This tells configure whether to compile ZoneMinder with debug included. Although debug is included
by default it is not output unless explicitly switched on elsewhere. These checks may induce a
small penalty on performance and if you are after squeezing the maximum possible performance out
of ZoneMinder you may use this switch to prevent debug from being compiled in.
e.g. --enable-debug=yes or --disable-debug])
)
if test "$ENABLE_DEBUG" != "yes"; then
AC_DEFINE(ZM_DBG_OFF,1,"Whether debug is switched off and compiled out")
fi
ENABLE_MMAP=yes
AC_ARG_ENABLE(mmap,
[ --enable-mmap=<yes|no> enable or disabled mapped memory versus shared memory, default mapped],
[ENABLE_MMAP=$enable_mmap],
AC_MSG_WARN([You can call configure with the --enable-mmap=<yes|no> or --disable-mmap option.
This tells configure whether to compile ZoneMinder with mmap support rather than IPC shared
memory. This is a feature that uses memory mapped into files which all processes can share.
Memory mapping requires less configuration and is more flexible than shared memory but may
slow down your system unless the mapped files are configured to reside on a fast or RAM based
filesystem which will normally be the case by default.
e.g. --enable-mmap=yes or --disable-mmap])
)
if test "$ENABLE_MMAP" == "yes"; then
AC_DEFINE(ZM_MEM_MAPPED,1,"Whether to use mapped rather than shared memory")
else
AC_DEFINE(ZM_MEM_MAPPED,0,"Whether to use mapped rather than shared memory")
fi
AC_SUBST(ENABLE_MMAP)
# Compiler
AC_LANG_CPLUSPLUS
# Checks for programs.
AC_PROG_CXX
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_RANLIB
AC_PROG_MAKE_SET
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_C_CONST
AC_TYPE_UID_T
AC_C_INLINE
AC_TYPE_MODE_T
AC_TYPE_SIZE_T
AC_HEADER_TIME
AC_STRUCT_TM
AC_TYPE_SIGNAL
AC_CHECK_TYPES(siginfo_t,,,[#include <signal.h>])
AC_CHECK_TYPES(ucontext_t,,,[#include <signal.h>])
# Checks for library functions.
AC_PROG_GCC_TRADITIONAL
AC_FUNC_MALLOC
AC_FUNC_MMAP
AC_FUNC_SELECT_ARGTYPES
AC_FUNC_STAT
AC_FUNC_STRFTIME
AC_FUNC_STRTOD
AC_FUNC_VPRINTF
AC_CHECK_FUNCS([gethostbyname gethostname gettimeofday memmove memset mkdir munmap posix_memalign putenv select sendfile socket sqrt strcasecmp strchr strcspn strerror strncasecmp strrchr strspn strstr strtol strtoull])
AC_CHECK_FUNCS([syscall sleep usleep ioctl ioctlsocket sigaction])
# Other programs
AC_CHECK_PROG(OPT_FFMPEG,ffmpeg,yes,no)
AC_PATH_PROG(PATH_FFMPEG,ffmpeg)
AC_CHECK_PROG(OPT_NETPBM,pnmscale,yes,no)
AC_PATH_PROG(PATH_NETPBM,pnmscale)
if test "$OPT_NETPBM" == "yes"; then
PATH_NETPBM=`dirname $PATH_NETPBM`
fi
# Checks for libraries.
AC_SEARCH_LIBS(mysql_init,[mysqlclient mariadbclient],,AC_MSG_ERROR(zm requires libmysqlclient.a or libmariadbclient.a))
AC_CHECK_LIB(jpeg,jpeg_start_compress,,AC_MSG_ERROR(zm requires libjpeg.a))
AC_CHECK_LIB(pthread,pthread_create,,AC_MSG_ERROR(zm requires libpthread.a))
AC_CHECK_LIB(dl,dlsym,,AC_MSG_ERROR(zm requires libdl.a))
if test "$ZM_SSL_LIB" == "openssl"; then
AC_CHECK_HEADERS(openssl/md5.h,,AC_MSG_WARN(zm requires openssl/md5.h header to be installed for openssl),)
AC_CHECK_LIB(crypto,MD5,,AC_MSG_WARN([libcrypto.a is required for authenticated streaming - use ZM_SSL_LIB option to select gnutls instead]))
else
AC_CHECK_HEADERS(gnutls/openssl.h,AC_SUBST(ZM_HAS_GNUTLS_OPENSSL,1),AC_SUBST(ZM_HAS_GNUTLS_OPENSSL,0),)
AC_CHECK_HEADERS(gnutls/gnutls.h,AC_SUBST(ZM_HAS_GNUTLS,1),AC_SUBST(ZM_HAS_GNUTLS,0),)
if test "$ZM_HAS_GNUTLS_OPENSSL" == "0" && test "$ZM_HAS_GNUTLS" == "0"; then
AC_MSG_WARN(gnutls is required for authenticated streaming - use ZM_SSL_LIB option to select openssl instead)
fi
AC_CHECK_HEADERS(gcrypt.h,,AC_MSG_WARN(zm requires libgcrypt headers to be installed for gnutls),)
AC_CHECK_LIB(gcrypt,gcry_check_version,,AC_MSG_WARN([libgcrypt.a is required for authenticated streaming - use ZM_SSL_LIB option to select openssl instead]))
AC_CHECK_LIB(gnutls,gnutls_fingerprint,,AC_MSG_WARN([libgnutls.a is required for authenticated streaming - use ZM_SSL_LIB option to select openssl instead]))
if test "$ZM_HAS_GNUTLS_OPENSSL" == "1"; then
AC_CHECK_LIB(gnutls-openssl,MD5,,AC_MSG_WARN([libgnutls.a is required for authenticated streaming - use ZM_SSL_LIB option to select openssl instead]))
fi
fi
AC_CHECK_LIB(pcre,pcre_compile,,AC_MSG_WARN(libpcre.a may be required for remote/network camera support))
AC_CHECK_LIB(z,zlibVersion)
AC_CHECK_LIB(x264,x264_predict_16x16_init)
AC_CHECK_LIB(avutil,av_malloc,,AC_MSG_WARN(libavutil.a may be required for MPEG streaming))
# Don't bother to warn about this one
AC_CHECK_LIB(avcore,av_image_copy,,)
AC_CHECK_LIB(avcodec,avcodec_version,,AC_MSG_WARN(libavcodec.a is required for MPEG streaming))
AC_CHECK_LIB(avformat,avformat_version,,AC_MSG_WARN(libavformat.a is required for MPEG streaming))
#AC_CHECK_LIB(avcodec,avcodec_open,,AC_MSG_WARN(libavcodec.a is required for MPEG streaming))
#AC_CHECK_LIB(avformat,av_new_stream,,AC_MSG_WARN(libavformat.a is required for MPEG streaming))
AC_CHECK_LIB(avdevice,avdevice_register_all,,AC_MSG_WARN(libavdevice.a may be required for MPEG streaming))
AC_CHECK_LIB(swscale,sws_scale,,,-lswscale)
AC_CHECK_LIB(vlc,libvlc_new,,AC_MSG_WARN(libvlc.a may be required for streaming))
AC_CHECK_LIB(bz2,BZ2_bzCompress,,AC_MSG_WARN(zm requires libbz2.a for recent versions of ffmpeg))
AC_CHECK_LIB(z,compress,,)
AC_CHECK_LIB(curl,curl_global_init,,)
# Checks for header files.
AC_FUNC_ALLOCA
AC_HEADER_STDC
AC_CHECK_HEADERS([fcntl.h limits.h memory.h stddef.h stdlib.h string.h strings.h sys/param.h sys/time.h syslog.h unistd.h values.h])
AC_CHECK_HEADERS([netdb.h netinet/in.h arpa/inet.h sys/ioctl.h sys/socket.h sys/un.h glob.h sys/sendfile.h])
AC_CHECK_HEADERS(execinfo.h,,,)
AC_CHECK_HEADERS(ucontext.h,,,)
AC_CHECK_HEADERS(sys/syscall.h,,,)
AC_CHECK_HEADERS(pthread.h,,,)
AC_CHECK_HEADERS(linux/videodev.h,AC_SUBST(ZM_HAS_V4L1,1),AC_SUBST(ZM_HAS_V4L1,0),)
AC_CHECK_HEADERS(linux/videodev2.h,AC_SUBST(ZM_HAS_V4L2,1),AC_SUBST(ZM_HAS_V4L2,0),)
if test "$ZM_HAS_V4L1" == "1" || test "$ZM_HAS_V4L2" == "1"; then
AC_SUBST(ZM_HAS_V4L,1)
else
AC_SUBST(ZM_HAS_V4L,0)
AC_MSG_WARN(zm requires Video4Linux or Video4Linux2 to be installed for analog or USB camera support)
fi
AC_CHECK_HEADERS(jpeglib.h,,AC_MSG_ERROR(zm requires libjpeg headers to be installed),)
AC_CHECK_HEADERS(mysql/mysql.h,,AC_MSG_ERROR(zm requires MySQL headers - check that MySQL development packages are installed),)
AC_LANG_PUSH([C])
AC_CHECK_HEADERS(libavutil/avutil.h,,,)
AC_CHECK_HEADERS(libavcodec/avcodec.h,,,)
AC_CHECK_HEADERS(libavformat/avformat.h,,,)
AC_CHECK_HEADERS(libswscale/swscale.h,,,)
AC_LANG_POP([C])
AC_CHECK_HEADERS(pcre/pcre.h,AC_SUBST(ZM_PCRE,"1"),,)
AC_CHECK_HEADERS(pcre.h,AC_SUBST(ZM_PCRE,"1"),,)
if test "$ENABLE_MMAP" == "yes"; then
AC_CHECK_HEADERS(sys/mman.h,,,)
AC_CHECK_HEADERS(fcntl.h,,,)
else
AC_CHECK_HEADERS(sys/ipc.h,,,)
AC_CHECK_HEADERS(sys/shm.h,,,)
fi
AC_CHECK_HEADERS(zlib.h,,,)
AC_CHECK_HEADERS(vlc/vlc.h,,,)
AC_CHECK_HEADERS(curl/curl.h,,,)
if test "$ZM_SSL_LIB" == "openssl"; then
AC_CHECK_DECLS(MD5,,AC_MSG_ERROR([zm requires openssl/md5.h - use ZM_SSL_LIB option to select gnutls instead]),[#include <stdlib.h>
#include <openssl/md5.h>])
else
if test "$ZM_HAS_GNUTLS_OPENSSL" == "1"; then
AC_CHECK_DECLS(MD5,,AC_MSG_ERROR([zm requires gnutls/openssl.h - use ZM_SSL_LIB option to select openssl instead]),[#include <stdlib.h>
#include <gnutls/openssl.h>])
else
AC_CHECK_DECLS(gnutls_fingerprint,,AC_MSG_ERROR([zm requires gnutls/gnutls.h - use ZM_SSL_LIB option to select openssl instead]),[#include <stdlib.h>
#include <gnutls/gnutls.h>])
fi
fi
AC_CHECK_DECLS(backtrace,,,[#include <execinfo.h>])
AC_CHECK_DECLS(backtrace_symbols,,,[#include <execinfo.h>])
AC_SUBST(LDFLAGS)
AC_PROG_PERL_VERSION(5.6.0)
# Compulsory perl modules
AC_PROG_PERL_MODULES(Sys::Syslog,,AC_MSG_ERROR(zm requires SYS:Syslog))
AC_PROG_PERL_MODULES(DBI,,AC_MSG_ERROR(zm requires DBI))
AC_PROG_PERL_MODULES(DBD::mysql,,AC_MSG_ERROR(zm requires DBD::mysql))
AC_PROG_PERL_MODULES(Getopt::Long,,AC_MSG_ERROR(zm requires Getopt::Long))
AC_PROG_PERL_MODULES(Time::HiRes,,AC_MSG_ERROR(zm requires Time::HiRes))
AC_PROG_PERL_MODULES(Date::Manip,,AC_MSG_ERROR(zm requires Date::Manip))
AC_PROG_PERL_MODULES(LWP::UserAgent,,AC_MSG_ERROR(zm requires LWP::UserAgent))
AC_PROG_PERL_MODULES(ExtUtils::MakeMaker,,AC_MSG_ERROR(zm requires ExtUtils::MakeMaker))
if test "$ENABLE_MMAP" == "yes"; then
AC_PROG_PERL_MODULES(Sys::Mmap,,AC_MSG_ERROR(zm requires Sys::Mmap for mapped memory - set --enable-mmap=no to use IPC shared memory instead))
fi
# Optional perl modules
AC_PROG_PERL_MODULES(Module::Load,,AC_MSG_WARN(Module::Load is required for PTZ camera control))
AC_PROG_PERL_MODULES(Device::SerialPort,,AC_MSG_WARN(Device::SerialPort is required for RS232/RS485 PTZ camera control))
AC_PROG_PERL_MODULES(Net::FTP,,AC_MSG_WARN(Net::FTP is required for automatic event uploading using ftp))
AC_PROG_PERL_MODULES(Net::SFTP::Foreign,,AC_MSG_WARN(Net::SFTP::Foreign is required for automatic event uploading using sftp))
AC_PROG_PERL_MODULES(Expect,,AC_MSG_WARN(Expect is required for automatic event uploading using sftp))
AC_PROG_PERL_MODULES(Archive::Tar,,AC_MSG_WARN(Archive::Tar may be required for automatic event uploading))
AC_PROG_PERL_MODULES(Archive::Zip,,AC_MSG_WARN(Archive::Zip may be required for automatic event uploading))
AC_PROG_PERL_MODULES(Net::SMTP,,AC_MSG_WARN(Net::SMTP may be required for automatic event email notification))
AC_PROG_PERL_MODULES(MIME::Lite,,AC_MSG_WARN(MIME::Lite may be required for automatic event email notification))
AC_PROG_PERL_MODULES(MIME::Entity,,AC_MSG_WARN(MIME::Entity may be required for automatic event email notification))
AC_PROG_PERL_MODULES(X10::ActiveHome,,AC_MSG_WARN(X10::ActiveHome is required for X.10 support))
AC_DEFINE_DIR([BINDIR],[bindir],[Expanded binary directory])
AC_DEFINE_DIR([LIBDIR],[libdir],[Expanded library directory])
AC_DEFINE_DIR([DATADIR],[datadir],[Expanded data directory])
AC_SUBST(PKGDATADIR,"$DATADIR/$PACKAGE")
AC_SUBST(ZM_PID,"$ZM_RUNDIR/zm.pid")
AC_DEFINE_DIR([SYSCONFDIR],[sysconfdir],[Expanded configuration directory])
AC_SUBST(ZM_CONFIG,"$SYSCONFDIR/zm.conf")
# Slight hack for non-standard perl install paths
if test "$prefix" != "NONE"; then
PERL_SITE_PREFIX=`perl -V:siteprefix | sed -e "s/.*='\(.*\)';/\1/"`
PERL_SITE_LIB=`perl -V:installsitelib | sed -e "s/.*='\(.*\)';/\1/"`
PERL_LIB_PATH=`echo $PERL_SITE_LIB | sed -e "s|^$PERL_SITE_PREFIX||"`
EXTRA_PERL_LIB="use lib '$prefix$PERL_LIB_PATH'; # Include custom perl install path"
PERL_MM_PARMS="PREFIX=$prefix"
else
EXTRA_PERL_LIB="# Include from system perl paths only"
PERL_MM_PARMS=
fi
AC_SUBST(PERL_MM_PARMS)
AC_SUBST(EXTRA_PERL_LIB)
AC_CONFIG_FILES([Makefile zm.conf zmconfgen.pl db/Makefile db/zm_create.sql onvif/Makefile onvif/scripts/Makefile misc/Makefile misc/apache.conf misc/logrotate.conf misc/syslog.conf misc/com.zoneminder.systemctl.policy misc/com.zoneminder.systemctl.rules scripts/Makefile scripts/zm scripts/zmaudit.pl scripts/zmcontrol.pl scripts/zmdc.pl scripts/zmfilter.pl scripts/zmpkg.pl scripts/zmtrack.pl scripts/zmcamtool.pl scripts/zmtrigger.pl scripts/zmupdate.pl scripts/zmvideo.pl scripts/zmwatch.pl scripts/zmx10.pl scripts/zmdbbackup scripts/zmdbrestore scripts/zmeventdump scripts/zmlogrotate.conf scripts/ZoneMinder/lib/ZoneMinder/Base.pm scripts/ZoneMinder/lib/ZoneMinder/Config.pm scripts/ZoneMinder/lib/ZoneMinder/Memory.pm scripts/ZoneMinder/lib/ZoneMinder/ConfigData.pm src/Makefile src/zm_config.h web/Makefile web/ajax/Makefile web/css/Makefile web/graphics/Makefile web/includes/Makefile web/includes/config.php web/js/Makefile web/lang/Makefile web/skins/Makefile web/skins/classic/Makefile web/skins/classic/ajax/Makefile web/skins/classic/css/Makefile web/skins/classic/graphics/Makefile web/skins/classic/includes/Makefile web/skins/classic/js/Makefile web/skins/classic/lang/Makefile web/skins/classic/views/Makefile web/skins/classic/views/css/Makefile web/skins/classic/views/js/Makefile web/skins/mobile/Makefile web/skins/mobile/ajax/Makefile web/skins/mobile/css/Makefile web/skins/mobile/graphics/Makefile web/skins/mobile/includes/Makefile web/skins/mobile/lang/Makefile web/skins/mobile/views/Makefile web/skins/mobile/views/css/Makefile web/tools/Makefile web/tools/mootools/Makefile web/views/Makefile web/skins/xml/Makefile web/skins/xml/views/Makefile web/skins/xml/includes/Makefile web/skins/flat/Makefile web/skins/flat/ajax/Makefile web/skins/flat/css/Makefile web/skins/flat/graphics/Makefile web/skins/flat/includes/Makefile web/skins/flat/js/Makefile web/skins/flat/lang/Makefile web/skins/flat/views/Makefile web/skins/flat/views/css/Makefile web/skins/flat/views/js/Makefile])
# Create the definitions for compilation and defaults for the database
AC_CONFIG_COMMANDS([src/zm_config_defines.h],[perl ./zmconfgen.pl])
# Manually generate the perl Makefile maker
AC_CONFIG_COMMANDS([scripts/ZoneMinder/Makefile],[(cd scripts/ZoneMinder; echo "perl Makefile.PL $PERL_MM_PARMS"; perl Makefile.PL $PERL_MM_PARMS)],[PERL_MM_PARMS=$PERL_MM_PARMS])
AC_CONFIG_COMMANDS([onvif/modules/Makefile],[(cd onvif/modules; echo "perl Makefile.PL $PERL_MM_PARMS"; perl Makefile.PL $PERL_MM_PARMS)],[PERL_MM_PARMS=$PERL_MM_PARMS])
AC_CONFIG_COMMANDS([onvif/proxy/Makefile],[(cd onvif/proxy; echo "perl Makefile.PL $PERL_MM_PARMS"; perl Makefile.PL $PERL_MM_PARMS)],[PERL_MM_PARMS=$PERL_MM_PARMS])
AC_OUTPUT

View File

@ -1,14 +0,0 @@
AUTOMAKE_OPTIONS = foreign
zmdbdatadir = $(pkgdatadir)/db
EXTRA_DIST = \
zm_create.sql.in \
$(dbupgrade_scripts)
dist_zmdbdata_DATA = \
zm_create.sql \
$(dbupgrade_scripts)
dbupgrade_scripts = $(wildcard zm_update-*.sql)

View File

@ -236,13 +236,15 @@ CREATE TABLE `Filters` (
DROP TABLE IF EXISTS `Frames`; DROP TABLE IF EXISTS `Frames`;
CREATE TABLE `Frames` ( CREATE TABLE `Frames` (
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`EventId` int(10) unsigned NOT NULL default '0', `EventId` int(10) unsigned NOT NULL default '0',
`FrameId` int(10) unsigned NOT NULL default '0', `FrameId` int(10) unsigned NOT NULL default '0',
`Type` enum('Normal','Bulk','Alarm') NOT NULL default 'Normal', `Type` enum('Normal','Bulk','Alarm') NOT NULL default 'Normal',
`TimeStamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP, `TimeStamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
`Delta` decimal(8,2) NOT NULL default '0.00', `Delta` decimal(8,2) NOT NULL default '0.00',
`Score` smallint(5) unsigned NOT NULL default '0', `Score` smallint(5) unsigned NOT NULL default '0',
PRIMARY KEY (`EventId`,`FrameId`), PRIMARY KEY (`Id`),
INDEX `EventId_idx` (`EventId`),
KEY `Type` (`Type`), KEY `Type` (`Type`),
KEY `TimeStamp` (`TimeStamp`) KEY `TimeStamp` (`TimeStamp`)
) ENGINE=@ZM_MYSQL_ENGINE@; ) ENGINE=@ZM_MYSQL_ENGINE@;
@ -267,7 +269,8 @@ DROP TABLE IF EXISTS `Logs`;
CREATE TABLE `Logs` ( CREATE TABLE `Logs` (
`TimeKey` decimal(16,6) NOT NULL, `TimeKey` decimal(16,6) NOT NULL,
`Component` varchar(32) NOT NULL, `Component` varchar(32) NOT NULL,
`Pid` smallint(6) DEFAULT NULL, `ServerId` int(10) unsigned,
`Pid` int(10) DEFAULT NULL,
`Level` tinyint(3) NOT NULL, `Level` tinyint(3) NOT NULL,
`Code` char(3) NOT NULL, `Code` char(3) NOT NULL,
`Message` text NOT NULL, `Message` text NOT NULL,
@ -315,12 +318,13 @@ DROP TABLE IF EXISTS `Monitors`;
CREATE TABLE `Monitors` ( CREATE TABLE `Monitors` (
`Id` int(10) unsigned NOT NULL auto_increment, `Id` int(10) unsigned NOT NULL auto_increment,
`Name` varchar(64) NOT NULL default '', `Name` varchar(64) NOT NULL default '',
`ServerId` int(10) unsigned,
`Type` enum('Local','Remote','File','Ffmpeg','Libvlc','cURL') NOT NULL default 'Local', `Type` enum('Local','Remote','File','Ffmpeg','Libvlc','cURL') NOT NULL default 'Local',
`Function` enum('None','Monitor','Modect','Record','Mocord','Nodect') NOT NULL default 'Monitor', `Function` enum('None','Monitor','Modect','Record','Mocord','Nodect') NOT NULL default 'Monitor',
`Enabled` tinyint(3) unsigned NOT NULL default '1', `Enabled` tinyint(3) unsigned NOT NULL default '1',
`LinkedMonitors` varchar(255) NOT NULL default '', `LinkedMonitors` varchar(255) NOT NULL default '',
`Triggers` set('X10') NOT NULL default '', `Triggers` set('X10') NOT NULL default '',
`Device` varchar(64) NOT NULL default '', `Device` tinytext NOT NULL default '',
`Channel` tinyint(3) unsigned NOT NULL default '0', `Channel` tinyint(3) unsigned NOT NULL default '0',
`Format` int(10) unsigned NOT NULL default '0', `Format` int(10) unsigned NOT NULL default '0',
`V4LMultiBuffer` tinyint(1) unsigned NOT NULL default '0', `V4LMultiBuffer` tinyint(1) unsigned NOT NULL default '0',
@ -340,6 +344,7 @@ CREATE TABLE `Monitors` (
`Palette` int(10) unsigned NOT NULL default '0', `Palette` int(10) unsigned NOT NULL default '0',
`Orientation` enum('0','90','180','270','hori','vert') NOT NULL default '0', `Orientation` enum('0','90','180','270','hori','vert') NOT NULL default '0',
`Deinterlacing` int(10) unsigned NOT NULL default '0', `Deinterlacing` int(10) unsigned NOT NULL default '0',
`RTSPDescribe` tinyint(1) unsigned NOT NULL default '0',
`Brightness` mediumint(7) NOT NULL default '-1', `Brightness` mediumint(7) NOT NULL default '-1',
`Contrast` mediumint(7) NOT NULL default '-1', `Contrast` mediumint(7) NOT NULL default '-1',
`Hue` mediumint(7) NOT NULL default '-1', `Hue` mediumint(7) NOT NULL default '-1',
@ -348,6 +353,7 @@ CREATE TABLE `Monitors` (
`LabelFormat` varchar(64) NOT NULL default '%N - %y/%m/%d %H:%M:%S', `LabelFormat` varchar(64) NOT NULL default '%N - %y/%m/%d %H:%M:%S',
`LabelX` smallint(5) unsigned NOT NULL default '0', `LabelX` smallint(5) unsigned NOT NULL default '0',
`LabelY` smallint(5) unsigned NOT NULL default '0', `LabelY` smallint(5) unsigned NOT NULL default '0',
`LabelSize` smallint(5) unsigned NOT NULL DEFAULT '1',
`ImageBufferCount` smallint(5) unsigned NOT NULL default '100', `ImageBufferCount` smallint(5) unsigned NOT NULL default '100',
`WarmupCount` smallint(5) unsigned NOT NULL default '25', `WarmupCount` smallint(5) unsigned NOT NULL default '25',
`PreEventCount` smallint(5) unsigned NOT NULL default '10', `PreEventCount` smallint(5) unsigned NOT NULL default '10',
@ -357,6 +363,8 @@ CREATE TABLE `Monitors` (
`SectionLength` int(10) unsigned NOT NULL default '600', `SectionLength` int(10) unsigned NOT NULL default '600',
`FrameSkip` smallint(5) unsigned NOT NULL default '0', `FrameSkip` smallint(5) unsigned NOT NULL default '0',
`MotionFrameSkip` smallint(5) unsigned NOT NULL default '0', `MotionFrameSkip` smallint(5) unsigned NOT NULL default '0',
`AnalysisFPS` decimal(5,2) default NULL,
`AnalysisUpdateDelay` smallint(5) unsigned NOT NULL default '0',
`MaxFPS` decimal(5,2) default NULL, `MaxFPS` decimal(5,2) default NULL,
`AlarmMaxFPS` decimal(5,2) default NULL, `AlarmMaxFPS` decimal(5,2) default NULL,
`FPSReportInterval` smallint(5) unsigned NOT NULL default '250', `FPSReportInterval` smallint(5) unsigned NOT NULL default '250',
@ -376,21 +384,40 @@ CREATE TABLE `Monitors` (
`DefaultScale` smallint(5) unsigned NOT NULL default '100', `DefaultScale` smallint(5) unsigned NOT NULL default '100',
`SignalCheckColour` varchar(32) NOT NULL default '#0000BE', `SignalCheckColour` varchar(32) NOT NULL default '#0000BE',
`WebColour` varchar(32) NOT NULL default 'red', `WebColour` varchar(32) NOT NULL default 'red',
`Exif` tinyint(1) unsigned NOT NULL default '0',
`Sequence` smallint(5) unsigned default NULL, `Sequence` smallint(5) unsigned default NULL,
PRIMARY KEY (`Id`) PRIMARY KEY (`Id`)
) ENGINE=@ZM_MYSQL_ENGINE@; ) ENGINE=@ZM_MYSQL_ENGINE@;
-- --
-- Table structure for table `States` -- Table structure for table `States`
-- -- PP - Added IsActive to track custom run states
-- Also made sure Name is unique
DROP TABLE IF EXISTS `States`; DROP TABLE IF EXISTS `States`;
CREATE TABLE `States` ( CREATE TABLE `States` (
`Id` int(10) unsigned NOT NULL auto_increment,
`Name` varchar(64) NOT NULL default '', `Name` varchar(64) NOT NULL default '',
`Definition` text NOT NULL, `Definition` text NOT NULL,
PRIMARY KEY (`Name`) `IsActive` tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (`Id`),
UNIQUE KEY (`Name`)
) ENGINE=@ZM_MYSQL_ENGINE@; ) ENGINE=@ZM_MYSQL_ENGINE@;
INSERT INTO States (Name,Definition,IsActive) VALUES ('default','','1');
--
-- Table structure for table `Servers`
--
DROP TABLE IF EXISTS `Servers`;
CREATE TABLE `Servers` (
`Id` int(10) unsigned NOT NULL auto_increment,
`Hostname` TEXT,
`Name` varchar(64) NOT NULL default '',
`State_Id` int(10) unsigned,
PRIMARY KEY (`Id`)
) ENGINE=@ZM_MYSQL_ENGINE@;
-- --
-- Table structure for table `Stats` -- Table structure for table `Stats`
-- --
@ -446,6 +473,7 @@ CREATE TABLE `Users` (
`Events` enum('None','View','Edit') NOT NULL default 'None', `Events` enum('None','View','Edit') NOT NULL default 'None',
`Control` enum('None','View','Edit') NOT NULL default 'None', `Control` enum('None','View','Edit') NOT NULL default 'None',
`Monitors` enum('None','View','Edit') NOT NULL default 'None', `Monitors` enum('None','View','Edit') NOT NULL default 'None',
`Groups` enum('None','View','Edit') NOT NULL default 'None',
`Devices` enum('None','View','Edit') NOT NULL default 'None', `Devices` enum('None','View','Edit') NOT NULL default 'None',
`System` enum('None','View','Edit') NOT NULL default 'None', `System` enum('None','View','Edit') NOT NULL default 'None',
`MaxBandwidth` varchar(16) NOT NULL default '', `MaxBandwidth` varchar(16) NOT NULL default '',
@ -462,7 +490,7 @@ DROP TABLE IF EXISTS `ZonePresets`;
CREATE TABLE `ZonePresets` ( CREATE TABLE `ZonePresets` (
`Id` int(10) unsigned NOT NULL auto_increment, `Id` int(10) unsigned NOT NULL auto_increment,
`Name` varchar(64) NOT NULL default '', `Name` varchar(64) NOT NULL default '',
`Type` enum('Active','Inclusive','Exclusive','Preclusive','Inactive') NOT NULL default 'Active', `Type` enum('Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy') NOT NULL default 'Active',
`Units` enum('Pixels','Percent') NOT NULL default 'Pixels', `Units` enum('Pixels','Percent') NOT NULL default 'Pixels',
`CheckMethod` enum('AlarmedPixels','FilteredPixels','Blobs') NOT NULL default 'Blobs', `CheckMethod` enum('AlarmedPixels','FilteredPixels','Blobs') NOT NULL default 'Blobs',
`MinPixelThreshold` smallint(5) unsigned default NULL, `MinPixelThreshold` smallint(5) unsigned default NULL,
@ -491,7 +519,7 @@ CREATE TABLE `Zones` (
`Id` int(10) unsigned NOT NULL auto_increment, `Id` int(10) unsigned NOT NULL auto_increment,
`MonitorId` int(10) unsigned NOT NULL default '0', `MonitorId` int(10) unsigned NOT NULL default '0',
`Name` varchar(64) NOT NULL default '', `Name` varchar(64) NOT NULL default '',
`Type` enum('Active','Inclusive','Exclusive','Preclusive','Inactive') NOT NULL default 'Active', `Type` enum('Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy') NOT NULL default 'Active',
`Units` enum('Pixels','Percent') NOT NULL default 'Pixels', `Units` enum('Pixels','Percent') NOT NULL default 'Pixels',
`NumCoords` tinyint(3) unsigned NOT NULL default '0', `NumCoords` tinyint(3) unsigned NOT NULL default '0',
`Coords` tinytext NOT NULL, `Coords` tinytext NOT NULL,
@ -531,7 +559,7 @@ CREATE TABLE `Zones` (
-- --
-- Create a default admin user. -- Create a default admin user.
-- --
insert into Users VALUES (NULL,'admin',password('admin'),'',1,'View','Edit','Edit','Edit','Edit','Edit','',''); insert into Users VALUES (NULL,'admin',password('admin'),'',1,'View','Edit','Edit','Edit','Edit','Edit','Edit','','');
-- --
-- Add a sample filter to purge the oldest 100 events when the disk is 95% full -- Add a sample filter to purge the oldest 100 events when the disk is 95% full
@ -559,6 +587,13 @@ INSERT INTO Controls VALUES (NULL,'Toshiba IK-WB11A','Remote','Toshiba_IK_WB11A'
INSERT INTO Controls VALUES (NULL,'WanscamPT','Remote','Wanscam',1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,16,0,0,0,0,0,1,16,1,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0); INSERT INTO Controls VALUES (NULL,'WanscamPT','Remote','Wanscam',1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,16,0,0,0,0,0,1,16,1,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0);
INSERT INTO Controls VALUES (NULL,'3S Domo N5071', 'Remote', '3S', 0, 0, 1, 1, 0, 1, 1, 0, 0, 9999, 0, 9999, 0, 0, 0, 1, 1, 1, 1, 0, 0, 9999, 20, 9999, 0, 0, 0, 1, 1, 1, 1, 0, 0, 9999, 1, 9999, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 64, 1, 0, 1, 1, 0, 0, 0, 0, 1, -180, 180, 40, 100, 1, 40, 100, 0, 0, 1, -180, 180, 40, 100, 1, 40, 100, 0, 0, 0, 0); INSERT INTO Controls VALUES (NULL,'3S Domo N5071', 'Remote', '3S', 0, 0, 1, 1, 0, 1, 1, 0, 0, 9999, 0, 9999, 0, 0, 0, 1, 1, 1, 1, 0, 0, 9999, 20, 9999, 0, 0, 0, 1, 1, 1, 1, 0, 0, 9999, 1, 9999, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 64, 1, 0, 1, 1, 0, 0, 0, 0, 1, -180, 180, 40, 100, 1, 40, 100, 0, 0, 1, -180, 180, 40, 100, 1, 40, 100, 0, 0, 0, 0);
INSERT INTO Controls VALUES (NULL,'ONVIF Camera','Ffmpeg','onvif',0,0,1,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,255,16,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,6,1,1,0,0,0,1,10,0,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0); INSERT INTO Controls VALUES (NULL,'ONVIF Camera','Ffmpeg','onvif',0,0,1,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,255,16,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,6,1,1,0,0,0,1,10,0,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0);
INSERT INTO `Controls` VALUES (NULL,'Foscam 9831W','Ffmpeg','FI9831W',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,16,1,1,1,1,0,0,0,1,1,0,360,0,360,1,0,4,0,0,1,0,90,0,90,0,0,0,0,0,0,0);
INSERT INTO `Controls` VALUES (NULL,'Foscam FI8918W','Ffmpeg','FI8918W',0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,8,0,1,1,1,0,0,0,1,1,0,360,0,360,1,0,4,0,0,1,0,90,0,90,1,0,4,0,0,0,0);
INSERT INTO `Controls` VALUES (NULL,'SunEyes SP-P1802SWPTZ','Libvlc','SPP1802SWPTZ',0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,8,0,1,1,0,0,0,0,1,1,0,0,0,0,1,0,64,0,0,1,0,0,0,0,1,0,64,0,0,0,0);
INSERT INTO `Controls` VALUES (NULL,'Wanscam HW0025','Libvlc','WanscamHW0025', 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 16, 1, 1, 1, 1, 0, 1, 1, 0, 1, 0, 350, 0, 0, 1, 0, 10, 0, 0, 1, 0, 0, 0, 0, 1, 0, 10, 0, 0, 0, 0);
INSERT INTO `Controls` VALUES (NULL,'IPCC 7210W','Libvlc','IPCC7210W', 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 16, 1, 1, 1, 1, 0, 1, 1, 0, 1, 0, 350, 0, 0, 1, 0, 10, 0, 0, 1, 0, 0, 0, 0, 1, 0, 10, 0, 0, 0, 0);
INSERT INTO `Controls` VALUES (NULL,'Vivotek ePTZ','Remote','Vivotek_ePTZ',0,0,1,1,0,0,0,1,0,0,0,0,1,0,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,1,0,0,0,0,1,0,5,0,0,1,0,0,0,0,1,0,5,0,0,0,0);
INSERT INTO `Controls` VALUES (NULL,'Netcat ONVIF','Ffmpeg','Netcat',0,0,1,1,0,0,0,1,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,100,5,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,100,5,5,0,0,0,1,255,1,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0);
-- --
-- Add some monitor preset values -- Add some monitor preset values
@ -630,6 +665,7 @@ INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI8608W FFMPEG H.264','Ffmpeg',N
INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI9821W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:88/videoMain',NULL,1280,720,0,NULL,1,'12','<admin_pwd>','<ip-address>',100,100); INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI9821W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:88/videoMain',NULL,1280,720,0,NULL,1,'12','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Loftek Sentinel PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<ip-address>','80','/videostream.cgi?user=<username>&pwd=<password>&resolution=32&rate=11',NULL,640,480,4,NULL,1,'13','','<username>:<pwd>@<ip-address>',100,100); INSERT INTO MonitorPresets VALUES (NULL,'Loftek Sentinel PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<ip-address>','80','/videostream.cgi?user=<username>&pwd=<password>&resolution=32&rate=11',NULL,640,480,4,NULL,1,'13','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Airlink 777W PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<username>:<password>@<ip-address>','80','/cgi/mjpg/mjpg.cgi',NULL,640,480,4,NULL,1,'7','','<username>:<pwd>@<ip-address>',100,100); INSERT INTO MonitorPresets VALUES (NULL,'Airlink 777W PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<username>:<password>@<ip-address>','80','/cgi/mjpg/mjpg.cgi',NULL,640,480,4,NULL,1,'7','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'SunEyes SP-P1802SWPTZ','Libvlc','/dev/video<?>','0',255,'','rtpMulti','','80','rtsp://<ip-address>:554/11','',1920,1080,0,0.00,1,'16','-speed=64','<ip-address>:<port>',100,33);
-- --
-- Add some zone preset values -- Add some zone preset values

1
db/zm_update-1.28.1.sql Normal file
View File

@ -0,0 +1 @@
ALTER TABLE Monitors MODIFY Device tinytext;

22
db/zm_update-1.28.100.sql Normal file
View File

@ -0,0 +1,22 @@
--
-- This updates a 1.28.99 database to 1.28.100
--
--
-- Add ServerId column to Monitors
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'ServerId'
) > 0,
"SELECT 'Column ServerId exists in Monitors'",
"ALTER TABLE Monitors ADD `ServerId` int(10) unsigned AFTER `Name`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

22
db/zm_update-1.28.101.sql Normal file
View File

@ -0,0 +1,22 @@
--
-- This updates a 1.28.100 database to 1.28.101
--
--
-- Add Groups column to Users
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Users'
AND table_schema = DATABASE()
AND column_name = 'Groups'
) > 0,
"SELECT 'Column Groups exists in Users'",
"ALTER TABLE Users ADD COLUMN `Groups` ENUM('None','View','Edit') NOT NULL DEFAULT 'None' AFTER `Monitors`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

17
db/zm_update-1.28.102.sql Normal file
View File

@ -0,0 +1,17 @@
--
-- Add Monitor Exif field
-- Used to enable or disable processing of the remote camera RTSP DESCRIBE response header
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'Exif'
) > 0,
"SELECT 'Column Exif already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `Exif` tinyint(1) unsigned NOT NULL default '0' AFTER `WebColour`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

22
db/zm_update-1.28.103.sql Normal file
View File

@ -0,0 +1,22 @@
--
-- This updates a 1.28.102 database to 1.28.103
--
--
-- Add LabelSize column to Monitors
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'LabelSize'
) > 0,
"SELECT 'Column LabelSize exists in Monitors'",
"ALTER TABLE Monitors ADD `LabelSize` smallint(5) unsigned NOT NULL DEFAULT '1' AFTER `LabelY`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

40
db/zm_update-1.28.104.sql Normal file
View File

@ -0,0 +1,40 @@
--
-- This updates a 1.28.103 database to 1.28.104
--
--
-- Add AnalysisFPS column to Monitors
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'AnalysisFPS'
) > 0,
"SELECT 'Column AnalysisFPS exists in Monitors'",
"ALTER TABLE Monitors ADD `AnalysisFPS` decimal(5,2) default NULL AFTER `MotionFrameSkip`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
--
-- Add AnalysisUpdateDelay column to Monitors
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'AnalysisUpdateDelay'
) > 0,
"SELECT 'Column AnalysisUpdateDelay exists in Monitors'",
"ALTER TABLE Monitors ADD `AnalysisUpdateDelay` smallint(5) unsigned not null default 0 AFTER `AnalysisFPS`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

10
db/zm_update-1.28.105.sql Normal file
View File

@ -0,0 +1,10 @@
--
-- This updates a 1.28.104 database to 1.28.105
--
--
-- Add Privacy type to Zone Types
--
alter table Zones modify Type enum('Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy') NOT NULL DEFAULT 'Active';
alter table ZonePresets modify Type enum('Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy') NOT NULL DEFAULT 'Active';

21
db/zm_update-1.28.106.sql Normal file
View File

@ -0,0 +1,21 @@
--
-- This updates a 1.28.105 database to 1.28.106
--
--
-- Add Monitor RTSPDescribe field
-- Used to enable or disable processing of the remote camera RTSP DESCRIBE response header
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'RTSPDescribe'
) > 0,
"SELECT 'Column RTSPDescribe already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `RTSPDescribe` tinyint(1) unsigned NOT NULL default '0' AFTER `Deinterlacing`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

21
db/zm_update-1.28.107.sql Normal file
View File

@ -0,0 +1,21 @@
--
-- This updates a 1.28.106 database to 1.28.107
--
--
-- Update Frame table to have a PrimaryKey of ID, insetad of a Composite Primary Key
-- Used primarially for compatibility with CakePHP
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Frames'
AND table_schema = DATABASE()
AND column_name = 'Id'
) > 0,
"SELECT 'Column ID already exists in Frames'",
"ALTER TABLE `Frames` ADD COLUMN `Id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT FIRST, DROP PRIMARY KEY, ADD PRIMARY KEY(`Id`)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

22
db/zm_update-1.28.108.sql Normal file
View File

@ -0,0 +1,22 @@
--
-- This updates a 1.28.107 database to 1.28.108
--
--
-- Update Frame table to have an Index on EventId, per the change made in 1.28.107
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.STATISTICS
WHERE table_name = 'Frames'
AND table_schema = DATABASE()
AND index_name = 'EventId_idx'
) > 0,
"SELECT 'EventId Index already exists on Frames table'",
"CREATE INDEX `EventId_idx` ON `Frames` (`EventId`)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

21
db/zm_update-1.28.109.sql Normal file
View File

@ -0,0 +1,21 @@
--
-- This updates a 1.28.108 database to 1.28.109
--
--
-- Update Frame table to have a PrimaryKey of ID, insetad of a Composite Primary Key
-- Used primarially for compatibility with CakePHP
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Servers'
AND table_schema = DATABASE()
AND column_name = 'Hostname'
) > 0,
"SELECT 'Column Hostname already exists in Servers'",
"ALTER TABLE `Servers` ADD COLUMN `Hostname` TEXT AFTER Name"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

21
db/zm_update-1.28.110.sql Normal file
View File

@ -0,0 +1,21 @@
--
-- This updates a 1.28.109 database to 1.28.110
--
--
-- Update Frame table to have a PrimaryKey of ID, insetad of a Composite Primary Key
-- Used primarially for compatibility with CakePHP
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Logs'
AND table_schema = DATABASE()
AND column_name = 'ServerId'
) > 0,
"SELECT 'Column ServerId already exists in Logs'",
"ALTER TABLE `Logs` ADD COLUMN `ServerId` int(10) unsigned AFTER Component"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

395
db/zm_update-1.28.99.sql Normal file
View File

@ -0,0 +1,395 @@
--
-- This updates a 1.28.10 database to 1.28.99
--
--
-- Add Controls definition for ONVIF
-- Add Controls definition for FI9831W
-- Add Controls definition for FI8918W
--
INSERT INTO Controls
SELECT * FROM (SELECT NULL as Id,
'ONVIF Camera' as Name,
'Ffmpeg' as Type,
'onvif' as Protocol,
0 as CanWake,
0 as CanSleep,
1 as CanReset,
1 as CanZoom,
0 as CanAutoZoom,
0 as CanZoomAbs,
0 as CanZoomRel,
1 as CanZoomCon,
0 as MinZoomRange,
0 as MaxZoomRange,
0 as MinZoomStep,
0 as MaxZoomStep,
0 as HasZoomSpeed,
0 as MinZoomSpeed,
0 as MaxZoomSpeed,
0 as CanFocus,
0 as CanAutoFocus,
0 as CanFocusAbs,
0 as CanFocusRel,
0 as CanFocusCon,
0 as MinFocusRange,
0 as MaxFocusRange,
0 as MinFocusStep,
0 as MaxFocusStep,
0 as HasFocusSpeed,
0 as MinFocusSpeed,
0 as MaxFocusSpeed,
1 as CanIris,
0 as CanAutoIris,
1 as CanIrisAbs,
0 as CanIrisRel,
0 as CanIrisCon,
0 as MinIrisRange,
255 as MaxIrisRange,
16 as MinIrisStep,
16 as MaxIrisStep,
0 as HasIrisSpeed,
0 as MinIrisSpeed,
0 as MaxIrisSpeed,
0 as CanGain,
0 as CanAutoGain,
0 as CanGainAbs,
0 as CanGainRel,
0 as CanGainCon,
0 as MinGainRange,
0 as MaxGainRange,
0 as MinGainStep,
0 as MaxGainStep,
0 as HasGainSpeed,
0 as MinGainSpeed,
0 as MaxGainSpeed,
1 as CanWhite,
0 as CanAutoWhite,
1 as CanWhiteAbs,
0 as CanWhiteRel,
0 as CanWhiteCon,
0 as MinWhiteRange,
6 as MaxWhiteRange,
1 as MinWhiteStep,
1 as MaxWhiteStep,
0 as HasWhiteSpeed,
0 as MinWhiteSpeed,
0 as MaxWhiteSpeed,
1 as HasPresets,
10 as NumPresets,
0 as HasHomePreset,
1 as CanSetPresets,
1 as CanMove,
1 as CanMoveDiag,
0 as CanMoveMap,
0 as CanMoveAbs,
0 as CanMoveRel,
1 as CanMoveCon,
1 as CanPan,
0 as MinPanRange,
0 as MaxPanRange,
0 as MinPanStep,
0 as MaxPanStep,
0 as HasPanSpeed,
0 as MinPanSpeed,
0 as MaxPanSpeed,
0 as HasTurboPan,
0 as TurboPanSpeed,
1 as CanTilt,
0 as MinTiltRange,
0 as MaxTiltRange,
0 as MinTiltStep,
0 as MaxTiltStep,
0 as HasTiltSpeed,
0 as MinTiltSpeed,
0 as MaxTiltSpeed,
0 as HasTurboTilt,
0 as TurboTiltSpeed,
0 as CanAutoScan,
0 as NumScanPaths) AS tmp
WHERE NOT EXISTS (
SELECT Name FROM Controls WHERE name = 'ONVIF Camera'
) LIMIT 1;
INSERT INTO Controls
SELECT * FROM (SELECT NULL as Id,
'Foscam 9831W' as Name,
'Ffmpeg' as Type,
'FI9831W' as Protocol,
0 as CanWake,
0 as CanSleep,
1 as CanReset,
0 as CanZoom,
0 as CanAutoZoom,
0 as CanZoomAbs,
0 as CanZoomRel,
0 as CanZoomCon,
0 as MinZoomRange,
0 as MaxZoomRange,
0 as MinZoomStep,
0 as MaxZoomStep,
0 as HasZoomSpeed,
0 as MinZoomSpeed,
0 as MaxZoomSpeed,
0 as CanFocus,
0 as CanAutoFocus,
0 as CanFocusAbs,
0 as CanFocusRel,
0 as CanFocusCon,
0 as MinFocusRange,
0 as MaxFocusRange,
0 as MinFocusStep,
0 as MaxFocusStep,
0 as HasFocusSpeed,
0 as MinFocusSpeed,
0 as MaxFocusSpeed,
0 as CanIris,
0 as CanAutoIris,
0 as CanIrisAbs,
0 as CanIrisRel,
0 as CanIrisCon,
0 as MinIrisRange,
0 as MaxIrisRange,
0 as MinIrisStep,
0 as MaxIrisStep,
0 as HasIrisSpeed,
0 as MinIrisSpeed,
0 as MaxIrisSpeed,
0 as CanGain,
0 as CanAutoGain,
0 as CanGainAbs,
0 as CanGainRel,
0 as CanGainCon,
0 as MinGainRange,
0 as MaxGainRange,
0 as MinGainStep,
0 as MaxGainStep,
0 as HasGainSpeed,
0 as MinGainSpeed,
0 as MaxGainSpeed,
0 as CanWhite,
0 as CanAutoWhite,
0 as CanWhiteAbs,
0 as CanWhiteRel,
0 as CanWhiteCon,
0 as MinWhiteRange,
0 as MaxWhiteRange,
0 as MinWhiteStep,
0 as MaxWhiteStep,
0 as HasWhiteSpeed,
0 as MinWhiteSpeed,
0 as MaxWhiteSpeed,
0 as HasPresets,
16 as NumPresets,
1 as HasHomePreset,
1 as CanSetPresets,
1 as CanMove,
1 as CanMoveDiag,
0 as CanMoveMap,
0 as CanMoveAbs,
0 as CanMoveRel,
1 as CanMoveCon,
1 as CanPan,
0 as MinPanRange,
360 as MaxPanRange,
0 as MinPanStep,
360 as MaxPanStep,
1 as HasPanSpeed,
0 as MinPanSpeed,
4 as MaxPanSpeed,
0 as HasTurboPan,
0 as TurboPanSpeed,
1 as CanTilt,
0 as MinTiltRange,
90 as MaxTiltRange,
0 as MinTiltStep,
90 as MaxTiltStep,
0 as HasTiltSpeed,
0 as MinTiltSpeed,
0 as MaxTiltSpeed,
0 as HasTurboTilt,
0 as TurboTiltSpeed,
0 as CanAutoScan,
0 as NumScanPaths) AS tmp
WHERE NOT EXISTS (
SELECT Name FROM Controls WHERE name = 'Foscam 9831W'
) LIMIT 1;
INSERT INTO Controls
SELECT * FROM (SELECT NULL as Id,
'Foscam FI8918W' as Name,
'Ffmpeg' as Type,
'FI8918W' as Protocol,
0 as CanWake,
0 as CanSleep,
1 as CanReset,
0 as CanZoom,
0 as CanAutoZoom,
0 as CanZoomAbs,
0 as CanZoomRel,
0 as CanZoomCon,
0 as MinZoomRange,
0 as MaxZoomRange,
0 as MinZoomStep,
0 as MaxZoomStep,
0 as HasZoomSpeed,
0 as MinZoomSpeed,
0 as MaxZoomSpeed,
0 as CanFocus,
0 as CanAutoFocus,
0 as CanFocusAbs,
0 as CanFocusRel,
0 as CanFocusCon,
0 as MinFocusRange,
0 as MaxFocusRange,
0 as MinFocusStep,
0 as MaxFocusStep,
0 as HasFocusSpeed,
0 as MinFocusSpeed,
0 as MaxFocusSpeed,
0 as CanIris,
0 as CanAutoIris,
0 as CanIrisAbs,
0 as CanIrisRel,
0 as CanIrisCon,
0 as MinIrisRange,
0 as MaxIrisRange,
0 as MinIrisStep,
0 as MaxIrisStep,
0 as HasIrisSpeed,
0 as MinIrisSpeed,
0 as MaxIrisSpeed,
0 as CanGain,
0 as CanAutoGain,
0 as CanGainAbs,
0 as CanGainRel,
0 as CanGainCon,
0 as MinGainRange,
0 as MaxGainRange,
0 as MinGainStep,
0 as MaxGainStep,
0 as HasGainSpeed,
0 as MinGainSpeed,
0 as MaxGainSpeed,
0 as CanWhite,
0 as CanAutoWhite,
0 as CanWhiteAbs,
0 as CanWhiteRel,
0 as CanWhiteCon,
0 as MinWhiteRange,
0 as MaxWhiteRange,
0 as MinWhiteStep,
0 as MaxWhiteStep,
0 as HasWhiteSpeed,
0 as MinWhiteSpeed,
0 as MaxWhiteSpeed,
0 as HasPresets,
8 as NumPresets,
0 as HasHomePreset,
1 as CanSetPresets,
1 as CanMove,
1 as CanMoveDiag,
0 as CanMoveMap,
0 as CanMoveAbs,
0 as CanMoveRel,
1 as CanMoveCon,
1 as CanPan,
0 as MinPanRange,
360 as MaxPanRange,
0 as MinPanStep,
360 as MaxPanStep,
1 as HasPanSpeed,
0 as MinPanSpeed,
4 as MaxPanSpeed,
0 as HasTurboPan,
0 as TurboPanSpeed,
1 as CanTilt,
0 as MinTiltRange,
90 as MaxTiltRange,
0 as MinTiltStep,
90 as MaxTiltStep,
0 as HasTiltSpeed,
0 as MinTiltSpeed,
0 as MaxTiltSpeed,
0 as HasTurboTilt,
0 as TurboTiltSpeed,
0 as CanAutoScan,
0 as NumScanPaths) AS tmp
WHERE NOT EXISTS (
SELECT Name FROM Controls WHERE name = 'Foscam FI8918W'
) LIMIT 1;
--
-- Hide USE_DEEP_STORAGE from user to prevent accidental event loss
--
UPDATE `zm`.`Config` SET `Category`='hidden' WHERE `Name`='ZM_USE_DEEP_STORAGE';
--
-- Add Id column to State
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'States'
AND table_schema = DATABASE()
AND column_name = 'Id'
) > 0,
"SELECT 'Column Id exists in States'",
"ALTER TABLE States DROP PRIMARY KEY, ADD `Id` int(10) unsigned auto_increment NOT NULL PRIMARY KEY FIRST"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
-- PP:The States table will be updated to have a new column called IsActive
-- used to keep track of which custom state is active (if any)
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'States'
AND table_schema = DATABASE()
AND column_name = 'IsActive'
) > 0,
"SELECT 'Column IsActive exists in States'",
"ALTER TABLE `States` ADD `IsActive` tinyint(3) unsigned not null default 0 AFTER `Definition`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
-- PP:If default state does not exist, create it and set its IsActive to 1
INSERT INTO States (Name,Definition,IsActive)
SELECT * FROM (SELECT 'default', '', '1') AS tmp
WHERE NOT EXISTS (
SELECT Name FROM States WHERE Name = 'default'
) LIMIT 1;
-- PP:Start with a sane isActive state
UPDATE States SET IsActive = '0';
UPDATE States SET IsActive = '1' WHERE Name = 'default';
-- PP:Finally convert States to make sure Names are unique
-- If duplicate states existed while upgrading, that is
-- very likely an error that ZM allowed earlier, so
-- we are picking up the first one and deleting the others
ALTER TABLE States ADD UNIQUE (Name);
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.TABLES
WHERE table_name = 'Servers'
AND table_schema = DATABASE()
) > 0,
"SELECT 'Servers table exists'",
"CREATE TABLE `Servers` (
`Id` int(10) unsigned NOT NULL auto_increment,
`Name` varchar(64) NOT NULL default '',
`State_Id` int(10) unsigned,
PRIMARY KEY (`Id`)
)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

5
db/zm_update-1.29.0.sql Normal file
View File

@ -0,0 +1,5 @@
--
-- This updates a 1.28.110 database to 1.29.0
--
-- No changes required
--

7
db/zm_update-1.29.1.sql Normal file
View File

@ -0,0 +1,7 @@
--
-- This updates a 1.29.0 database to 1.29.1
--
--
-- Increase the size of the Pid field for FreeBSD
ALTER TABLE Logs MODIFY Pid int(10);

5
db/zm_update-1.30.0.sql Normal file
View File

@ -0,0 +1,5 @@
--
-- This updates a 1.29.1 database to 1.30.0
--
-- No changes required
--

View File

@ -1,7 +1,6 @@
Alias /zm /usr/share/zoneminder Alias /zm /usr/share/zoneminder/www
<Directory /usr/share/zoneminder> <Directory /usr/share/zoneminder/www>
php_flag register_globals off
Options Indexes FollowSymLinks Options Indexes FollowSymLinks
<IfModule mod_dir.c> <IfModule mod_dir.c>
DirectoryIndex index.php DirectoryIndex index.php

View File

@ -1,3 +1,32 @@
zoneminder (1.28.108-nmu2015100101) wheezy; urgency=low
*
-- Isaac Connor <iconnor@connortechnology.com> Thu, 01 Oct 2015 18:20:29 +0000
zoneminder (1.28.107-nmu2015092401) wheezy; urgency=low
*
-- Isaac Connor <iconnor@connortechnology.com> Thu, 24 Sep 2015 14:15:46 +0000
zoneminder (1.28.1+106-nmu2015091001) wheezy; urgency=low
*
-- Isaac Connor <iconnor@connortechnology.com> Thu, 10 Sep 2015 18:03:43 +0000
zoneminder (1.28.0-0.1) wheezy; urgency=low
* Use CMake instead of Autotools to simplify
debian/rules and have less build-depends.
* Some lintian love in debian/{control,copyright}
and perl ZoneMinder modules.
* Don't purge database if we use a remote
MySQL server.
-- Cosme Domínguez Díaz <cosme.ddiaz@gmail.com> Sun, 09 Nov 2014 02:20:20 +0100
zoneminder (1.28.0-wheezy) wheezy; urgency=medium zoneminder (1.28.0-wheezy) wheezy; urgency=medium
* Release * Release

View File

@ -2,14 +2,54 @@ Source: zoneminder
Section: net Section: net
Priority: optional Priority: optional
Maintainer: Isaac Connor <iconnor@connortechnology.com> Maintainer: Isaac Connor <iconnor@connortechnology.com>
Build-Depends: debhelper (>= 7.0.50), autoconf, automake, dpatch, libphp-serialization-perl, libgnutls-dev, libmysqlclient-dev | libmariadbclient-dev, libdbd-mysql-perl, libdate-manip-perl, libwww-perl, libjpeg8-dev, libpcre3-dev, libavcodec-dev, libavformat-dev (>= 3:0.svn20090204), libswscale-dev (>= 3:0.svn20090204), libavutil-dev, libv4l-dev (>= 0.8.3), libbz2-dev, libtool, libsys-mmap-perl, ffmpeg | libav-tools, libnetpbm10-dev, libavdevice-dev, libdevice-serialport-perl, libpcre3, libarchive-zip-perl, libmime-lite-perl, libjpeg8, dh-autoreconf, libvlccore-dev, libvlc-dev, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev, libgcrypt11-dev Build-Depends: debhelper (>= 9), cmake
Standards-Version: 3.9.2 , libphp-serialization-perl
, libgnutls28-dev | libgnutls-dev
, libmysqlclient-dev | libmariadbclient-dev
, libjpeg8-dev
, libpcre3-dev
, libavcodec-dev, libavformat-dev (>= 3:0.svn20090204), libswscale-dev (>= 3:0.svn20090204), libavutil-dev
, libv4l-dev (>= 0.8.3)
, libbz2-dev
, libav-tools
, libnetpbm10-dev
, libavdevice-dev
, libvlccore-dev, libvlc-dev
, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev
, libgcrypt11-dev, libpolkit-gobject-1-dev
, libphp-serialization-perl
, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl, libdbd-mysql-perl
, libwww-perl, libarchive-tar-perl, libarchive-zip-perl, libdevice-serialport-perl
, libmodule-load-perl, libsys-mmap-perl, libjson-any-perl
, libnet-sftp-foreign-perl, libio-pty-perl, libexpect-perl
, libdata-dump-perl, libclass-std-fast-perl, libsoap-wsdl-perl, libio-socket-multicast-perl, libdigest-sha-perl
, libsys-cpu-perl, libsys-meminfo-perl
, libdata-uuid-perl
Standards-Version: 3.9.4
Package: zoneminder Package: zoneminder
Architecture: any Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, apache2 | httpd, libapache2-mod-php5 | libapache2-mod-fcgid | php5-fpm, php5, php5-mysql|php5-mysqlnd, libphp-serialization-perl, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl, mariadb-client|mysql-client, libwww-perl, libarchive-tar-perl, libarchive-zip-perl, libdevice-serialport-perl, libpcre3, ffmpeg | libav-tools, rsyslog | system-log-daemon, libmodule-load-perl, libsys-mmap-perl, libjson-any-perl, netpbm, libavdevice53, libjpeg8, zip, libnet-sftp-foreign-perl, libio-pty-perl, libexpect-perl, libvlccore5 | libvlccore7, libvlc5, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev, libpolkit-gobject-1-0 Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
Recommends: mysql-server|mariadb-server , apache2 | httpd, libapache2-mod-php5 | libapache2-mod-fcgid | php5-fpm
Description: A video camera security and surveillance solution , php5-mysqlnd | php5-mysql
, mariadb-client | mysql-client
, libphp-serialization-perl
, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl, libdbd-mysql-perl
, libwww-perl, libarchive-tar-perl, libarchive-zip-perl, libdevice-serialport-perl
, libmodule-load-perl, libsys-mmap-perl, libjson-any-perl
, libnet-sftp-foreign-perl, libio-pty-perl, libexpect-perl
, libdata-dump-perl, libclass-std-fast-perl, libsoap-wsdl-perl, libio-socket-multicast-perl, libdigest-sha-perl
, libsys-cpu-perl, libsys-meminfo-perl
, libdata-uuid-perl
, libpcre3
, libav-tools, libavdevice53
, rsyslog | system-log-daemon
, netpbm , libjpeg8
, zip
, libvlccore5 | libvlccore7, libvlc5
, libpolkit-gobject-1-0, php5-gd
Recommends: mysql-server | mariadb-server
Description: Video camera security and surveillance solution
ZoneMinder is intended for use in single or multi-camera video security ZoneMinder is intended for use in single or multi-camera video security
applications, including commercial or home CCTV, theft prevention and child applications, including commercial or home CCTV, theft prevention and child
or family member or home monitoring and other care scenarios. It or family member or home monitoring and other care scenarios. It
@ -23,10 +63,10 @@ Description: A video camera security and surveillance solution
Package: zoneminder-dbg Package: zoneminder-dbg
Architecture: any Architecture: any
Depends: Section: debug
zoneminder (= ${binary:Version}), Priority: extra
${misc:Depends} Depends: zoneminder (= ${binary:Version}), ${misc:Depends}
Description: debugging syumbols for zoneminder. Description: Debugging symbols for zoneminder.
ZoneMinder is a video camera security and surveillance solution. ZoneMinder is a video camera security and surveillance solution.
ZoneMinder is intended for use in single or multi-camera video security ZoneMinder is intended for use in single or multi-camera video security
applications, including commercial or home CCTV, theft prevention and child applications, including commercial or home CCTV, theft prevention and child

View File

@ -20,3 +20,38 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
On Debian GNU/Linux systems, the text of the GPL can be found in On Debian GNU/Linux systems, the text of the GPL can be found in
/usr/share/common-licenses/GPL. /usr/share/common-licenses/GPL.
/usr/share/zoneminder/api/lib/Cake/*:
Copyright:
Copyright (c) 2005-2013, Cake Software Foundation, Inc.
License:
CakePHP(tm) : The Rapid Development PHP Framework (http://cakephp.org)
The MIT License
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
Cake Software Foundation, Inc.
1785 E. Sahara Avenue,
Suite 490-204
Las Vegas, Nevada 89104,
United States of America.

View File

@ -3,4 +3,3 @@ var/lib/zm
var/cache/zoneminder/events var/cache/zoneminder/events
var/cache/zoneminder/images var/cache/zoneminder/images
var/cache/zoneminder/temp var/cache/zoneminder/temp
usr/share/zoneminder/db

View File

@ -23,12 +23,11 @@ command="$ZM_PATH_BIN/zmpkg.pl"
start() { start() {
echo -n "Starting $prog: " echo -n "Starting $prog: "
mkdir -p $RUNDIR && chown www-data:www-data $RUNDIR export TZ=:/etc/localtime
mkdir -p $TMPDIR && chown www-data:www-data $TMPDIR mkdir -p $RUNDIR $TMPDIR && chown www-data:www-data $RUNDIR $TMPDIR
$command start $command start
RETVAL=$? RETVAL=$?
[ $RETVAL = 0 ] && echo success [ $RETVAL = 0 ] && echo success || echo failure
[ $RETVAL != 0 ] && echo failure
echo echo
[ $RETVAL = 0 ] && touch /var/lock/zm [ $RETVAL = 0 ] && touch /var/lock/zm
return $RETVAL return $RETVAL
@ -51,8 +50,7 @@ stop() {
else else
$command stop $command stop
RETVAL=$? RETVAL=$?
[ $RETVAL = 0 ] && echo success [ $RETVAL = 0 ] && echo success || echo failure
[ $RETVAL != 0 ] && echo failure
echo echo
[ $RETVAL = 0 ] && rm -f /var/lock/zm [ $RETVAL = 0 ] && rm -f /var/lock/zm
fi fi

View File

@ -1,7 +1,8 @@
usr/bin usr/bin
usr/lib/cgi-bin usr/lib/zoneminder/cgi-bin
usr/share/man usr/share/man
usr/share/perl5/ZoneMinder usr/share/perl5/ZoneMinder
usr/share/perl5/ZoneMinder.pm usr/share/perl5/ZoneMinder.pm
usr/share/zoneminder usr/share/zoneminder/db
usr/share/zoneminder/www
etc/zm etc/zm

View File

@ -1,4 +1,3 @@
var/cache/zoneminder/events usr/share/zoneminder/events var/cache/zoneminder/events usr/share/zoneminder/events
var/cache/zoneminder/images usr/share/zoneminder/images var/cache/zoneminder/images usr/share/zoneminder/images
var/cache/zoneminder/temp usr/share/zoneminder/temp var/cache/zoneminder/temp usr/share/zoneminder/temp
usr/lib/cgi-bin usr/share/zoneminder/cgi-bin

View File

@ -3,6 +3,19 @@
set -e set -e
if [ "$1" = "configure" ]; then if [ "$1" = "configure" ]; then
. /etc/zm/zm.conf
# The logs can contain passwords, etc... so by setting group root, only www-data can read them, not people in the www-data group.
chown www-data:root /var/log/zm
chown www-data:www-data /var/lib/zm
if [ -z "$2" ]; then
chown www-data:www-data /var/cache/zoneminder /var/cache/zoneminder/*
fi
# Do this every time the package is installed or upgraded
if [ "$ZM_DB_HOST" = "localhost" ]; then
if [ -e "/etc/init.d/mysql" ]; then if [ -e "/etc/init.d/mysql" ]; then
# #
# Get mysql started if it isn't # Get mysql started if it isn't
@ -15,39 +28,26 @@ if [ "$1" = "configure" ]; then
# test if database if already present... # test if database if already present...
if ! $(echo quit | mysql --defaults-file=/etc/mysql/debian.cnf zm > /dev/null 2> /dev/null) ; then if ! $(echo quit | mysql --defaults-file=/etc/mysql/debian.cnf zm > /dev/null 2> /dev/null) ; then
cat /usr/share/zoneminder/db/zm_create.sql | mysql --defaults-file=/etc/mysql/debian.cnf cat /usr/share/zoneminder/db/zm_create.sql | mysql --defaults-file=/etc/mysql/debian.cnf
echo 'grant lock tables, alter,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql # This creates the user.
echo "grant lock tables, alter,select,insert,update,delete,create,index on ${ZM_DB_NAME}.* to '${ZM_DB_USER}'@localhost identified by \"${ZM_DB_PASS}\";" | mysql --defaults-file=/etc/mysql/debian.cnf mysql
else
echo "grant lock tables, alter,select,insert,update,delete,create,index on ${ZM_DB_NAME}.* to '${ZM_DB_USER}'@localhost;" | mysql --defaults-file=/etc/mysql/debian.cnf mysql
fi fi
# Ensure zoneminder is stopped
invoke-rc.d zoneminder stop || true invoke-rc.d zoneminder stop || true
zmupdate.pl --nointeractive zmupdate.pl --nointeractive
zmupdate.pl --nointeractive -f
invoke-rc.d zoneminder start || true
else else
echo 'NOTE: mysql not running, please start mysql and run dpkg-reconfigure zoneminder when it is running.' echo 'NOTE: mysql not running, please start mysql and run dpkg-reconfigure zoneminder when it is running.'
fi fi
else else
echo 'mysql not found, assuming remote server.' echo 'mysql not found, assuming remote server.'
fi fi
chown www-data:www-data /var/log/zm
chown www-data:www-data /var/lib/zm/
if [ -z "$2" ]; then
chown www-data:www-data -R /var/cache/zoneminder
fi
fi
# Ensure zoneminder is stopped...
if [ -x "/etc/init.d/zoneminder" ]; then
if invoke-rc.d zoneminder status ; then
invoke-rc.d zoneminder stop || exit $?
fi
fi
if [ "$1" = "configure" ]; then
if [ -z "$2" ]; then
chown www-data:www-data /var/log/zm
chown www-data:www-data /var/lib/zm/
chown www-data:www-data -R /var/cache/zoneminder
else else
chown www-data:www-data /var/log/zm echo "Not doing database upgrade due to remote db server ($ZM_DB_HOST)"
zmupdate.pl
fi fi
fi fi
#DEBHELPER# #DEBHELPER#

View File

@ -1,9 +1,11 @@
#! /bin/sh #! /bin/sh
# set -e # to be reinstated later set -e
if [ "$1" = "purge" ]; then if [ "$1" = "purge" ]; then
if [ -e "/etc/init.d/mysql" ]; then
echo 'delete from user where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql echo 'delete from user where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
echo 'delete from db where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql echo 'delete from db where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
mysqladmin --defaults-file=/etc/mysql/debian.cnf -f drop zm mysqladmin --defaults-file=/etc/mysql/debian.cnf -f drop zm
fi
fi fi
#DEBHELPER# #DEBHELPER#

0
distros/debian/preinst Executable file → Normal file
View File

View File

@ -1,71 +1,41 @@
#!/usr/bin/make -f #!/usr/bin/make -f
# -*- makefile -*- # -*- makefile -*-
# Sample debian/rules that uses debhelper.
# This file was originally written by Joey Hess and Craig Small.
# As a special exception, when this file is copied by dh-make into a
# dh-make output file, you may use that output file without restriction.
# This special exception was added by Craig Small in version 0.37 of dh-make.
# Uncomment this to turn on verbose mode. # Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1 #export DH_VERBOSE=1
# These are used for cross-compiling and for saving the configure script export CFLAGS = -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -pipe
# from having to guess our platform (since we know it already) export CXXFLAGS = -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -pipe
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) INSTDIR = debian/tmp
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
CFLAGS = -Wall -g
CPPFLAGS = -D__STDC_CONSTANT_MACROS
CXXFLAGS = -DHAVE_LIBCRYPTO
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
else
CFLAGS += -O2
endif
%:
dh $@ --with autoreconf
override_dh_auto_configure: override_dh_auto_configure:
CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --sysconfdir=/etc/zm --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info --with-mysql=/usr --with-mariadb=/usr --with-webdir=/usr/share/zoneminder --with-ffmpeg=/usr --with-cgidir=/usr/lib/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-crashtrace=no --enable-mmap=yes dh_auto_configure -- \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_SKIP_RPATH=ON \
-DCMAKE_VERBOSE_MAKEFILE=OFF \
-DCMAKE_COLOR_MAKEFILE=ON \
-DZM_RUNDIR=/var/run/zm \
-DZM_SOCKDIR=/var/run/zm \
-DZM_TMPDIR=/var/tmp/zm \
-DZM_LOGDIR=/var/log/zm \
-DZM_WEBDIR=/usr/share/zoneminder/www \
-DZM_CONTENTDIR=/var/cache/zoneminder \
-DZM_CGIDIR=/usr/lib/zoneminder/cgi-bin \
-DZM_WEB_USER=www-data \
-DZM_WEB_GROUP=www-data \
-DCMAKE_INSTALL_SYSCONFDIR=etc/zm
override_dh_clean: override_dh_auto_install:
# Add here commands to clean up after the build process. dh_auto_install --buildsystem=cmake
[ ! -f Makefile ] || $(MAKE) distclean install -D -m 0644 debian/apache.conf $(INSTDIR)/etc/zm/apache.conf
dh_clean rm $(INSTDIR)/usr/share/zoneminder/api/lib/Cake/LICENSE.txt
rm $(INSTDIR)/usr/share/zoneminder/api/.gitignore
override_dh_install: rm -r $(INSTDIR)/usr/share/zoneminder/api/lib/Cake/Test
# Add here commands to install the package into debian/zm.
$(MAKE) install DESTDIR=$(CURDIR)/debian/zoneminder RUNDIR=$(CURDIR)/debian/zoneminder/var/run ZM_RUNDIR=$(CURDIR)/debian/zoneminder/var/run
install -D -m 0644 db/zm_create.sql $(CURDIR)/debian/zoneminder/usr/share/zoneminder/db
install -D -m 0644 db/zm_update-*.sql $(CURDIR)/debian/zoneminder/usr/share/zoneminder/db
install -D -m 0644 debian/apache.conf $(CURDIR)/debian/zoneminder/etc/zm
#
# NOTE: This is a short-term kludge; hopefully changes in the next
# upstream version will render this unnecessary.
rm -rf debian/zoneminder/usr/share/zoneminder/events
rm -rf debian/zoneminder/usr/share/zoneminder/images
rm -rf debian/zoneminder/usr/share/zoneminder/temp
ln -s /var/cache/zoneminder/events debian/zoneminder/usr/share/zoneminder/
ln -s /var/cache/zoneminder/images debian/zoneminder/usr/share/zoneminder/
ln -s /var/cache/zoneminder/temp debian/zoneminder/usr/share/zoneminder/
#
# This is a slightly lesser kludge; moving the cgi stuff to
# /usr/share/zoneminder/cgi-bin breaks one set of behavior,
# having it just in /usr/lib/cgi-bin breaks another bit of
# behavior.
#
ln -s /usr/lib/cgi-bin debian/zoneminder/usr/share/zoneminder/
override_dh_fixperms:
dh_fixperms
chown root:root debian/zoneminder/etc/zm/zm.conf
override_dh_auto_test: override_dh_auto_test:
# do not run tests... # do not run tests...
.PHONY: override_dh_strip
override_dh_strip: override_dh_strip:
dh_strip --dbg-package=zoneminder-dbg dh_strip --dbg-package=zoneminder-dbg
%:
dh $@ --buildsystem=cmake --parallel

View File

@ -1,29 +0,0 @@
zoneminder (1.28.0-0.1) wheezy; urgency=low
* Use CMake instead of Autotools to simplify
debian/rules and have less build-depends.
* Some lintian love in debian/{control,copyright}
and perl ZoneMinder modules.
* Don't purge database if we use a remote
MySQL server.
-- Cosme Domínguez Díaz <cosme.ddiaz@gmail.com> Sun, 09 Nov 2014 02:20:20 +0100
zoneminder (1.28.0-wheezy) wheezy; urgency=medium
* Release
-- Isaac Connor <iconnor@connortechnology.com> Fri, 17 Oct 2014 09:27:22 -0400
zoneminder (1.27.99+1-testing-SNAPSHOT2014072901) testing; urgency=medium
* improve error messages
* Make zmupdate re-run the most recent patch so that people running the daily builds get their db updates
-- Isaac Connor <iconnor@connortechnology.com> Tue, 29 Jul 2014 14:50:20 -0400
zoneminder (1.27.0+1-testing-v4ltomonitor-1) testing; urgency=high
* Snapshot release -
-- Isaac Connor <iconnor@connortechnology.com> Wed, 09 Jul 2014 21:35:29 -0400

View File

@ -1,40 +0,0 @@
Source: zoneminder
Section: net
Priority: optional
Maintainer: Isaac Connor <iconnor@connortechnology.com>
Build-Depends: debhelper (>= 9), cmake, libphp-serialization-perl, libgnutls-dev, libmysqlclient-dev | libmariadbclient-dev, libdbd-mysql-perl, libdate-manip-perl, libwww-perl, libjpeg8-dev, libpcre3-dev, libavcodec-dev, libavformat-dev (>= 3:0.svn20090204), libswscale-dev (>= 3:0.svn20090204), libavutil-dev, libv4l-dev (>= 0.8.3), libbz2-dev, libsys-mmap-perl, libav-tools, libnetpbm10-dev, libavdevice-dev, libdevice-serialport-perl, libarchive-zip-perl, libmime-lite-perl, libvlccore-dev, libvlc-dev, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev, libgcrypt11-dev, libpolkit-gobject-1-dev
Standards-Version: 3.9.4
Package: zoneminder
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, apache2 | httpd, libapache2-mod-php5 | libapache2-mod-fcgid | php5-fpm, php5-mysqlnd | php5-mysql, libphp-serialization-perl, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl, mariadb-client | mysql-client, libwww-perl, libarchive-tar-perl, libarchive-zip-perl, libdevice-serialport-perl, libpcre3, libav-tools, rsyslog | system-log-daemon, libmodule-load-perl, libsys-mmap-perl, libjson-any-perl, netpbm, libavdevice53, libjpeg8, zip, libnet-sftp-foreign-perl, libio-pty-perl, libexpect-perl, libvlccore5 | libvlccore7, libvlc5, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev, libpolkit-gobject-1-0
Recommends: mysql-server | mariadb-server
Description: Video camera security and surveillance solution
ZoneMinder is intended for use in single or multi-camera video security
applications, including commercial or home CCTV, theft prevention and child
or family member or home monitoring and other care scenarios. It
supports capture, analysis, recording, and monitoring of video data coming
from one or more video or network cameras attached to a Linux system.
ZoneMinder also support web and semi-automatic control of Pan/Tilt/Zoom
cameras using a variety of protocols. It is suitable for use as a home
video security system and for commercial or professional video security
and surveillance. It can also be integrated into a home automation system
via X.10 or other protocols.
Package: zoneminder-dbg
Architecture: any
Priority: extra
Section: debug
Depends: zoneminder (= ${binary:Version}), ${misc:Depends}
Description: debugging syumbols for zoneminder.
ZoneMinder is a video camera security and surveillance solution.
ZoneMinder is intended for use in single or multi-camera video security
applications, including commercial or home CCTV, theft prevention and child
or family member or home monitoring and other care scenarios. It
supports capture, analysis, recording, and monitoring of video data coming
from one or more video or network cameras attached to a Linux system.
ZoneMinder also support web and semi-automatic control of Pan/Tilt/Zoom
cameras using a variety of protocols. It is suitable for use as a home
video security system and for commercial or professional video security
and surveillance. It can also be integrated into a home automation system
via X.10 or other protocols.

View File

@ -1,57 +0,0 @@
Copyright:
Copyright 2002 Philip Coombes <philip.coombes@zoneminder.com>
License:
This package is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This package is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public
License along with this package; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
On Debian GNU/Linux systems, the text of the GPL can be found in
/usr/share/common-licenses/GPL.
/usr/share/zoneminder/api/lib/Cake/*:
Copyright:
Copyright (c) 2005-2013, Cake Software Foundation, Inc.
License:
CakePHP(tm) : The Rapid Development PHP Framework (http://cakephp.org)
The MIT License
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
Cake Software Foundation, Inc.
1785 E. Sahara Avenue,
Suite 490-204
Las Vegas, Nevada 89104,
United States of America.

View File

@ -1,7 +0,0 @@
usr/bin
usr/lib/cgi-bin
usr/share/man
usr/share/perl5/ZoneMinder
usr/share/perl5/ZoneMinder.pm
usr/share/zoneminder
etc/zm

View File

@ -1,4 +0,0 @@
var/cache/zoneminder/events usr/share/zoneminder/events
var/cache/zoneminder/images usr/share/zoneminder/images
var/cache/zoneminder/temp usr/share/zoneminder/temp
usr/lib/cgi-bin usr/share/zoneminder/cgi-bin

View File

@ -1,53 +0,0 @@
#! /bin/sh
set -e
if [ "$1" = "configure" ]; then
if [ -e "/etc/init.d/mysql" ]; then
#
# Get mysql started if it isn't
#
if ! $(/etc/init.d/mysql status >/dev/null 2>&1); then
invoke-rc.d mysql start
fi
if $(/etc/init.d/mysql status >/dev/null 2>&1); then
mysqladmin --defaults-file=/etc/mysql/debian.cnf -f reload
# test if database if already present...
if ! $(echo quit | mysql --defaults-file=/etc/mysql/debian.cnf zm > /dev/null 2> /dev/null) ; then
cat /usr/share/zoneminder/db/zm_create.sql | mysql --defaults-file=/etc/mysql/debian.cnf
echo 'grant lock tables, alter,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
fi
invoke-rc.d zoneminder stop || true
zmupdate.pl --nointeractive
else
echo 'NOTE: mysql not running, please start mysql and run dpkg-reconfigure zoneminder when it is running.'
fi
else
echo 'mysql not found, assuming remote server.'
fi
chown www-data:www-data /var/log/zm
chown www-data:www-data /var/lib/zm/
if [ -z "$2" ]; then
chown www-data:www-data -R /var/cache/zoneminder
fi
fi
# Ensure zoneminder is stopped...
if [ -x "/etc/init.d/zoneminder" ]; then
if invoke-rc.d zoneminder status ; then
invoke-rc.d zoneminder stop || exit $?
fi
fi
if [ "$1" = "configure" ]; then
if [ -z "$2" ]; then
chown www-data:www-data /var/log/zm
chown www-data:www-data /var/lib/zm/
chown www-data:www-data -R /var/cache/zoneminder
else
chown www-data:www-data /var/log/zm
zmupdate.pl
fi
fi
#DEBHELPER#

View File

@ -1,11 +0,0 @@
#! /bin/sh
set -e
if [ "$1" = "purge" ]; then
if [ -e "/etc/init.d/mysql" ]; then
echo 'delete from user where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
echo 'delete from db where User="zmuser";' | mysql --defaults-file=/etc/mysql/debian.cnf mysql
mysqladmin --defaults-file=/etc/mysql/debian.cnf -f drop zm
fi
fi
#DEBHELPER#

View File

@ -1,42 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
export CFLAGS = -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -pipe
export CXXFLAGS = -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -pipe
INSTDIR = debian/tmp
override_dh_auto_configure:
dh_auto_configure -- \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_SKIP_RPATH=ON \
-DCMAKE_VERBOSE_MAKEFILE=OFF \
-DCMAKE_COLOR_MAKEFILE=ON \
-DZM_RUNDIR=/var/run/zm \
-DZM_SOCKDIR=/var/run/zm \
-DZM_TMPDIR=/var/tmp/zm \
-DZM_LOGDIR=/var/log/zm \
-DZM_WEBDIR=/usr/share/zoneminder \
-DZM_CONTENTDIR=/var/cache/zoneminder \
-DZM_CGIDIR=/usr/lib/cgi-bin \
-DZM_WEB_USER=www-data \
-DZM_WEB_GROUP=www-data \
-DZM_PERL_SUBPREFIX=/share/perl5 \
-DCMAKE_INSTALL_SYSCONFDIR=etc/zm
override_dh_auto_install:
dh_auto_install --buildsystem=cmake
install -D -m 0644 debian/apache.conf $(INSTDIR)/etc/zm/apache.conf
rm $(INSTDIR)/usr/share/zoneminder/api/lib/Cake/LICENSE.txt
rm $(INSTDIR)/usr/share/zoneminder/api/.gitignore
rm -r $(INSTDIR)/usr/share/zoneminder/api/lib/Cake/Test
override_dh_auto_test:
# do not run tests...
override_dh_strip:
dh_strip --dbg-package=zoneminder-dbg
%:
dh $@ --buildsystem=cmake --parallel

View File

@ -1,3 +0,0 @@
version=3
http://www.zoneminder.com/downloads.html \
.*/ZoneMinder-(.*).tar.gz

View File

@ -1,7 +1,16 @@
# CMakeLists.txt for the Fedora Target Distro. # CMakeLists.txt for the Fedora Target Distro.
# Display a message to show the Fedora build options are being processed.
message([STATUS] "Starting Fedora Build Options" ...)
# Create the ZoneMinder Apache config file
configure_file(zoneminder.service.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.service @ONLY)
configure_file(zoneminder.conf.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.conf @ONLY)
configure_file(zoneminder.tmpfiles.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.tmpfiles @ONLY)
configure_file(zoneminder.logrotate.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.logrotate @ONLY)
# Download jscalendar & move files into position # Download jscalendar & move files into position
file(DOWNLOAD http://downloads.sourceforge.net/jscalendar/jscalendar-1.0.zip ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar-1.0.zip STATUS download_jsc) file(DOWNLOAD http://iweb.dl.sourceforge.net/project/jscalendar/jscalendar/1.0/jscalendar-1.0.zip ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar-1.0.zip STATUS download_jsc)
if(download_jsc EQUAL 0) if(download_jsc EQUAL 0)
message(STATUS "Jscalander successfully downloaded. Installing...") message(STATUS "Jscalander successfully downloaded. Installing...")
execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE unzip_jsc) execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE unzip_jsc)
@ -25,14 +34,15 @@ install(DIRECTORY events images temp DESTINATION /var/lib/zoneminder DIRECTORY_P
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/events \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/events\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/events \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/events\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/images \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/images\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/images \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/images\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/temp\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/temp\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/api/app/tmp\")")
# Fedora requires cambozola as a separate package so just link to it # Fedora requires cambozola as a separate package so just link to it
install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")") install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")")
# Install auxillary files required to run zoneminder on Fedora # Install auxiliary files required to run zoneminder on Fedora
install(FILES zoneminder.conf DESTINATION /etc/httpd/conf.d PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(FILES zoneminder.conf DESTINATION /etc/httpd/conf.d PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(FILES zoneminder.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.tmpfiles DESTINATION /etc/tmpfiles.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) install(FILES ../../misc/zoneminder-tmpfiles.conf DESTINATION /etc/tmpfiles.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES redalert.wav DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/sounds PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) install(FILES redalert.wav DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/sounds PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
install(FILES zoneminder.service DESTINATION /usr/lib/systemd/system PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(FILES zoneminder.service DESTINATION /usr/lib/systemd/system PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)

View File

@ -1,113 +1,150 @@
What's New
==========
1. The Apache ScriptAlias has been changed from "/cgi-bin/zm/zms" to
"/cgi-bin-zm/zms". This has been to done to avoid this bug:
https://bugzilla.redhat.com/show_bug.cgi?id=973067
IMPORTANT: You must manually inspect the value for PATH_ZMS under Options
and verify it is set to "/cgi-bin-zm/nph-zms". Failure to do so will result
in a broken system. You have been warned.
2. Due to the active state of the ZoneMinder project, we now recommend granting
ALL permission to the ZoneMinder mysql account. This change must be done
manually before ZoneMinder will run. See the installation steps below.
3. This package uses the HTTPS protocol by default to access the web portal.
Requests using HTTP will auto-redirect to HTTPS. See README.https for
more information.
4. This package ships with the new ZoneMinder API enabled.
New installs New installs
============ ============
1. Unless you are already using the MySQL server or you are running it 1. This package supports either community-mysql-server or mariadb-server with
remotely you will need to ensure that the server is installed and secured: mariadb being the preferred choice. Unless you are already using MariaDB or
Mysql server, you need to ensure that the server is configured to start
sudo yum install community-mysql-server during boot and properly secured by running:
sudo systemctl enable mysqld
sudo systemctl start mysqld.service
sudo yum install mariadb-server
sudo systemctl enable mariadb
sudo systemctl start mariadb.service
mysql_secure_installation mysql_secure_installation
NOTE: The Fedora team currently recommends mysql-community over mariadb 2. Assuming the database is local and using the password for the root account
set during the previous step, you will need to create the ZoneMinder
2. Using the password for the root account set during the previous step, you database and configure a database account for ZoneMinder to use:
will need to create the ZoneMinder database, assuming your database server
is local:
mysql -uroot -p < /usr/share/zoneminder/db/zm_create.sql mysql -uroot -p < /usr/share/zoneminder/db/zm_create.sql
mysql -uroot -p -e "grant all on zm.* to \
'zmuser'@localhost identified by 'zmpass';"
mysqladmin -uroot -p reload mysqladmin -uroot -p reload
3. The database needs a user. One is not created by default because this would The database account credentials, zmuser/zmpass, are arbitrary. Set them to
introduce an obvious security issue. The following should set this up: anything that suits your environment.
mysql -u root -p 3. If you have chosen to change the zoneminder database account credentials to
grant select,insert,update,delete,lock tables,alter on zm.* to something other than zmuser/zmpass, you must now edit /etc/zm/zm.conf.
'zmuser'@localhost identified by 'zmpass'; Change ZM_DB_USER and ZM_DB_PASS to the values you created in the previous
step.
Obviously, change at least zmpass to an actual, secure password or This version of zoneminder no longer requires you to make a similar change
passphrase. You can change zmuser as well if you like. to the credentials in /usr/share/zoneminder/www/api/app/Config/database.php
This now happens dynamically. Do *not* make any changes to this file.
4. Edit /etc/zm.conf and, at the bottom, change ZM_DB_PASS and perhaps 4. Edit /etc/php.ini, uncomment the date.timezone line, and add your local
ZM_DB_USER to match. timezone. PHP will complain loudly if this is not set, or if it is set
incorrectly, and these complaints will show up in the zoneminder logging
5. Edit /etc/php.ini, uncomment the date.timezone line, and add your local system as errors.
timezone. For whatever reason, PHP will complain loudly if this is not set,
or if it is set incorrectly, and these complaints will show up in the
zoneminder logging system as errors.
If you are not sure of the proper timezone specification to use, look at If you are not sure of the proper timezone specification to use, look at
http://php.net/date.timezone http://php.net/date.timezone
6. This package probably does not work with SELinux enabled at the moment. It 5. Disable SELinux
may be necessary to disable SELinux for httpd, or even completely for
ZoneMinder to function. This will be addressed in a later release. Run We currently do not have the resources to create and maintain an accurate
SELinux policy for ZoneMinder on Fedora. We will gladly accept pull
reqeusts from anyone who wishes to do the work. In the meantime, SELinux
will need to be disabled or put into permissive mode.
To immediately disbale SELinux for the current seesion, issue the following
from the command line:
sudo setenforce 0 sudo setenforce 0
for testing, and edit /etc/sysconfig/selinux to disable it at boot time. To permanently disable SELinux, edit /etc/selinux/config and change the
SELINUX line from "enforcing" to "disabled". This change will take
effect after a reboot.
7. IMPORTANT: Edit /etc/httpd/conf.d/zoneminder.conf and/or 6. Install mod_ssl or configure /etc/httpd/conf.d/zoneminder.conf to meet your
/etc/httpd/conf/httpd.conf. needs. This package comes preconfigured for HTTPS using the default self
signed certificate on your system. The recommended way to complete this step
is to simply install mod_ssl:
The httpd.conf file included with this version of Fedora processes the conf.d sudo yum install mod_ssl
folder after the default ScriptAlias directive in the httpd.conf file.
Previously, the conf.d folder was processed before the default ScriptAlias
directive. This causes a ScriptAlias overlap and breaks Zoneminder's
streaming abilities.
Reference: http://httpd.apache.org/docs/2.4/mod/mod_alias.html#order If this does not meet your needs, then read README.https to
Bug Report: https://bugzilla.redhat.com/show_bug.cgi?id=973067 learn about alternatives. When in doubt, install mod_ssl.
WORKAROUND #1 7. Now start the web server:
If you are running zoneminder on a dedicated server then the simplest
solution may be to simply comment out the line in httpd.conf that reads:
ScriptAlias /cgi-bin/ "/var/www/cgi-bin/" sudo systemctl enable httpd
sudo systemctl start httpd
WORKAROUND #2 8. Now start zoneminder:
If you need both the default cgi-bin folder & the zoneminder cgi-bin folder
then a solution might be to move the following line before the default
ScriptAlias directive in the httpd.conf file:
IncludeOptional conf.d/*.conf sudo systemctl enable zoneminder
sudo systemctl start zoneminder
8. Now start the web server:
sudo systemctl enable httpd.service
sudo systemctl start httpd.service
9. Now start zoneminder:
sudo systemctl enable zoneminder.service
sudo systemctl start zoneminder.service
Upgrades Upgrades
======== ========
1. Update /etc/zm.conf. Check for any new settings and update the version 1. Verify /etc/zm/zm.conf.
information. Comparing /etc/zm.conf and /etc/zm.conf.rpmnew should help to
do this.
2. Add additional permissions to the zmuser account: If zm.conf was manually edited before running the upgrade, the installation
may not overwrite it. In this case, it will create the file
/etc/zm/zm.conf.rpmnew.
mysql -u root -p For example, this will happen if you are using database account credentials
grant lock tables,alter on zm.* to other than zmuser/zmpass.
'zmuser'@localhost identified by 'zmpass';
Since this is an upgrade, the assumption is that the zmuser account already Compare /etc/zm/zm.conf to /etc/zm/zm.conf.rpmnew. Verify that zm.conf
has select, insert, update, and delete permission. contains any new config settings that may be in zm.conf.rpmnew.
3. You will need to upgrade the ZoneMinder database as described in the This version of zoneminder no longer requires you to make a similar change
manual. Only if the previous step was succesful, may you run zmupdate like to the credentials in /usr/share/zoneminder/www/api/app/Config/database.php
so: This now happens dynamically. Do *not* make any changes to this file.
sudo zmupdate.pl --version=<from version> 2. Verify permissions of the zmuser account.
Over time, the database account permissions required for normal operation
have increased. Verify the zmuser database account has been granted all
permission to the ZoneMinder database:
If unsure then run it this way: mysql -uroot -p -e "show grants for zmuser@localhost;"
See step 2 of the Installation section to add missing permissions.
3. Verify the ZoneMinder Apache configuration file in the folder
/etc/httpd/conf.d. You will have a file called "zoneminder.conf" and there
may also be a file called "zoneminder.conf.rpmnew". If the rpmnew file
exists, inspect it and merge anything new in that file with zoneminder.conf.
Verify the SSL REquirements meet your needs. Read README.https if necessary.
4. Upgrade the database before starting ZoneMinder.
Most upgrades can be performed by executing the following command:
sudo zmupdate.pl
Recent versions of ZoneMinder don't require any parameters added to the
zmupdate command. However, if ZoneMinder complains, you may need to call
zmupdate in the following manner:
sudo zmupdate.pl --user=root --pass=<mysql_root_pwd> --version=<from version> sudo zmupdate.pl --user=root --pass=<mysql_root_pwd> --version=<from version>
5. Now start zoneminder:
sudo systemctl start zoneminder

1
distros/fedora/README.https Symbolic link
View File

@ -0,0 +1 @@
../redhat/README.https

View File

@ -72,7 +72,6 @@ too much degradation of performance.
%build %build
%cmake \ %cmake \
-DZM_TARGET_DISTRO="f19" \ -DZM_TARGET_DISTRO="f19" \
-DZM_PERL_SUBPREFIX=`x="%{perl_vendorlib}" ; echo ${x#"%{_prefix}"}` \
%{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \ %{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \
%{?_without_x10:-DZM_NO_X10=ON} \ %{?_without_x10:-DZM_NO_X10=ON} \
. .
@ -141,7 +140,6 @@ fi
# zmfix removed from zoneminder 1.26.6 # zmfix removed from zoneminder 1.26.6
#%attr(4755,root,root) %{_bindir}/zmfix #%attr(4755,root,root) %{_bindir}/zmfix
%{_bindir}/zmpkg.pl %{_bindir}/zmpkg.pl
%{_bindir}/zmstreamer
%{_bindir}/zmtrack.pl %{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl %{_bindir}/zmtrigger.pl
%{_bindir}/zmu %{_bindir}/zmu

View File

@ -32,7 +32,7 @@ Alias /zm "/usr/share/zoneminder/www"
ScriptAlias /cgi-bin/zm "/usr/libexec/zoneminder/cgi-bin" ScriptAlias /cgi-bin/zm "/usr/libexec/zoneminder/cgi-bin"
<Directory "/usr/libexec/zoneminder/cgi-bin"> <Directory "/usr/libexec/zoneminder/cgi-bin">
AllowOverride All AllowOverride All
Options ExecCGI Options +ExecCGI +FollowSymLinks
<IfModule mod_authz_core.c> <IfModule mod_authz_core.c>
# Apache 2.4 # Apache 2.4
Require all granted Require all granted

View File

@ -232,7 +232,6 @@ fi
# zmfix removed from zoneminder 1.26.6 # zmfix removed from zoneminder 1.26.6
#%attr(4755,root,root) %{_bindir}/zmfix #%attr(4755,root,root) %{_bindir}/zmfix
%{_bindir}/zmpkg.pl %{_bindir}/zmpkg.pl
%{_bindir}/zmstreamer
%{_bindir}/zmtrack.pl %{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl %{_bindir}/zmtrigger.pl
%{_bindir}/zmu %{_bindir}/zmu

View File

@ -10,7 +10,7 @@
%define _without_x10 1 %define _without_x10 1
Name: zoneminder Name: zoneminder
Version: 1.28.0 Version: 1.28.1
Release: 1%{?dist} Release: 1%{?dist}
Summary: A camera monitoring and analysis tool Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons Group: System Environment/Daemons
@ -22,25 +22,23 @@ URL: http://www.zoneminder.com/
#Source: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz #Source: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz
Source: ZoneMinder-%{version}.tar.gz Source: ZoneMinder-%{version}.tar.gz
Patch1: zoneminder-1.28.0-defaults.patch
BuildRequires: cmake gnutls-devel systemd-units bzip2-devel BuildRequires: cmake gnutls-devel systemd-units bzip2-devel
BuildRequires: community-mysql-devel pcre-devel libjpeg-turbo-devel BuildRequires: community-mysql-devel pcre-devel libjpeg-turbo-devel
BuildRequires: perl(Archive::Tar) perl(Archive::Zip) BuildRequires: perl(Archive::Tar) perl(Archive::Zip) perl-podlators
BuildRequires: perl(Date::Manip) perl(DBD::mysql) BuildRequires: perl(Date::Manip) perl(DBD::mysql)
BuildRequires: perl(ExtUtils::MakeMaker) perl(LWP::UserAgent) BuildRequires: perl(ExtUtils::MakeMaker) perl(LWP::UserAgent)
BuildRequires: perl(MIME::Entity) perl(MIME::Lite) BuildRequires: perl(MIME::Entity) perl(MIME::Lite)
BuildRequires: perl(PHP::Serialization) perl(Sys::Mmap) BuildRequires: perl(PHP::Serialization) perl(Sys::Mmap)
BuildRequires: perl(Time::HiRes) perl(Net::SFTP::Foreign) BuildRequires: perl(Time::HiRes) perl(Net::SFTP::Foreign)
BuildRequires: perl(Expect) perl(Sys::Syslog) BuildRequires: perl(Expect) perl(Sys::Syslog)
BuildRequires: gcc gcc-c++ vlc-devel libcurl-devel BuildRequires: gcc gcc-c++ vlc-devel libcurl-devel libv4l-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg-devel} %{!?_without_ffmpeg:BuildRequires: ffmpeg-devel}
%{!?_without_x10:BuildRequires: perl(X10::ActiveHome) perl(Astro::SunTime)} %{!?_without_x10:BuildRequires: perl(X10::ActiveHome) perl(Astro::SunTime)}
# cmake needs the following installed at build time due to the way it auto-detects certain parameters # cmake needs the following installed at build time due to the way it auto-detects certain parameters
BuildRequires: httpd polkit-devel BuildRequires: httpd polkit-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg} %{!?_without_ffmpeg:BuildRequires: ffmpeg}
Requires: httpd php php-mysql cambozola polkit Requires: httpd php php-gd php-mysql cambozola polkit net-tools psmisc
Requires: libjpeg-turbo vlc-core libcurl Requires: libjpeg-turbo vlc-core libcurl
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip) Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip)
@ -66,12 +64,18 @@ too much degradation of performance.
%prep %prep
%setup -q -n ZoneMinder-%{version} %setup -q -n ZoneMinder-%{version}
%patch1 -p0 -b .defaults # Change the following default values
./utils/zmeditconfigdata.sh ZM_PATH_ZMS /cgi-bin/zm/nph-zms
./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
./utils/zmeditconfigdata.sh ZM_PATH_SWAP /dev/shm
./utils/zmeditconfigdata.sh ZM_UPLOAD_FTP_LOC_DIR /var/spool/zoneminder-upload
./utils/zmeditconfigdata.sh ZM_OPT_CONTROL yes
./utils/zmeditconfigdata.sh ZM_CHECK_FOR_UPDATES no
./utils/zmeditconfigdata.sh ZM_DYN_SHOW_DONATE_REMINDER no
%build %build
%cmake \ %cmake \
-DZM_TARGET_DISTRO="f20" \ -DZM_TARGET_DISTRO="f20" \
-DZM_PERL_SUBPREFIX=`x="%{perl_vendorlib}" ; echo ${x#"%{_prefix}"}` \
%{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \ %{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \
%{?_without_x10:-DZM_NO_X10=ON} \ %{?_without_x10:-DZM_NO_X10=ON} \
. .
@ -138,7 +142,6 @@ fi
%{_bindir}/zmf %{_bindir}/zmf
%{_bindir}/zmfilter.pl %{_bindir}/zmfilter.pl
%{_bindir}/zmpkg.pl %{_bindir}/zmpkg.pl
%{_bindir}/zmstreamer
%{_bindir}/zmtrack.pl %{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl %{_bindir}/zmtrigger.pl
%{_bindir}/zmu %{_bindir}/zmu

View File

@ -0,0 +1,396 @@
%define zmuid $(id -un)
%define zmgid $(id -gn)
%define zmuid_final apache
%define zmgid_final apache
%global _hardened_build 1
### Delete the lines below to build with ffmpeg and/or x10
%define _without_ffmpeg 1
%define _without_x10 1
Name: zoneminder
Version: 1.28.1
Release: 1%{?dist}
Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons
# jscalendar is LGPL (any version): http://www.dynarch.com/projects/calendar/
# Mootools is inder the MIT license: http://mootools.net/
License: GPLv2+ and LGPLv2+ and MIT
URL: http://www.zoneminder.com/
#Source: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz
Source: ZoneMinder-%{version}.tar.gz
BuildRequires: cmake gnutls-devel systemd-units bzip2-devel
BuildRequires: community-mysql-devel pcre-devel libjpeg-turbo-devel
BuildRequires: perl(Archive::Tar) perl(Archive::Zip) perl-podlators
BuildRequires: perl(Date::Manip) perl(DBD::mysql)
BuildRequires: perl(ExtUtils::MakeMaker) perl(LWP::UserAgent)
BuildRequires: perl(MIME::Entity) perl(MIME::Lite)
BuildRequires: perl(PHP::Serialization) perl(Sys::Mmap)
BuildRequires: perl(Time::HiRes) perl(Net::SFTP::Foreign)
BuildRequires: perl(Expect) perl(Sys::Syslog)
BuildRequires: gcc gcc-c++ vlc-devel libcurl-devel libv4l-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg-devel}
%{!?_without_x10:BuildRequires: perl(X10::ActiveHome) perl(Astro::SunTime)}
# cmake needs the following installed at build time due to the way it auto-detects certain parameters
BuildRequires: httpd polkit-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg}
Requires: httpd php php-gd php-mysql cambozola polkit net-tools psmisc
Requires: libjpeg-turbo vlc-core libcurl
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip)
Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP)
Requires: perl(LWP::Protocol::https)
%{!?_without_ffmpeg:Requires: ffmpeg}
Requires(post): systemd-units systemd-sysv
Requires(post): /usr/bin/gpasswd
Requires(post): /usr/bin/less
Requires(preun): systemd-units
Requires(postun): systemd-units
%description
ZoneMinder is a set of applications which is intended to provide a complete
solution allowing you to capture, analyse, record and monitor any cameras you
have attached to a Linux based machine. It is designed to run on kernels which
support the Video For Linux (V4L) interface and has been tested with cameras
attached to BTTV cards, various USB cameras and IP network cameras. It is
designed to support as many cameras as you can attach to your computer without
too much degradation of performance.
%prep
%setup -q -n ZoneMinder-%{version}
# Change the following default values
./utils/zmeditconfigdata.sh ZM_PATH_ZMS /cgi-bin/zm/nph-zms
./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
./utils/zmeditconfigdata.sh ZM_PATH_SWAP /dev/shm
./utils/zmeditconfigdata.sh ZM_UPLOAD_FTP_LOC_DIR /var/spool/zoneminder-upload
./utils/zmeditconfigdata.sh ZM_OPT_CONTROL yes
./utils/zmeditconfigdata.sh ZM_CHECK_FOR_UPDATES no
./utils/zmeditconfigdata.sh ZM_DYN_SHOW_DONATE_REMINDER no
%build
%cmake \
-DZM_TARGET_DISTRO="f21" \
%{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \
%{?_without_x10:-DZM_NO_X10=ON} \
.
make %{?_smp_mflags}
%install
export DESTDIR=%{buildroot}
make install
%post
if [ $1 -eq 1 ] ; then
# Initial installation
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
# Allow zoneminder access to local video sources, serial ports, and x10
/usr/bin/gpasswd -a %{zmuid_final} video
/usr/bin/gpasswd -a %{zmuid_final} dialout
# Display the README for post installation instructions
/usr/bin/less %{_docdir}/%{name}/README.Fedora
%preun
if [ $1 -eq 0 ] ; then
# Package removal, not upgrade
/bin/systemctl --no-reload disable zoneminder.service > /dev/null 2>&1 || :
/bin/systemctl stop zoneminder.service > /dev/null 2>&1 || :
fi
%postun
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
if [ $1 -ge 1 ] ; then
# Package upgrade, not uninstall
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
fi
%triggerun -- zoneminder < 1.25.0-4
# Save the current service runlevel info
# User must manually run systemd-sysv-convert --apply zoneminder
# to migrate them to systemd targets
/usr/bin/systemd-sysv-convert --save zoneminder >/dev/null 2>&1 ||:
# Run these because the SysV package being removed won't do them
/sbin/chkconfig --del zoneminder >/dev/null 2>&1 || :
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
%files
%defattr(-,root,root,-)
%doc AUTHORS COPYING README.md distros/fedora/README.Fedora distros/fedora/jscalendar-doc
%config %attr(640,root,%{zmgid_final}) /etc/zm/zm.conf
%config(noreplace) %attr(644,root,root) /etc/httpd/conf.d/zoneminder.conf
%config(noreplace) /etc/tmpfiles.d/zoneminder.conf
%config(noreplace) /etc/logrotate.d/zoneminder
%{_unitdir}/zoneminder.service
%{_bindir}/zma
%{_bindir}/zmaudit.pl
%{_bindir}/zmc
%{_bindir}/zmcontrol.pl
%{_bindir}/zmdc.pl
%{_bindir}/zmf
%{_bindir}/zmfilter.pl
%{_bindir}/zmpkg.pl
%{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl
%{_bindir}/zmu
%{_bindir}/zmupdate.pl
%{_bindir}/zmvideo.pl
%{_bindir}/zmwatch.pl
%{_bindir}/zmcamtool.pl
%{_bindir}/zmsystemctl.pl
%{!?_without_x10:%{_bindir}/zmx10.pl}
%{perl_vendorlib}/ZoneMinder*
%{_mandir}/man*/*
%dir %{_libexecdir}/zoneminder
%{_libexecdir}/zoneminder/cgi-bin
%dir %{_datadir}/zoneminder
%{_datadir}/zoneminder/db
%{_datadir}/zoneminder/www
%{_datadir}/polkit-1/actions/com.zoneminder.systemctl.policy
%{_datadir}/polkit-1/rules.d/com.zoneminder.systemctl.rules
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/events
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/images
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/sock
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/swap
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/temp
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/log/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/spool/zoneminder-upload
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /run/zoneminder
%changelog
* Sat Feb 14 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Bump version for 1.28.1 release on Fedora 21.
* Sun Oct 5 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.0
- Bump version for 1.28.0 release.
* Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Tweak build requirements for cmake
* Sat Feb 01 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Add zmcamtool.pl. Bump version for 1.27 release.
* Mon Dec 16 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.5
- This is a bug fixe release
- RTSP fixes, cmake enhancements, couple other misc fixes
* Mon Oct 07 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Initial cmake build.
* Sat Oct 05 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Fedora specific path changes have been moved to zoneminder-1.26.0-defaults.patch
- All files are now part of the zoneminder source tree. Update specfile accordingly.
* Sat Sep 21 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.3
- Initial rebuild for ZoneMinder 1.26.3 release.
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Mon Jan 21 2013 Adam Tkac <atkac redhat com> - 1.25.0-12
- rebuild due to "jpeg8-ABI" feature drop
* Mon Jan 7 2013 Remi Collet <rcollet@redhat.com> - 1.25.0-11
- fix configuration file for httpd 2.4, #871502
* Fri Dec 21 2012 Adam Tkac <atkac redhat com> - 1.25.0-10
- rebuild against new libjpeg
* Thu Aug 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-9
- Add patch to work around v4l2 api breakage in 3.5 kernel.
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sat Jun 23 2012 Petr Pisar <ppisar@redhat.com> - 1.25.0-7
- Perl 5.16 rebuild
* Wed Mar 21 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-6
- Fix stupid thinko in sql modifications.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-5
- Clean up macro usage.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-4
- Convert to systemd.
- Add tmpfiles.d configuration since the initscript isn't around to create
/run/zoneminder.
- Remove some pointless executable permissions.
- Add logrotate file.
* Wed Feb 22 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-3
- Update README.Fedora to reference systemctl and mention timezone info in
php.ini.
- Add proper default for EYEZM_LOG_TO_FILE.
* Thu Feb 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-2
- Rebuild for new pcre.
* Thu Jan 19 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-1
- Update to 1.25.0
- Fix gcc4.7 build problems.
- Drop gcc4.4 build fixes; for whatever reason they now break the build.
- Clean up old patches.
- Force setting of ZM_TMPDIR and ZM_RUNDIR.
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.4-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-3
- Re-add the dist-tag that somehow got lost.
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-2
- Add patch for bug 711780 - fix syntax issue in Mapped.pm.
- Undo that patch, and undo another which was the cause of the whole mess.
- Fix up other patches so ZM_PATH_BUILD is both defined and useful.
- Make sure database creation mods actually take.
- Update Fedora-specific docs with some additional info.
- Use bundled mootools (javascript, so no guideline violation).
- Update download location.
- Update the gcrypt patch to actually work.
- Upstream changed the tarball without changing the version to patch a
vulnerability, so redownload.
* Sun Aug 14 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-1
- Initial attempt to upgrade to 1.24.4.
- Add patch from BZ 460310 to build against libgcrypt instead of requiring the
gnutls openssl libs.
* Thu Jul 21 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-7.20110324svn3310
- Perl mass rebuild
* Wed Jul 20 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-6.20110324svn3310
- Perl mass rebuild
* Mon May 09 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-5.20110324svn3310
- Bump for gnutls update.
* Thu Mar 24 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-4.20110324svn3310
- Update to latest 1.24.3 subversion. Turns out that what upstream was calling
1.24.3 is really just an occasionally updated devel snapshot.
- Rebase various patches.
* Wed Mar 23 2011 Dan Horák <dan@danny.cz> - 1.24.3-3
- rebuilt for mysql 5.5.10 (soname bump in libmysqlclient)
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Tue Jan 25 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-1
- Update to latest upstream version.
- Rebase patches.
- Initial incomplete attempt to disable v4l1 support.
* Fri Jan 21 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-6
- Unbundle cambozola; instead link to the separately pacakged copy.
- Remove BuildRoot:, %%clean and buildroot cleaning in %%install.
- Git rid of mixed space/tab usage by removing all tabs.
- Remove unnecessary Conflicts: line.
- Attempt to force short_open_tag on for the code directories.
- Move default location of sockets, swaps, logfiles and some temporary files to
make more sense and allow things to work better with a future selinux policy.
- Fix errors in README.Fedora.
* Wed Jun 02 2010 Marcela Maslanova <mmaslano@redhat.com> - 1.24.2-5
- Mass rebuild with perl-5.12.0
* Fri Dec 4 2009 Stepan Kasal <skasal@redhat.com> - 1.24.2-4
- rebuild against perl 5.10.1
- use Perl vendorarch and archlib variables correctly
* Mon Jul 27 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-2
- Bump release since 1.24.2-1 was mistakenly tagged a few months ago.
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-1
- Initial update to 1.24.2.
- Rebase patches.
- Update mootools download location.
- Update to mootools 1.2.3.
- Add additional dependencies for some optional features.
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-3
- Remove unused Sys::Mmap perl dependency RPM is finding
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-2
- Update gcc44 patch to disable -frepo, seems to be broken with gcc44
- Added noffmpeg patch to make building outside mock easier
* Sat Mar 21 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-1
- Patch for gcc 4.4 compilation errors
- Upgrade to 1.24.1
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.23.3-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Sat Jan 24 2009 Caolán McNamara <caolanm@redhat.com> - 1.23.3-3
- rebuild for dependencies
* Mon Dec 15 2008 Martin Ebourne <martin@zepler.org> - 1.23.3-2
- Fix permissions on zm.conf
* Fri Jul 11 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.23.3-1
- Initial attempt at packaging 1.23.
* Tue Jul 1 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-15
- Add perl module compat dependency, bz #453590
* Tue May 6 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-14
- Remove default runlevel, bz #441315
* Mon Apr 28 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.22.3-13
- Backport patch for CVE-2008-1381 from 1.23.3 to 1.22.3.
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.22.3-12
- Autorebuild for GCC 4.3
* Thu Jan 3 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-11
- Fix compilation on gcc 4.3
* Thu Dec 6 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-10
- Rebuild for new openssl
* Thu Aug 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-8
- Fix licence tag
* Thu Jul 12 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-7
- Fixes from testing by Jitz including missing dependencies and database creation
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-6
- Disable crashtrace on ppc
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-5
- Fix uid for directories in /var/lib/zoneminder
* Tue Jun 26 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-4
- Added perl Archive::Tar dependency
- Disabled web interface due to lack of access control on the event images
* Sun Jun 10 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-3
- Changes recommended in review by Jason Tibbitts
* Mon Apr 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-2
- Standardised on package name of zoneminder
* Thu Dec 28 2006 Martin Ebourne <martin@zepler.org> - 1.22.3-1
- First version. Uses some parts from zm-1.20.1 by Corey DeLasaux and Serg Oskin

View File

@ -1 +0,0 @@
../redhat/redalert.wav

1
distros/fedora/redalert.wav Symbolic link
View File

@ -0,0 +1 @@
../redhat/redalert.wav

View File

@ -0,0 +1 @@
../redhat/zoneminder.el7.conf.in

View File

@ -0,0 +1 @@
zoneminder.f23.spec

View File

@ -0,0 +1,429 @@
%define zmuid $(id -un)
%define zmgid $(id -gn)
%define zmuid_final apache
%define zmgid_final apache
%global _hardened_build 1
### Delete the lines below to build with ffmpeg and/or x10
%define _without_ffmpeg 1
%define _without_x10 1
Name: zoneminder
Version: 1.30.0
Release: 1%{?dist}
Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons
# jscalendar is LGPL (any version): http://www.dynarch.com/projects/calendar/
# Mootools is inder the MIT license: http://mootools.net/
License: GPLv2+ and LGPLv2+ and MIT
URL: http://www.zoneminder.com/
#Source: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz
Source: ZoneMinder-%{version}.tar.gz
BuildRequires: cmake gnutls-devel systemd-units bzip2-devel
BuildRequires: mariadb-devel pcre-devel libjpeg-turbo-devel
BuildRequires: perl(Archive::Tar) perl(Archive::Zip) perl-podlators
BuildRequires: perl(Date::Manip) perl(DBD::mysql)
BuildRequires: perl(ExtUtils::MakeMaker) perl(LWP::UserAgent)
BuildRequires: perl(MIME::Entity) perl(MIME::Lite)
BuildRequires: perl(PHP::Serialization) perl(Sys::Mmap)
BuildRequires: perl(Time::HiRes) perl(Net::SFTP::Foreign)
BuildRequires: perl(Expect) perl(Sys::Syslog)
BuildRequires: gcc gcc-c++ vlc-devel libcurl-devel libv4l-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg-devel}
%{!?_without_x10:BuildRequires: perl(X10::ActiveHome) perl(Astro::SunTime)}
# cmake needs the following installed at build time due to the way it auto-detects certain parameters
BuildRequires: httpd polkit-devel
%{!?_without_ffmpeg:BuildRequires: ffmpeg}
Requires: httpd php php-gd php-mysql cambozola polkit net-tools psmisc
Requires: libjpeg-turbo vlc-core libcurl
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip)
Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP)
Requires: perl(LWP::Protocol::https)
%{!?_without_ffmpeg:Requires: ffmpeg}
Requires(post): systemd-units systemd-sysv
Requires(post): /usr/bin/gpasswd
Requires(post): /usr/bin/less
Requires(preun): systemd-units
Requires(postun): systemd-units
%description
ZoneMinder is a set of applications which is intended to provide a complete
solution allowing you to capture, analyse, record and monitor any cameras you
have attached to a Linux based machine. It is designed to run on kernels which
support the Video For Linux (V4L) interface and has been tested with cameras
attached to BTTV cards, various USB cameras and IP network cameras. It is
designed to support as many cameras as you can attach to your computer without
too much degradation of performance.
%prep
%setup -q -n ZoneMinder-%{version}
# Change the following default values
./utils/zmeditconfigdata.sh ZM_PATH_ZMS /cgi-bin-zm/nph-zms
./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
./utils/zmeditconfigdata.sh ZM_PATH_SWAP /dev/shm
./utils/zmeditconfigdata.sh ZM_UPLOAD_FTP_LOC_DIR /var/spool/zoneminder-upload
./utils/zmeditconfigdata.sh ZM_OPT_CONTROL yes
./utils/zmeditconfigdata.sh ZM_CHECK_FOR_UPDATES no
./utils/zmeditconfigdata.sh ZM_DYN_SHOW_DONATE_REMINDER no
./utils/zmeditconfigdata.sh ZM_OPT_FAST_DELETE no
%build
%cmake \
-DZM_TARGET_DISTRO="f23" \
%{?_without_ffmpeg:-DZM_NO_FFMPEG=ON} \
%{?_without_x10:-DZM_NO_X10=ON} \
.
make %{?_smp_mflags}
%install
export DESTDIR=%{buildroot}
make install
%post
# Add any new PTZ control configurations to the database (will not overwrite)
%{_bindir}/zmcamtool.pl --import >/dev/null 2>&1 || :
if [ $1 -eq 1 ] ; then
# Initial installation
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
# Allow zoneminder access to local video sources, serial ports, and x10
/usr/bin/gpasswd -a %{zmuid_final} video
/usr/bin/gpasswd -a %{zmuid_final} dialout
# Upgrade from a previous version of zoneminder
if [ $1 -eq 2 ] ; then
# Add any new PTZ control configurations to the database (will not overwrite)
%{_bindir}/zmcamtool.pl --import >/dev/null 2>&1 || :
# Freshen the database
%{_bindir}/zmupdate.pl -f >/dev/null 2>&1 || :
# We can't run this automatically when new sql account permissions need to
# be manually added first
# Run zmupdate non-interactively
#/usr/bin/zmupdate.pl --nointeractive
fi
# Warn the end user to read the README file
echo -e "\nVERY IMPORTANT: Before starting ZoneMinder, read README.Fedora to finish the\ninstallation or upgrade!\n"
echo -e "\nThe README file is located here: %{_docdir}/%{name}\n"
%preun
if [ $1 -eq 0 ] ; then
# Package removal, not upgrade
/bin/systemctl --no-reload disable zoneminder.service > /dev/null 2>&1 || :
/bin/systemctl stop zoneminder.service > /dev/null 2>&1 || :
fi
%postun
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
if [ $1 -ge 1 ] ; then
# Package upgrade, not uninstall
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
fi
%triggerun -- zoneminder < 1.25.0-4
# Save the current service runlevel info
# User must manually run systemd-sysv-convert --apply zoneminder
# to migrate them to systemd targets
/usr/bin/systemd-sysv-convert --save zoneminder >/dev/null 2>&1 ||:
# Run these because the SysV package being removed won't do them
/sbin/chkconfig --del zoneminder >/dev/null 2>&1 || :
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
%files
%defattr(-,root,root,-)
%doc AUTHORS COPYING README.md distros/fedora/README.Fedora distros/fedora/README.https distros/fedora/jscalendar-doc
%config %attr(640,root,%{zmgid_final}) /etc/zm/zm.conf
%config(noreplace) %attr(644,root,root) /etc/httpd/conf.d/zoneminder.conf
%config(noreplace) /etc/tmpfiles.d/zoneminder.conf
%config(noreplace) /etc/logrotate.d/zoneminder
%{_unitdir}/zoneminder.service
%{_bindir}/zma
%{_bindir}/zmaudit.pl
%{_bindir}/zmc
%{_bindir}/zmcontrol.pl
%{_bindir}/zmdc.pl
%{_bindir}/zmf
%{_bindir}/zmfilter.pl
%{_bindir}/zmpkg.pl
%{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl
%{_bindir}/zmu
%{_bindir}/zmupdate.pl
%{_bindir}/zmvideo.pl
%{_bindir}/zmwatch.pl
%{_bindir}/zmcamtool.pl
%{_bindir}/zmsystemctl.pl
%{_bindir}/zmtelemetry.pl
%{!?_without_x10:%{_bindir}/zmx10.pl}
%{_bindir}/zmonvif-probe.pl
%{perl_vendorlib}/ZoneMinder*
%{perl_vendorlib}/ONVIF*
%{perl_vendorlib}/WSDiscovery*
%{perl_vendorlib}/WSSecurity*
%{perl_vendorlib}/WSNotification*
%{_mandir}/man*/*
%dir %{_libexecdir}/zoneminder
%{_libexecdir}/zoneminder/cgi-bin
%dir %{_datadir}/zoneminder
%{_datadir}/zoneminder/db
%{_datadir}/zoneminder/www
%{_datadir}/polkit-1/actions/com.zoneminder.systemctl.policy
%{_datadir}/polkit-1/rules.d/com.zoneminder.systemctl.rules
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/events
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/images
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/sock
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/swap
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/temp
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/log/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/spool/zoneminder-upload
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /run/zoneminder
%changelog
* Thu Mar 3 2016 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.30.0
- Bump version fo 1.30.0 release.
* Sat Nov 21 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.29.0
- Bump version for 1.29.0 release on Fedora 23.
* Sat Feb 14 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Bump version for 1.28.1 release on Fedora 21.
* Sun Oct 5 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.0
- Bump version for 1.28.0 release.
* Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Tweak build requirements for cmake
* Sat Feb 01 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Add zmcamtool.pl. Bump version for 1.27 release.
* Mon Dec 16 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.5
- This is a bug fixe release
- RTSP fixes, cmake enhancements, couple other misc fixes
* Mon Oct 07 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Initial cmake build.
* Sat Oct 05 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Fedora specific path changes have been moved to zoneminder-1.26.0-defaults.patch
- All files are now part of the zoneminder source tree. Update specfile accordingly.
* Sat Sep 21 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.3
- Initial rebuild for ZoneMinder 1.26.3 release.
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Mon Jan 21 2013 Adam Tkac <atkac redhat com> - 1.25.0-12
- rebuild due to "jpeg8-ABI" feature drop
* Mon Jan 7 2013 Remi Collet <rcollet@redhat.com> - 1.25.0-11
- fix configuration file for httpd 2.4, #871502
* Fri Dec 21 2012 Adam Tkac <atkac redhat com> - 1.25.0-10
- rebuild against new libjpeg
* Thu Aug 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-9
- Add patch to work around v4l2 api breakage in 3.5 kernel.
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sat Jun 23 2012 Petr Pisar <ppisar@redhat.com> - 1.25.0-7
- Perl 5.16 rebuild
* Wed Mar 21 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-6
- Fix stupid thinko in sql modifications.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-5
- Clean up macro usage.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-4
- Convert to systemd.
- Add tmpfiles.d configuration since the initscript isn't around to create
/run/zoneminder.
- Remove some pointless executable permissions.
- Add logrotate file.
* Wed Feb 22 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-3
- Update README.Fedora to reference systemctl and mention timezone info in
php.ini.
- Add proper default for EYEZM_LOG_TO_FILE.
* Thu Feb 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-2
- Rebuild for new pcre.
* Thu Jan 19 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-1
- Update to 1.25.0
- Fix gcc4.7 build problems.
- Drop gcc4.4 build fixes; for whatever reason they now break the build.
- Clean up old patches.
- Force setting of ZM_TMPDIR and ZM_RUNDIR.
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.4-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-3
- Re-add the dist-tag that somehow got lost.
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-2
- Add patch for bug 711780 - fix syntax issue in Mapped.pm.
- Undo that patch, and undo another which was the cause of the whole mess.
- Fix up other patches so ZM_PATH_BUILD is both defined and useful.
- Make sure database creation mods actually take.
- Update Fedora-specific docs with some additional info.
- Use bundled mootools (javascript, so no guideline violation).
- Update download location.
- Update the gcrypt patch to actually work.
- Upstream changed the tarball without changing the version to patch a
vulnerability, so redownload.
* Sun Aug 14 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-1
- Initial attempt to upgrade to 1.24.4.
- Add patch from BZ 460310 to build against libgcrypt instead of requiring the
gnutls openssl libs.
* Thu Jul 21 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-7.20110324svn3310
- Perl mass rebuild
* Wed Jul 20 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-6.20110324svn3310
- Perl mass rebuild
* Mon May 09 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-5.20110324svn3310
- Bump for gnutls update.
* Thu Mar 24 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-4.20110324svn3310
- Update to latest 1.24.3 subversion. Turns out that what upstream was calling
1.24.3 is really just an occasionally updated devel snapshot.
- Rebase various patches.
* Wed Mar 23 2011 Dan Horák <dan@danny.cz> - 1.24.3-3
- rebuilt for mysql 5.5.10 (soname bump in libmysqlclient)
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Tue Jan 25 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-1
- Update to latest upstream version.
- Rebase patches.
- Initial incomplete attempt to disable v4l1 support.
* Fri Jan 21 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-6
- Unbundle cambozola; instead link to the separately pacakged copy.
- Remove BuildRoot:, %%clean and buildroot cleaning in %%install.
- Git rid of mixed space/tab usage by removing all tabs.
- Remove unnecessary Conflicts: line.
- Attempt to force short_open_tag on for the code directories.
- Move default location of sockets, swaps, logfiles and some temporary files to
make more sense and allow things to work better with a future selinux policy.
- Fix errors in README.Fedora.
* Wed Jun 02 2010 Marcela Maslanova <mmaslano@redhat.com> - 1.24.2-5
- Mass rebuild with perl-5.12.0
* Fri Dec 4 2009 Stepan Kasal <skasal@redhat.com> - 1.24.2-4
- rebuild against perl 5.10.1
- use Perl vendorarch and archlib variables correctly
* Mon Jul 27 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-2
- Bump release since 1.24.2-1 was mistakenly tagged a few months ago.
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-1
- Initial update to 1.24.2.
- Rebase patches.
- Update mootools download location.
- Update to mootools 1.2.3.
- Add additional dependencies for some optional features.
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-3
- Remove unused Sys::Mmap perl dependency RPM is finding
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-2
- Update gcc44 patch to disable -frepo, seems to be broken with gcc44
- Added noffmpeg patch to make building outside mock easier
* Sat Mar 21 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-1
- Patch for gcc 4.4 compilation errors
- Upgrade to 1.24.1
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.23.3-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Sat Jan 24 2009 Caolán McNamara <caolanm@redhat.com> - 1.23.3-3
- rebuild for dependencies
* Mon Dec 15 2008 Martin Ebourne <martin@zepler.org> - 1.23.3-2
- Fix permissions on zm.conf
* Fri Jul 11 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.23.3-1
- Initial attempt at packaging 1.23.
* Tue Jul 1 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-15
- Add perl module compat dependency, bz #453590
* Tue May 6 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-14
- Remove default runlevel, bz #441315
* Mon Apr 28 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.22.3-13
- Backport patch for CVE-2008-1381 from 1.23.3 to 1.22.3.
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.22.3-12
- Autorebuild for GCC 4.3
* Thu Jan 3 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-11
- Fix compilation on gcc 4.3
* Thu Dec 6 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-10
- Rebuild for new openssl
* Thu Aug 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-8
- Fix licence tag
* Thu Jul 12 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-7
- Fixes from testing by Jitz including missing dependencies and database creation
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-6
- Disable crashtrace on ppc
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-5
- Fix uid for directories in /var/lib/zoneminder
* Tue Jun 26 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-4
- Added perl Archive::Tar dependency
- Disabled web interface due to lack of access control on the event images
* Sun Jun 10 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-3
- Changes recommended in review by Jason Tibbitts
* Mon Apr 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-2
- Standardised on package name of zoneminder
* Thu Dec 28 2006 Martin Ebourne <martin@zepler.org> - 1.22.3-1
- First version. Uses some parts from zm-1.20.1 by Corey DeLasaux and Serg Oskin

View File

@ -0,0 +1 @@
../redhat/zoneminder.el7.logrotate.in

View File

@ -0,0 +1,18 @@
# ZoneMinder systemd unit file for Fedora
# Replace mariadb with community-mysql if using mysql service instead of mariadb
[Unit]
Description=ZoneMinder CCTV recording and security system
After=network.target mariadb.service httpd.service
Requires=mariadb.service httpd.service
[Service]
User=@WEB_USER@
Type=forking
ExecStart=@BINDIR@/zmpkg.pl start
ExecReload=@BINDIR@/zmpkg.pl restart
ExecStop=@BINDIR@/zmpkg.pl stop
PIDFile="@ZM_RUNDIR@/zm.pid"
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1 @@
../redhat/zoneminder.tmpfiles.in

View File

@ -38,7 +38,7 @@ install(CODE "execute_process(COMMAND ln -sf ../../../../${zm_webdir}/temp \"\$E
# Opensuse cambazola? requires cambozola as a separate package so just link to it # Opensuse cambazola? requires cambozola as a separate package so just link to it
#install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")") #install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")")
# Install auxillary files required to run zoneminder on OpenSuse # Install auxiliary files required to run zoneminder on OpenSuse
install(FILES zoneminder.conf DESTINATION /etc/apache2/conf.d PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(FILES zoneminder.conf DESTINATION /etc/apache2/conf.d PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(FILES zoneminder.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.tmpfiles DESTINATION /etc/tmpfiles.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) install(FILES zoneminder.tmpfiles DESTINATION /etc/tmpfiles.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)

View File

@ -138,7 +138,7 @@ Upgrades
has select, insert, update, and delete permission. has select, insert, update, and delete permission.
3. You will need to upgrade the ZoneMinder database as described in the 3. You will need to upgrade the ZoneMinder database as described in the
manual. Only if the previous step was succesful, may you run zmupdate like manual. Only if the previous step was successful, may you run zmupdate like
so (as root): so (as root):
/opt/zoneminder/bin/zmupdate.pl /opt/zoneminder/bin/zmupdate.pl

View File

@ -1 +0,0 @@
../redhat/redalert.wav

View File

@ -0,0 +1 @@
../redhat/redalert.wav

View File

@ -1,10 +1,22 @@
# CMakeLists.txt for the Redhat/CentOS Target Distro. # CMakeLists.txt for the Redhat/CentOS Target Distro.
# Display a message to show the RHEL build options are being processed.
message([STATUS] "Starting RHEL Build Options" ...)
# Create the zoneminder service file # Create the zoneminder service file
configure_file(zoneminder.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.service @ONLY) if(ZM_TARGET_DISTRO STREQUAL "el7")
configure_file(zoneminder.service.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.service @ONLY)
configure_file(zoneminder.el7.conf.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.el7.conf @ONLY)
configure_file(zoneminder.tmpfiles.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.tmpfiles @ONLY)
configure_file(zoneminder.el7.logrotate.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.el7.logrotate @ONLY)
else(ZM_TARGET_DISTRO STREQUAL "el7")
configure_file(zoneminder.sysvinit.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.sysvinit @ONLY)
configure_file(zoneminder.el6.logrotate.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.el6.logrotate @ONLY)
configure_file(zoneminder.el6.conf.in ${CMAKE_CURRENT_SOURCE_DIR}/zoneminder.el6.conf @ONLY)
endif(ZM_TARGET_DISTRO STREQUAL "el7")
# Download jscalendar & move files into position # Download jscalendar & move files into position
file(DOWNLOAD http://softlayer-dal.dl.sourceforge.net/project/jscalendar/jscalendar/1.0/jscalendar-1.0.zip ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar-1.0.zip LOG jsc_log STATUS download_jsc) file(DOWNLOAD http://iweb.dl.sourceforge.net/project/jscalendar/jscalendar/1.0/jscalendar-1.0.zip ${CMAKE_CURRENT_SOURCE_DIR}/jscalendar-1.0.zip LOG jsc_log STATUS download_jsc)
#message(STATUS "Log of jscalender script was: ${jsc_log}") #message(STATUS "Log of jscalender script was: ${jsc_log}")
if(download_jsc EQUAL 0) if(download_jsc EQUAL 0)
message(STATUS "Jscalander successfully downloaded. Installing...") message(STATUS "Jscalander successfully downloaded. Installing...")
@ -14,15 +26,16 @@ else(download_jsc EQUAL 0)
message(STATUS "Unable to download optional jscalander. Skipping...") message(STATUS "Unable to download optional jscalander. Skipping...")
endif(download_jsc EQUAL 0) endif(download_jsc EQUAL 0)
# Cambozola is now packaged in zmrepo
# Download cambozola & move files into position # Download cambozola & move files into position
file(DOWNLOAD http://www.andywilcock.com/code/cambozola/cambozola-0.931.tar.gz ${CMAKE_CURRENT_SOURCE_DIR}/cambozola-0.931.tar.gz STATUS download_camb) #file(DOWNLOAD http://www.andywilcock.com/code/cambozola/cambozola-0.931.tar.gz ${CMAKE_CURRENT_SOURCE_DIR}/cambozola-0.931.tar.gz STATUS download_camb)
if(download_camb EQUAL 0) #if(download_camb EQUAL 0)
message(STATUS "Cambozola successfully downloaded. Installing...") # message(STATUS "Cambozola successfully downloaded. Installing...")
execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/cambozola.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE untar_camb) # execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/cambozola.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE untar_camb)
message(STATUS "Status of cambozola script was: ${untar_camb}") # message(STATUS "Status of cambozola script was: ${untar_camb}")
else(download_camb EQUAL 0) #else(download_camb EQUAL 0)
message(STATUS "Unable to download optional Cambozola. Skipping...") # message(STATUS "Unable to download optional Cambozola. Skipping...")
endif(download_camb EQUAL 0) #endif(download_camb EQUAL 0)
# Create several empty folders # Create several empty folders
file(MAKE_DIRECTORY sock swap zoneminder zoneminder-upload events images temp) file(MAKE_DIRECTORY sock swap zoneminder zoneminder-upload events images temp)
@ -39,12 +52,23 @@ install(DIRECTORY events images temp DESTINATION /var/lib/zoneminder DIRECTORY_P
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/events \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/events\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/events \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/events\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/images \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/images\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/images \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/images\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/temp\")") install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/temp\")")
install(CODE "execute_process(COMMAND ln -sf ../../../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/api/app/tmp\")")
# Install auxillary files required to run zoneminder on CentOS # Link to Cambozola, which is now packaged in zmrepo
install(FILES zoneminder.conf DESTINATION /etc/httpd/conf.d PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")")
install(FILES zm-logrotate_d DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
# Install auxiliary files required to run zoneminder on CentOS
install(FILES redalert.wav DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/sounds PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) install(FILES redalert.wav DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/sounds PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
install(FILES zoneminder.service DESTINATION /etc/rc.d/init.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) if(ZM_TARGET_DISTRO STREQUAL "el7")
install(FILES zoneminder.el7.conf DESTINATION /etc/httpd/conf.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.el7.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.service DESTINATION /usr/lib/systemd/system PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES ../../misc/zoneminder-tmpfiles.conf DESTINATION /etc/tmpfiles.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
else(ZM_TARGET_DISTRO STREQUAL "el7")
install(FILES zoneminder.el6.conf DESTINATION /etc/httpd/conf.d RENAME zoneminder.conf PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.el6.logrotate DESTINATION /etc/logrotate.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
install(FILES zoneminder.sysvinit DESTINATION /etc/rc.d/init.d RENAME zoneminder PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ)
endif(ZM_TARGET_DISTRO STREQUAL "el7")
# Install jscalendar # Install jscalendar
if(unzip_jsc STREQUAL "") if(unzip_jsc STREQUAL "")

View File

@ -1,6 +1,20 @@
================================================================================ What's New
NEW INSTALLS ==========
================================================================================
1. Due to the active state of the ZoneMinder project, we now recommend granting
ALL permission to the ZoneMinder mysql account. This change must be done
manually before ZoneMinder will run. See the installation steps below.
2. This package uses the HTTPS protocol by default to access the web portal.
Requests using HTTP will auto-redirect to HTTPS. See README.https for
more information.
3. The php package that ships with CentOS 6 does not support the new ZoneMinder
API. If you require API functionality (such as using a mobile app) then you
should consider an upgrade to CentOS 7 or use Fedora.
New installs
============
1. Unless you are already using MySQL server, you need to ensure that 1. Unless you are already using MySQL server, you need to ensure that
the server is confired to start during boot and properly secured the server is confired to start during boot and properly secured
@ -11,30 +25,38 @@
sudo chkconfig mysqld on sudo chkconfig mysqld on
2. Using the password for the root account set during the previous step, you 2. Using the password for the root account set during the previous step, you
will need to create the ZoneMinder database: will need to create the ZoneMinder database and configure a database
account for ZoneMinder to use:
mysql -uroot -p
mysql> create database zm;
mysql> grant select,insert,update,delete,lock tables,alter on zm.* to
'zmuser'@localhost identified by 'zmpass';
mysql> exit;
mysql -uroot -p < /usr/share/zoneminder/db/zm_create.sql mysql -uroot -p < /usr/share/zoneminder/db/zm_create.sql
mysql -uroot -p -e "grant all on zm.* to \
'zmuser'@localhost identified by 'zmpass';"
mysqladmin -uroot -p reload mysqladmin -uroot -p reload
The database account credentials, zmuser/zmpass, are arbitrary. Set them to
anything that suits your environment.
3. If you have chosen to change the zoneminder mysql credentials to something 3. If you have chosen to change the zoneminder mysql credentials to something
other than zmuser/zmpass then you must now edit /etc/zm.conf. Change other than zmuser/zmpass then you must now edit /etc/zm.conf. Change
ZM_DB_USER and ZM_DB_PASS to the values you created in step 2. ZM_DB_USER and ZM_DB_PASS to the values you created in the previous step.
4. IMPORTANT: Edit /etc/php.ini and put in the appropriate timezone for 4. Edit /etc/php.ini, uncomment the date.timezone line, and add your local
date.timezone! timezone. PHP will complain loudly if this is not set, or if it is set
incorrectly, and these complaints will show up in the zoneminder logging
system as errors
5. The ZoneMinder web interface is disabled by default, you will need If you are not sure of the proper timezone specification to use, look at
to edit this file to enable it: http://php.net/date.timezone
/etc/httpd/conf.d/zoneminder.conf 5. Install mod_ssl or configure /etc/httpd/conf.d/zoneminder.conf to meet your
needs. This package comes preconfigured for HTTPS using the default self
signed certificate on your system. The recommended way to complete this step
is to simply install mod_ssl:
HINT: Most users will want to simply delete the line that says sudo yum install mod_ssl
"Deny from all".
If this does not meet your needs, then read README.https to
learn about alternatives. When in doubt, install mod_ssl.
6. Configure the web server to start automatically: 6. Configure the web server to start automatically:
@ -45,8 +67,8 @@
called local_zoneminder. A copy of this policy is in the documentation called local_zoneminder. A copy of this policy is in the documentation
folder. folder.
Unfortunately, this has not resolved all the SELinux issues so It is still possible to run into SELinux issues, however. If this is case,
most will want to disable SELinux permanently by editing the following: you can disable SELinux permanently by editing the following:
/etc/selinux/conf /etc/selinux/conf
@ -62,31 +84,50 @@
Then point your web browser to http://<machine name or ip>/zm Then point your web browser to http://<machine name or ip>/zm
================================================================================ Upgrades
UPGRADES ========
================================================================================
1. Add additional permissions to the zmuser account: 1. Verify /etc/zm.conf.
mysql -u root -p If zm.conf was manually edited before running the upgrade, the installation
grant lock tables,alter on zm.* to may not overwrite it. In this case, it will create the file
'zmuser'@localhost identified by 'zmpass'; /etc/zm.conf.rpmnew.
Since this is an upgrade, the assumption is that the zmuser account exists For example, this will happen if you are using database account credentials
and already has select, insert, update, and delete permission. other than zmuser/zmpass.
2. If you have previsouly changed the zoneminder mysql credentials to something Compare /etc/zm.conf to /etc/zm.conf.rpmnew. Verify that zm.conf
other than zmuser/zmpass then you must now edit /etc/zm.conf. Change contains any new config settings that may be in zm.conf.rpmnew.
ZM_DB_USER and ZM_DB_PASS to their appropriate values.
3. You will need to upgrade the ZoneMinder database as described in the manual. 2. Verify permissions of the zmuser account.
Only if step 1 was succesfully applied, may you run zmupdate like so:
sudo zmupdate.pl --version=<from version> Over time, the database account permissions required for normal operation
have increased. Verify the zmuser database account has been granted all
permission to the ZoneMinder database:
mysql -uroot -p -e "show grants for zmuser@localhost;"
If unsure then run it this way: See step 2 of the Installation section to add missing permissions.
3. Verify the ZoneMinder Apache configuration file in the folder
/etc/httpd/conf.d. You will have a file called "zoneminder.conf" and there
may also be a file called "zoneminder.conf.rpmnew". If the rpmnew file
exists, inspect it and merge anything new in that file with zoneminder.conf.
Verify the SSL REquirements meet your needs. Read README.https if necessary.
4. Upgrade the database before starting ZoneMinder.
Most upgrades can be performed by executing the following command:
sudo zmupdate.pl
Recent versions of ZoneMinder don't require any parameters added to the
zmupdate command. However, if ZoneMinder complains, you may need to call
zmupdate in the following manner:
sudo zmupdate.pl --user=root --pass=<mysql_root_pwd> --version=<from version> sudo zmupdate.pl --user=root --pass=<mysql_root_pwd> --version=<from version>
5. Now start zoneminder:
sudo service zoneminder start

View File

@ -0,0 +1,148 @@
What's New
==========
1. The Apache ScriptAlias has been changed from "/cgi-bin/zm/zms" to
"/cgi-bin-zm/zms". This has been to done to avoid this bug:
https://bugzilla.redhat.com/show_bug.cgi?id=973067
IMPORTANT: You must manually verify the value of PATH_ZMS under Options.
Make sure it is set to "/cgi-bin-zm/nph-zms". Failure to do so will result
in a broken system. You have been warned.
2. Due to the active state of the ZoneMinder project, we now recommend granting
ALL permission to the ZoneMinder mysql account. This change must be done
manually before ZoneMinder will run. See the installation steps below.
3. This package uses the HTTPS protocol by default to access the web portal.
Requests using HTTP will auto-redirect to HTTPS. See README.https for
more information.
4. This package ships with the new ZoneMinder API enabled.
New installs
============
1. Unless you are already using MariaDB server, you need to ensure that
the server is configured to start during boot and properly secured
by running:
sudo systemctl enable mariadb
sudo systemctl start mariadb
sudo mysql_secure_installation
2. Using the password for the root account set during the previous step, you
will need to create the ZoneMinder database and configure a database
account for ZoneMinder to use:
mysql -uroot -p < /usr/share/zoneminder/db/zm_create.sql
mysql -uroot -p -e "grant all on zm.* to \
'zmuser'@localhost identified by 'zmpass';"
mysqladmin -uroot -p reload
The database account credentials, zmuser/zmpass, are arbitrary. Set them to
anything that suits your environment.
3. If you have chosen to change the zoneminder database account credentials to
something other than zmuser/zmpass, you must now edit /etc/zm/zm.conf.
Change ZM_DB_USER and ZM_DB_PASS to the values you created in the previous
step.
This version of zoneminder no longer requires you to make a similar change
to the credentials in /usr/share/zoneminder/www/api/app/Config/database.php
This now happens dynamically. Do *not* make any changes to this file.
4. Edit /etc/php.ini, uncomment the date.timezone line, and add your local
timezone. PHP will complain loudly if this is not set, or if it is set
incorrectly, and these complaints will show up in the zoneminder logging
system as errors.
If you are not sure of the proper timezone specification to use, look at
http://php.net/date.timezone
5. Disable SELinux
We currently do not have the resources to create and maintain an accurate
SELinux policy for ZoneMinder on CentOS 7. We will gladly accept pull
reqeusts from anyone who wishes to do the work. In the meantime, SELinux
will need to be disabled or put into permissive mode.
To immediately disbale SELinux for the current seesion, issue the following
from the command line:
sudo setenforce 0
To permanently disable SELinux, edit /etc/selinux/config and change the
SELINUX line from "enforcing" to "disabled". This change will take
effect after a reboot.
6. Install mod_ssl or configure /etc/httpd/conf.d/zoneminder.conf to meet your
needs. This package comes preconfigured for HTTPS using the default self
signed certificate on your system. The recommended way to complete this step
is to simply install mod_ssl:
sudo yum install mod_ssl
If this does not meet your needs, then read README.https to
learn about alternatives. When in doubt, install mod_ssl.
7. Now start the web server:
sudo systemctl enable httpd
sudo systemctl start httpd
8. Now start zoneminder:
sudo systemctl enable zoneminder
sudo systemctl start zoneminder
Upgrades
========
1. Verify /etc/zm/zm.conf.
If zm.conf was manually edited before running the upgrade, the installation
may not overwrite it. In this case, it will create the file
/etc/zm/zm.conf.rpmnew.
For example, this will happen if you are using database account credentials
other than zmuser/zmpass.
Compare /etc/zm/zm.conf to /etc/zm/zm.conf.rpmnew. Verify that zm.conf
contains any new config settings that may be in zm.conf.rpmnew.
This version of zoneminder no longer requires you to make a similar change
to the credentials in /usr/share/zoneminder/www/api/app/Config/database.php
This now happens dynamically. Do *not* make any changes to this file.
2. Verify permissions of the zmuser account.
Over time, the database account permissions required for normal operation
have increased. Verify the zmuser database account has been granted all
permission to the ZoneMinder database:
mysql -uroot -p -e "show grants for zmuser@localhost;"
See step 2 of the Installation section to add missing permissions.
3. Verify the ZoneMinder Apache configuration file in the folder
/etc/httpd/conf.d. You will have a file called "zoneminder.conf" and there
may also be a file called "zoneminder.conf.rpmnew". If the rpmnew file
exists, inspect it and merge anything new in that file with zoneminder.conf.
Verify the SSL REquirements meet your needs. Read README.https if necessary.
4. Upgrade the database before starting ZoneMinder.
Most upgrades can be performed by executing the following command:
sudo zmupdate.pl
Recent versions of ZoneMinder don't require any parameters added to the
zmupdate command. However, if ZoneMinder complains, you may need to call
zmupdate in the following manner:
sudo zmupdate.pl --user=root --pass=<mysql_root_pwd> --version=<from version>
5. Now start zoneminder:
sudo systemctl start zoneminder

View File

@ -0,0 +1,25 @@
HTTPS is now a requirement
==========================
This package now depends on Apache's mod_ssl pacakge. This will automatically
be installed along with ZoneMinder. Upon installation, the mod_ssl package
will create a default, self-signed certificate. This is the certificate that
ZoneMinder will use out of the box.
Since the certificate is self-signed, you will get a warning from your browser
the first time you access the web portal. This is normal.
This is not intended to be an all encompasing solution for everyone. ZoneMinder
will work just fine over HTTPS the way it is currently configured. However,
here are a couple of considerations you may want to take.
1. Create your own certificate. The CentOS wiki has a guide that describes how
to do this: https://wiki.centos.org/HowTos/Https . Additionally, Googling
"centos certificate" reveals many articles on the subject. Note that some
third party applications, such as zmNinja, will require you to create a
certificate different than the default certificate on your machine.
2. You can turn off HTTPS entirely by simply commenting out the SSLRequireSSL
directives found in /etc/httpd/conf.d/zoneminder.conf. You should also
comment out the HTTP -> HTTPS Rewrite rule.

View File

@ -237,7 +237,6 @@ fi
# zmfix removed from zoneminder 1.26.6 # zmfix removed from zoneminder 1.26.6
#%attr(4755,root,root) %{_bindir}/zmfix #%attr(4755,root,root) %{_bindir}/zmfix
%{_bindir}/zmpkg.pl %{_bindir}/zmpkg.pl
%{_bindir}/zmstreamer
%{_bindir}/zmtrack.pl %{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl %{_bindir}/zmtrigger.pl
%{_bindir}/zmu %{_bindir}/zmu
@ -250,9 +249,11 @@ fi
%{_bindir}/zmonvif-probe.pl %{_bindir}/zmonvif-probe.pl
%{perl_vendorlib}/ZoneMinder* %{perl_vendorlib}/ZoneMinder*
%{perl_vendorlib}/ONVIF* %{perl_vendorlib}/%{_arch}-linux-thread-multi/auto/ZoneMinder*
%{perl_vendorlib}/WSDiscovery* #%{perl_vendorlib}/ONVIF*
%{perl_vendorlib}/WSSecurity* #%{perl_vendorlib}/WSDiscovery*
#%{perl_vendorlib}/WSSecurity*
#%{perl_vendorlib}/%{_arch}-linux-thread-multi/auto/ONVIF*
%{_mandir}/man*/* %{_mandir}/man*/*
%dir %{_libexecdir}/%{name} %dir %{_libexecdir}/%{name}
%{_libexecdir}/%{name}/cgi-bin %{_libexecdir}/%{name}/cgi-bin
@ -277,6 +278,9 @@ fi
* Sun Aug 03 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27 * Sun Aug 03 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Include ONVIF support files - Include ONVIF support files
* Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Tweak build requirements for cmake
* Sat Feb 01 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27 * Sat Feb 01 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Add zmcamtool.pl. Bump version for 1.27 release. - Add zmcamtool.pl. Bump version for 1.27 release.

View File

@ -1,11 +1,12 @@
module local_zoneminder 1.2;
module local_zoneminder 1.1;
require { require {
type afs_ka_port_t; type afs_ka_port_t;
type netsupport_port_t; type netsupport_port_t;
type port_t; type port_t;
type presence_port_t; type presence_port_t;
type postfix_master_t;
type postfix_qmgr_t;
type postfix_pickup_t; type postfix_pickup_t;
type httpd_t; type httpd_t;
type var_lib_t; type var_lib_t;
@ -53,7 +54,7 @@ require {
class sock_file { write create unlink }; class sock_file { write create unlink };
class unix_stream_socket { read connectto }; class unix_stream_socket { read connectto };
class lnk_file { write create getattr read lock unlink }; class lnk_file { write create getattr read lock unlink };
class dir search; class dir {search getattr };
class udp_socket name_bind; class udp_socket name_bind;
class file { write getattr read lock unlink open }; class file { write getattr read lock unlink open };
class shm { unix_read unix_write associate read write getattr }; class shm { unix_read unix_write associate read write getattr };
@ -61,41 +62,42 @@ require {
} }
#============= httpd_t ============== #============= httpd_t ==============
allow httpd_t auditd_t:dir search; allow httpd_t auditd_t:dir { search getattr };
allow httpd_t auditd_t:file { read getattr open }; allow httpd_t auditd_t:file { read getattr open };
allow httpd_t crond_t:dir search; allow httpd_t crond_t:dir { search getattr };
allow httpd_t crond_t:file { read getattr open }; allow httpd_t crond_t:file { read getattr open };
allow httpd_t dhcpc_t:dir search; allow httpd_t dhcpc_t:dir { search getattr };
allow httpd_t dhcpc_t:file { read getattr open }; allow httpd_t dhcpc_t:file { read getattr open };
allow httpd_t getty_t:dir search; allow httpd_t getty_t:dir { search getattr };
allow httpd_t getty_t:file { read getattr open }; allow httpd_t getty_t:file { read getattr open };
allow httpd_t httpd_log_t:file write; allow httpd_t httpd_log_t:file write;
allow httpd_t httpd_var_lib_t:lnk_file { write getattr read lock unlink }; allow httpd_t httpd_var_lib_t:lnk_file { write getattr read lock unlink };
allow httpd_t init_t:dir search; allow httpd_t init_t:dir { search getattr };
allow httpd_t init_t:file { read getattr open }; allow httpd_t init_t:file { read getattr open };
#!!!! The source type 'httpd_t' can write to a 'file' of the following types: #!!!! The source type 'httpd_t' can write to a 'file' of the following types:
# squirrelmail_spool_t, dirsrvadmin_config_t, httpd_lock_t, dirsrv_config_t, httpd_tmp_t, dirsrvadmin_tmp_t, httpd_cache_t, httpd_tmpfs_t, httpd_squirrelmail_t, dirsrv_var_log_t, zarafa_var_lib_t, dirsrv_var_run_t, httpd_var_lib_t, httpd_var_run_t, passenger_tmp_t, httpd_nutups_cgi_rw_content_t, httpd_apcupsd_cgi_rw_content_t, httpd_dspam_rw_content_t, httpd_mediawiki_rw_content_t, httpd_squid_rw_content_t, httpd_prewikka_rw_content_t, httpd_smokeping_cgi_rw_content_t, passenger_var_run_t, httpd_openshift_rw_content_t, httpd_dirsrvadmin_rw_content_t, httpd_w3c_validator_rw_content_t, httpd_user_rw_content_t, httpd_awstats_rw_content_t, httpdcontent, httpd_cobbler_rw_content_t, root_t, httpd_munin_rw_content_t, httpd_bugzilla_rw_content_t, httpd_cvs_rw_content_t, httpd_git_rw_content_t, httpd_sys_rw_content_t, httpd_sys_rw_content_t, httpd_nagios_rw_content_t #squirrelmail_spool_t, mirrormanager_var_run_t, dirsrvadmin_config_t, httpd_lock_t, httpd_tmp_t, dirsrv_config_t, dirsrvadmin_tmp_t, httpd_cache_t, httpd_tmpfs_t, httpd_squirrelmail_t, dirsrv_var_run_t, dirsrv_var_log_t, httpd_var_lib_t, httpd_var_run_t, zarafa_var_lib_t, httpd_prewikka_rw_content_t, httpd_mediawiki_rw_content_t, httpd_squid_rw_content_t, passenger_var_run_t, httpd_smokeping_cgi_rw_content_t, httpd_openshift_rw_content_t, httpd_dirsrvadmin_rw_content_t, httpd_w3c_validator_rw_content_t, httpd_collectd_rw_content_t, cluster_var_lib_t, cluster_var_run_t, httpd_user_rw_content_t, httpd_awstats_rw_content_t, httpdcontent, root_t, httpd_cobbler_rw_content_t, httpd_munin_rw_content_t, cluster_conf_t, httpd_bugzilla_rw_content_t, passenger_tmp_t, httpd_cvs_rw_content_t, httpd_git_rw_content_t, httpd_sys_rw_content_t, httpd_sys_rw_content_t, httpd_nagios_rw_content_t, httpd_apcupsd_cgi_rw_content_t, httpd_nutups_cgi_rw_content_t, httpd_dspam_rw_content_t
allow httpd_t initrc_state_t:file { read write getattr unlink open }; allow httpd_t initrc_state_t:file { read write getattr unlink open };
allow httpd_t initrc_t:unix_stream_socket connectto; allow httpd_t initrc_t:unix_stream_socket connectto;
allow httpd_t initrc_t:shm { unix_read unix_write associate read write getattr }; allow httpd_t initrc_t:shm { unix_read unix_write associate read write getattr };
allow httpd_t initrc_var_run_t:file { read lock open }; allow httpd_t initrc_var_run_t:file { write read lock open };
allow httpd_t kernel_t:dir search; allow httpd_t kernel_t:dir { search getattr };
allow httpd_t kernel_t:file { read getattr open }; allow httpd_t kernel_t:file { read getattr open };
allow httpd_t mysqld_safe_t:dir search; allow httpd_t mysqld_safe_t:dir { search getattr };
allow httpd_t mysqld_safe_t:file { read getattr open }; allow httpd_t mysqld_safe_t:file { read getattr open };
allow httpd_t mysqld_t:dir search; allow httpd_t mysqld_t:dir { search getattr };
allow httpd_t mysqld_t:file { read getattr open }; allow httpd_t mysqld_t:file { read getattr open };
allow httpd_t sshd_t:dir search; allow httpd_t sshd_t:dir { search getattr };
allow httpd_t sshd_t:file { read getattr open }; allow httpd_t sshd_t:file { read getattr open };
allow httpd_t syslogd_t:dir search; allow httpd_t syslogd_t:dir { search getattr };
allow httpd_t syslogd_t:file { read getattr open }; allow httpd_t syslogd_t:file { read getattr open };
allow httpd_t tmpfs_t:sock_file write; allow httpd_t tmpfs_t:sock_file write;
allow httpd_t udev_t:dir search; allow httpd_t udev_t:dir { search getattr };
allow httpd_t udev_t:file { read getattr open }; allow httpd_t udev_t:file { read getattr open };
allow httpd_t unconfined_t:dir search; allow httpd_t unconfined_t:dir { search getattr };
allow httpd_t unconfined_t:file { read getattr open }; allow httpd_t unconfined_t:file { read getattr open };
allow httpd_t var_lib_t:lnk_file { write getattr read lock unlink }; allow httpd_t var_lib_t:lnk_file { write getattr read lock unlink };
allow httpd_t var_lib_t:sock_file { write unlink };
allow httpd_t v4l_device_t:chr_file getattr; allow httpd_t v4l_device_t:chr_file getattr;
allow httpd_t afs_fs_port_t:udp_socket name_bind; allow httpd_t afs_fs_port_t:udp_socket name_bind;
allow httpd_t afs_ka_port_t:udp_socket name_bind; allow httpd_t afs_ka_port_t:udp_socket name_bind;
@ -114,10 +116,10 @@ allow httpd_t mmcc_port_t:udp_socket name_bind;
allow httpd_t netsupport_port_t:udp_socket name_bind; allow httpd_t netsupport_port_t:udp_socket name_bind;
allow httpd_t nodejs_debug_port_t:udp_socket name_bind; allow httpd_t nodejs_debug_port_t:udp_socket name_bind;
allow httpd_t port_t:udp_socket name_bind; allow httpd_t port_t:udp_socket name_bind;
allow httpd_t postfix_master_t:dir search; allow httpd_t postfix_master_t:dir { search getattr };
allow httpd_t postfix_master_t:file { read getattr open }; allow httpd_t postfix_master_t:file { read getattr open };
allow httpd_t postfix_pickup_t:dir search; allow httpd_t postfix_pickup_t:dir { search getattr };
allow httpd_t postfix_pickup_t:file { read getattr open }; allow httpd_t postfix_pickup_t:file { read getattr open };
allow httpd_t postfix_qmgr_t:dir search; allow httpd_t postfix_qmgr_t:dir { search getattr };
allow httpd_t postfix_qmgr_t:file { read getattr open }; allow httpd_t postfix_qmgr_t:file { read getattr open };
allow httpd_t presence_port_t:udp_socket name_bind; allow httpd_t presence_port_t:udp_socket name_bind;

0
distros/redhat/redalert.wav Executable file → Normal file
View File

View File

@ -1,33 +0,0 @@
# The Zoneminder web interface has been disabled by default due to a small
# security issue in the default install.
#
# When using Zoneminder's own authentication, recorded CCTV images are
# accessible from the web directly without passing the authentication. This
# means any attacker could see your CCTV images without a password. In order
# to avoid this you can disable Zoneminder's authentication and configure
# standard Apache authentication (see the Apache documentation for details on
# this).
#
# If you still wish to use Zoneminder's own authentication, or have an
# internal site which needs no authentication, you need to delete the line
# marked below and restart Apache.
Alias /zm "/usr/share/zoneminder/www"
<Directory "/usr/share/zoneminder/www">
Options -Indexes MultiViews FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
# The code unfortunately uses short tags in many places
php_value short_open_tag 1
Deny from all # DELETE THIS LINE
</Directory>
ScriptAlias /cgi-bin/zm "/usr/libexec/zoneminder/cgi-bin"
<Directory "/usr/libexec/zoneminder/cgi-bin">
AllowOverride All
Options ExecCGI
Order allow,deny
Allow from all
</Directory>

View File

@ -0,0 +1,28 @@
#
# ZoneMinder Apache configuration file
# With SSLRequire and HTTPS auto redirect
# Modify this configuration to suit your requirements
#
# Auto Redirect HTTP requests to HTTPS
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/?(zm)(.*) https://%{SERVER_NAME}/$1$2 [R,L]
Alias /zm "@ZM_WEBDIR@"
<Directory "@ZM_WEBDIR@">
SSLRequireSSL
Options -Indexes MultiViews FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
ScriptAlias /cgi-bin/zm "@ZM_CGIDIR@"
<Directory "@ZM_CGIDIR@">
SSLRequireSSL
AllowOverride All
Options ExecCGI FollowSymLinks
Order allow,deny
Allow from all
</Directory>

View File

@ -1,4 +1,4 @@
/var/log/zoneminder/*log @ZM_LOGDIR@/*log
{ {
weekly weekly
notifempty notifempty

View File

@ -4,7 +4,7 @@
%define zmgid_final apache %define zmgid_final apache
Name: zoneminder Name: zoneminder
Version: 1.28.0 Version: 1.30.0
Release: 1%{?dist} Release: 1%{?dist}
Summary: A camera monitoring and analysis tool Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons Group: System Environment/Daemons
@ -17,8 +17,6 @@ URL: http://www.zoneminder.com/
#Source0: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz #Source0: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz
Source0: ZoneMinder-%{version}.tar.gz Source0: ZoneMinder-%{version}.tar.gz
Patch1: zoneminder-1.28.0-defaults.patch
BuildRequires: cmake gnutls-devel bzip2-devel BuildRequires: cmake gnutls-devel bzip2-devel
BuildRequires: mysql-devel pcre-devel libjpeg-turbo-devel BuildRequires: mysql-devel pcre-devel libjpeg-turbo-devel
BuildRequires: perl(Archive::Tar) perl(Archive::Zip) BuildRequires: perl(Archive::Tar) perl(Archive::Zip)
@ -32,8 +30,8 @@ BuildRequires: libcurl-devel vlc-devel ffmpeg-devel polkit-devel
# cmake needs the following installed at build time due to the way it auto-detects certain parameters # cmake needs the following installed at build time due to the way it auto-detects certain parameters
BuildRequires: httpd ffmpeg BuildRequires: httpd ffmpeg
Requires: httpd php php-mysql mysql-server libjpeg-turbo polkit Requires: httpd php php-gd php-mysql mysql-server libjpeg-turbo cambozola polkit net-tools
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) Requires: psmisc perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip) Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip)
Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP) Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP)
Requires: libcurl vlc-core ffmpeg Requires: libcurl vlc-core ffmpeg
@ -63,12 +61,20 @@ too much degradation of performance.
%prep %prep
%setup -q -n ZoneMinder-%{version} %setup -q -n ZoneMinder-%{version}
%patch1 -p0 -b .defaults # Change the following default values
./utils/zmeditconfigdata.sh ZM_PATH_ZMS /cgi-bin/zm/nph-zms
./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
./utils/zmeditconfigdata.sh ZM_PATH_SWAP /dev/shm
./utils/zmeditconfigdata.sh ZM_UPLOAD_FTP_LOC_DIR /var/spool/zoneminder-upload
./utils/zmeditconfigdata.sh ZM_OPT_CONTROL yes
./utils/zmeditconfigdata.sh ZM_CHECK_FOR_UPDATES no
./utils/zmeditconfigdata.sh ZM_DYN_SHOW_DONATE_REMINDER no
./utils/zmeditconfigdata.sh ZM_OPT_FAST_DELETE no
%build %build
# Have to override CMAKE_INSTALL_LIBDIR for cmake < 2.8.7 due to this bug: # Have to override CMAKE_INSTALL_LIBDIR for cmake < 2.8.7 due to this bug:
# https://bugzilla.redhat.com/show_bug.cgi?id=795542 # https://bugzilla.redhat.com/show_bug.cgi?id=795542
%cmake -DZM_TARGET_DISTRO="el6" -DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} -DZM_PERL_SUBPREFIX=`x="%{perl_vendorlib}" ; echo ${x#"%{_prefix}"}` . %cmake -DZM_TARGET_DISTRO="el6" -DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} .
make %{?_smp_mflags} make %{?_smp_mflags}
@ -91,8 +97,24 @@ echo -e "\nCreating and installing a ZoneMinder SELinux policy module. Please wa
/usr/bin/semodule_package -o %{_docdir}/%{name}-%{version}/local_zoneminder.pp -m %{_docdir}/%{name}-%{version}/local_zoneminder.mod > /dev/null /usr/bin/semodule_package -o %{_docdir}/%{name}-%{version}/local_zoneminder.pp -m %{_docdir}/%{name}-%{version}/local_zoneminder.mod > /dev/null
/usr/sbin/semodule -i %{_docdir}/%{name}-%{version}/local_zoneminder.pp > /dev/null /usr/sbin/semodule -i %{_docdir}/%{name}-%{version}/local_zoneminder.pp > /dev/null
# Display the README for post installation instructions # Upgrade from a previous version of zoneminder
/usr/bin/less %{_docdir}/%{name}-%{version}/README.CentOS if [ $1 -eq 2 ] ; then
# Add any new PTZ control configurations to the database (will not overwrite)
%{_bindir}/zmcamtool.pl --import >/dev/null 2>&1 || :
# Freshen the database
%{_bindir}/zmupdate.pl -f >/dev/null 2>&1 || :
# We can't run this automatically when new sql account permissions need to
# be manually added first
# Run zmupdate non-interactively
#/usr/bin/zmupdate.pl --nointeractive
fi
# Warn the end user to read the README file
echo -e "\nVERY IMPORTANT: Before starting ZoneMinder, read README.Centos to finish the\ninstallation or upgrade!\n"
echo -e "\nThe README file is located here: %{_docdir}/%{name}-%{version}.\n"
%preun %preun
if [ $1 -eq 0 ]; then if [ $1 -eq 0 ]; then
@ -113,8 +135,8 @@ rm -rf %{_docdir}/%{name}-%{version}
%files %files
%defattr(-,root,root,-) %defattr(-,root,root,-)
%doc AUTHORS BUGS ChangeLog COPYING LICENSE NEWS README.md distros/redhat/README.CentOS distros/redhat/jscalendar-doc %doc AUTHORS BUGS ChangeLog COPYING LICENSE NEWS README.md distros/redhat/README.CentOS distros/redhat/README.https distros/redhat/jscalendar-doc
%doc distros/redhat/cambozola-doc distros/redhat/local_zoneminder.te %doc distros/redhat/local_zoneminder.te
%config %attr(640,root,%{zmgid_final}) %{_sysconfdir}/zm.conf %config %attr(640,root,%{zmgid_final}) %{_sysconfdir}/zm.conf
%config(noreplace) %attr(644,root,root) %{_sysconfdir}/httpd/conf.d/zoneminder.conf %config(noreplace) %attr(644,root,root) %{_sysconfdir}/httpd/conf.d/zoneminder.conf
%config(noreplace) /etc/logrotate.d/%{name} %config(noreplace) /etc/logrotate.d/%{name}
@ -128,7 +150,6 @@ rm -rf %{_docdir}/%{name}-%{version}
%{_bindir}/zmf %{_bindir}/zmf
%{_bindir}/zmfilter.pl %{_bindir}/zmfilter.pl
%{_bindir}/zmpkg.pl %{_bindir}/zmpkg.pl
%{_bindir}/zmstreamer
%{_bindir}/zmtrack.pl %{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl %{_bindir}/zmtrigger.pl
%{_bindir}/zmu %{_bindir}/zmu
@ -137,15 +158,17 @@ rm -rf %{_docdir}/%{name}-%{version}
%{_bindir}/zmwatch.pl %{_bindir}/zmwatch.pl
%{_bindir}/zmcamtool.pl %{_bindir}/zmcamtool.pl
%{_bindir}/zmsystemctl.pl %{_bindir}/zmsystemctl.pl
%{_bindir}/zmtelemetry.pl
%{_bindir}/zmx10.pl %{_bindir}/zmx10.pl
%{_bindir}/zmonvif-probe.pl %{_bindir}/zmonvif-probe.pl
%{perl_vendorlib}/ZoneMinder* %{perl_vendorlib}/ZoneMinder*
%{perl_vendorlib}/%{_arch}-linux-thread-multi/auto/ZoneMinder* %{perl_vendorarch}/auto/ZoneMinder/.packlist
%{perl_vendorarch}/auto/ONVIF/.packlist
%{perl_vendorlib}/ONVIF* %{perl_vendorlib}/ONVIF*
%{perl_vendorlib}/WSDiscovery* %{perl_vendorlib}/WSDiscovery*
%{perl_vendorlib}/WSSecurity* %{perl_vendorlib}/WSSecurity*
%{perl_vendorlib}/%{_arch}-linux-thread-multi/auto/ONVIF* %{perl_vendorlib}/WSNotification*
%{_mandir}/man*/* %{_mandir}/man*/*
%dir %{_libexecdir}/%{name} %dir %{_libexecdir}/%{name}
%{_libexecdir}/%{name}/cgi-bin %{_libexecdir}/%{name}/cgi-bin
@ -166,12 +189,18 @@ rm -rf %{_docdir}/%{name}-%{version}
%dir %attr(755,%{zmuid_final},%{zmgid_final}) %{_localstatedir}/spool/zoneminder-upload %dir %attr(755,%{zmuid_final},%{zmgid_final}) %{_localstatedir}/spool/zoneminder-upload
%changelog %changelog
* Thu Mar 3 2016 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.30.0
- Bump version fo 1.30.0 release.
* Tue Sep 8 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Require https, freshen dB on updates.
* Wed Feb 18 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Include ONVIF support files
* Sun Oct 5 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.0 * Sun Oct 5 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.0
- Bump version for 1.28.0 release. - Bump version for 1.28.0 release.
* Sun Aug 03 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Include ONVIF support files
* Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27 * Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Tweak build requirements for cmake - Tweak build requirements for cmake

View File

@ -0,0 +1,43 @@
#
# ZoneMinder Apache configuration file
# With SSLRequire and HTTPS auto redirect
# Modify this configuration to suit your requirements
#
# Auto Redirect HTTP requests to HTTPS
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/?(zm)(.*) https://%{SERVER_NAME}/$1$2 [R,L]
Alias /zm "@ZM_WEBDIR@"
<Directory "@ZM_WEBDIR@">
SSLRequireSSL
Options -Indexes +MultiViews +FollowSymLinks
AllowOverride All
<IfModule mod_authz_core.c>
# Apache 2.4
Require all granted
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order deny,allow
Allow from all
</IfModule>
</Directory>
ScriptAlias /cgi-bin-zm "@ZM_CGIDIR@"
<Directory "@ZM_CGIDIR@">
SSLRequireSSL
AllowOverride All
Options +ExecCGI +FollowSymLinks
<IfModule mod_authz_core.c>
# Apache 2.4
Require all granted
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order deny,allow
Allow from all
</IfModule>
</Directory>

View File

@ -0,0 +1,8 @@
@ZM_LOGDIR@/*.log {
missingok
notifempty
sharedscripts
postrotate
@BINDIR@/zmpkg.pl logrot 2> /dev/null > /dev/null || :
endscript
}

View File

@ -0,0 +1,427 @@
%define zmuid $(id -un)
%define zmgid $(id -gn)
%define zmuid_final apache
%define zmgid_final apache
%global _hardened_build 1
Name: zoneminder
Version: 1.30.0
Release: 1%{?dist}
Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons
# jscalendar is LGPL (any version): http://www.dynarch.com/projects/calendar/
# Mootools is inder the MIT license: http://mootools.net/
License: GPLv2+ and LGPLv2+ and MIT
URL: http://www.zoneminder.com/
#Source: https://github.com/ZoneMinder/ZoneMinder/archive/v%{version}.tar.gz
Source: ZoneMinder-%{version}.tar.gz
BuildRequires: cmake gnutls-devel systemd-units bzip2-devel
BuildRequires: mariadb-devel pcre-devel libjpeg-turbo-devel
BuildRequires: perl(Archive::Tar) perl(Archive::Zip) perl-podlators
BuildRequires: perl(Date::Manip) perl(DBD::mysql)
BuildRequires: perl(ExtUtils::MakeMaker) perl(LWP::UserAgent)
BuildRequires: perl(MIME::Entity) perl(MIME::Lite)
BuildRequires: perl(PHP::Serialization) perl(Sys::Mmap)
BuildRequires: perl(Time::HiRes) perl(Net::SFTP::Foreign)
BuildRequires: perl(Expect) perl(Sys::Syslog)
BuildRequires: gcc gcc-c++ vlc-devel libcurl-devel libv4l-devel
BuildRequires: ffmpeg ffmpeg-devel perl(X10::ActiveHome) perl(Astro::SunTime)
# cmake needs the following installed at build time due to the way it auto-detects certain parameters
BuildRequires: httpd polkit-devel
Requires: httpd php php-gd php-mysql mariadb-server cambozola polkit net-tools
Requires: psmisc libjpeg-turbo vlc-core libcurl
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip)
Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP)
Requires: perl(LWP::Protocol::https) ffmpeg
Requires(post): systemd-units systemd-sysv
Requires(post): /usr/bin/gpasswd
Requires(post): /usr/bin/less
Requires(preun): systemd-units
Requires(postun): systemd-units
%description
ZoneMinder is a set of applications which is intended to provide a complete
solution allowing you to capture, analyse, record and monitor any cameras you
have attached to a Linux based machine. It is designed to run on kernels which
support the Video For Linux (V4L) interface and has been tested with cameras
attached to BTTV cards, various USB cameras and IP network cameras. It is
designed to support as many cameras as you can attach to your computer without
too much degradation of performance.
%prep
%setup -q -n ZoneMinder-%{version}
# Change the following default values
./utils/zmeditconfigdata.sh ZM_PATH_ZMS /cgi-bin-zm/nph-zms
./utils/zmeditconfigdata.sh ZM_OPT_CAMBOZOLA yes
./utils/zmeditconfigdata.sh ZM_PATH_SWAP /dev/shm
./utils/zmeditconfigdata.sh ZM_UPLOAD_FTP_LOC_DIR /var/spool/zoneminder-upload
./utils/zmeditconfigdata.sh ZM_OPT_CONTROL yes
./utils/zmeditconfigdata.sh ZM_CHECK_FOR_UPDATES no
./utils/zmeditconfigdata.sh ZM_DYN_SHOW_DONATE_REMINDER no
./utils/zmeditconfigdata.sh ZM_OPT_FAST_DELETE no
%build
%cmake \
-DZM_TARGET_DISTRO="el7" \
.
make %{?_smp_mflags}
%install
export DESTDIR=%{buildroot}
make install
%post
if [ $1 -eq 1 ] ; then
# Initial installation
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
# Allow zoneminder access to local video sources, serial ports, and x10
/usr/bin/gpasswd -a %{zmuid_final} video
/usr/bin/gpasswd -a %{zmuid_final} dialout
# Disabled. SELinux policy does not work for RHEL 7.
# Create and load zoneminder selinux policy module
#echo -e "\nCreating and installing a ZoneMinder SELinux policy module. Please wait.\n"
#/usr/bin/checkmodule -M -m -o %{_docdir}/%{name}-%{version}/local_zoneminder.mod %{_docdir}/%{name}-%{version}/local_zoneminder.te > /dev/null
#/usr/bin/semodule_package -o %{_docdir}/%{name}-%{version}/local_zoneminder.pp -m %{_docdir}/%{name}-%{version}/local_zoneminder.mod > /dev/null
#/usr/sbin/semodule -i %{_docdir}/%{name}-%{version}/local_zoneminder.pp > /dev/null
# Upgrade from a previous version of zoneminder
if [ $1 -eq 2 ] ; then
# Add any new PTZ control configurations to the database (will not overwrite)
%{_bindir}/zmcamtool.pl --import >/dev/null 2>&1 || :
# Freshen the database
%{_bindir}/zmupdate.pl -f >/dev/null 2>&1 || :
# We can't run this automatically when new sql account permissions need to
# be manually added first
# Run zmupdate non-interactively
#/usr/bin/zmupdate.pl --nointeractive
fi
# Warn the end user to read the README file
echo -e "\nVERY IMPORTANT: Before starting ZoneMinder, read README.Centos7 to finish the\ninstallation or upgrade!\n"
echo -e "\nThe README file is located here: %{_docdir}/%{name}-%{version}.\n"
%preun
if [ $1 -eq 0 ] ; then
# Package removal, not upgrade
/bin/systemctl --no-reload disable zoneminder.service > /dev/null 2>&1 || :
/bin/systemctl stop zoneminder.service > /dev/null 2>&1 || :
# echo -e "\nRemoving ZoneMinder SELinux policy module. Please wait.\n"
# /usr/sbin/semodule -r local_zoneminder.pp
fi
%postun
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
if [ $1 -ge 1 ] ; then
# Package upgrade, not uninstall
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
fi
%triggerun -- zoneminder < 1.25.0-4
# Save the current service runlevel info
# User must manually run systemd-sysv-convert --apply zoneminder
# to migrate them to systemd targets
/usr/bin/systemd-sysv-convert --save zoneminder >/dev/null 2>&1 ||:
# Run these because the SysV package being removed won't do them
/sbin/chkconfig --del zoneminder >/dev/null 2>&1 || :
/bin/systemctl try-restart zoneminder.service >/dev/null 2>&1 || :
%files
%defattr(-,root,root,-)
%doc AUTHORS BUGS ChangeLog COPYING LICENSE NEWS README.md distros/redhat/README.Centos7 distros/redhat/README.https distros/redhat/jscalendar-doc
%doc distros/redhat/local_zoneminder.te
%config %attr(640,root,%{zmgid_final}) /etc/zm/zm.conf
%config(noreplace) %attr(644,root,root) /etc/httpd/conf.d/zoneminder.conf
%config(noreplace) /etc/tmpfiles.d/zoneminder.conf
%config(noreplace) /etc/logrotate.d/zoneminder
%{_unitdir}/zoneminder.service
%{_bindir}/zma
%{_bindir}/zmaudit.pl
%{_bindir}/zmc
%{_bindir}/zmcontrol.pl
%{_bindir}/zmdc.pl
%{_bindir}/zmf
%{_bindir}/zmfilter.pl
%{_bindir}/zmpkg.pl
%{_bindir}/zmtrack.pl
%{_bindir}/zmtrigger.pl
%{_bindir}/zmu
%{_bindir}/zmupdate.pl
%{_bindir}/zmvideo.pl
%{_bindir}/zmwatch.pl
%{_bindir}/zmcamtool.pl
%{_bindir}/zmsystemctl.pl
%{_bindir}/zmtelemetry.pl
%{_bindir}/zmx10.pl
%{_bindir}/zmonvif-probe.pl
%{perl_vendorlib}/ZoneMinder*
%{perl_vendorarch}/auto/ZoneMinder/.packlist
%{perl_vendorarch}/auto/ONVIF/.packlist
%{perl_vendorlib}/ONVIF*
%{perl_vendorlib}/WSDiscovery*
%{perl_vendorlib}/WSSecurity*
%{perl_vendorlib}/WSNotification*
%{_mandir}/man*/*
%dir %{_libexecdir}/zoneminder
%{_libexecdir}/zoneminder/cgi-bin
%dir %{_datadir}/zoneminder
%{_datadir}/zoneminder/db
%{_datadir}/zoneminder/www
%{_datadir}/polkit-1/actions/com.zoneminder.systemctl.policy
%{_datadir}/polkit-1/rules.d/com.zoneminder.systemctl.rules
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/events
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/images
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/sock
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/swap
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/lib/zoneminder/temp
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/log/zoneminder
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /var/spool/zoneminder-upload
%dir %attr(755,%{zmuid_final},%{zmgid_final}) /run/zoneminder
%changelog
* Thu Mar 3 2016 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.30.0
- Bump version fo 1.30.0 release.
* Mon Sep 7 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Require https, disable selinux module, freshen dB on updates.
* Sun Feb 8 2015 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.1
- Initial release for CentOS 7.
* Sun Oct 5 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.28.0
- Bump version for 1.28.0 release.
* Fri Mar 14 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Tweak build requirements for cmake
* Sat Feb 01 2014 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.27
- Add zmcamtool.pl. Bump version for 1.27 release.
* Mon Dec 16 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.5
- This is a bug fixe release
- RTSP fixes, cmake enhancements, couple other misc fixes
* Mon Oct 07 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Initial cmake build.
* Sat Oct 05 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.4
- Fedora specific path changes have been moved to zoneminder-1.26.0-defaults.patch
- All files are now part of the zoneminder source tree. Update specfile accordingly.
* Sat Sep 21 2013 Andrew Bauer <knnniggett@users.sourceforge.net> - 1.26.3
- Initial rebuild for ZoneMinder 1.26.3 release.
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Mon Jan 21 2013 Adam Tkac <atkac redhat com> - 1.25.0-12
- rebuild due to "jpeg8-ABI" feature drop
* Mon Jan 7 2013 Remi Collet <rcollet@redhat.com> - 1.25.0-11
- fix configuration file for httpd 2.4, #871502
* Fri Dec 21 2012 Adam Tkac <atkac redhat com> - 1.25.0-10
- rebuild against new libjpeg
* Thu Aug 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-9
- Add patch to work around v4l2 api breakage in 3.5 kernel.
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.25.0-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sat Jun 23 2012 Petr Pisar <ppisar@redhat.com> - 1.25.0-7
- Perl 5.16 rebuild
* Wed Mar 21 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-6
- Fix stupid thinko in sql modifications.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-5
- Clean up macro usage.
* Sat Feb 25 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-4
- Convert to systemd.
- Add tmpfiles.d configuration since the initscript isn't around to create
/run/zoneminder.
- Remove some pointless executable permissions.
- Add logrotate file.
* Wed Feb 22 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-3
- Update README.Fedora to reference systemctl and mention timezone info in
php.ini.
- Add proper default for EYEZM_LOG_TO_FILE.
* Thu Feb 09 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-2
- Rebuild for new pcre.
* Thu Jan 19 2012 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.25.0-1
- Update to 1.25.0
- Fix gcc4.7 build problems.
- Drop gcc4.4 build fixes; for whatever reason they now break the build.
- Clean up old patches.
- Force setting of ZM_TMPDIR and ZM_RUNDIR.
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.4-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-3
- Re-add the dist-tag that somehow got lost.
* Thu Sep 15 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-2
- Add patch for bug 711780 - fix syntax issue in Mapped.pm.
- Undo that patch, and undo another which was the cause of the whole mess.
- Fix up other patches so ZM_PATH_BUILD is both defined and useful.
- Make sure database creation mods actually take.
- Update Fedora-specific docs with some additional info.
- Use bundled mootools (javascript, so no guideline violation).
- Update download location.
- Update the gcrypt patch to actually work.
- Upstream changed the tarball without changing the version to patch a
vulnerability, so redownload.
* Sun Aug 14 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.4-1
- Initial attempt to upgrade to 1.24.4.
- Add patch from BZ 460310 to build against libgcrypt instead of requiring the
gnutls openssl libs.
* Thu Jul 21 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-7.20110324svn3310
- Perl mass rebuild
* Wed Jul 20 2011 Petr Sabata <contyk@redhat.com> - 1.24.3-6.20110324svn3310
- Perl mass rebuild
* Mon May 09 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-5.20110324svn3310
- Bump for gnutls update.
* Thu Mar 24 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-4.20110324svn3310
- Update to latest 1.24.3 subversion. Turns out that what upstream was calling
1.24.3 is really just an occasionally updated devel snapshot.
- Rebase various patches.
* Wed Mar 23 2011 Dan Horák <dan@danny.cz> - 1.24.3-3
- rebuilt for mysql 5.5.10 (soname bump in libmysqlclient)
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Tue Jan 25 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.3-1
- Update to latest upstream version.
- Rebase patches.
- Initial incomplete attempt to disable v4l1 support.
* Fri Jan 21 2011 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-6
- Unbundle cambozola; instead link to the separately pacakged copy.
- Remove BuildRoot:, %%clean and buildroot cleaning in %%install.
- Git rid of mixed space/tab usage by removing all tabs.
- Remove unnecessary Conflicts: line.
- Attempt to force short_open_tag on for the code directories.
- Move default location of sockets, swaps, logfiles and some temporary files to
make more sense and allow things to work better with a future selinux policy.
- Fix errors in README.Fedora.
* Wed Jun 02 2010 Marcela Maslanova <mmaslano@redhat.com> - 1.24.2-5
- Mass rebuild with perl-5.12.0
* Fri Dec 4 2009 Stepan Kasal <skasal@redhat.com> - 1.24.2-4
- rebuild against perl 5.10.1
- use Perl vendorarch and archlib variables correctly
* Mon Jul 27 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.24.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-2
- Bump release since 1.24.2-1 was mistakenly tagged a few months ago.
* Wed Jul 22 2009 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.24.2-1
- Initial update to 1.24.2.
- Rebase patches.
- Update mootools download location.
- Update to mootools 1.2.3.
- Add additional dependencies for some optional features.
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-3
- Remove unused Sys::Mmap perl dependency RPM is finding
* Sat Apr 11 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-2
- Update gcc44 patch to disable -frepo, seems to be broken with gcc44
- Added noffmpeg patch to make building outside mock easier
* Sat Mar 21 2009 Martin Ebourne <martin@zepler.org> - 1.24.1-1
- Patch for gcc 4.4 compilation errors
- Upgrade to 1.24.1
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.23.3-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Sat Jan 24 2009 Caolán McNamara <caolanm@redhat.com> - 1.23.3-3
- rebuild for dependencies
* Mon Dec 15 2008 Martin Ebourne <martin@zepler.org> - 1.23.3-2
- Fix permissions on zm.conf
* Fri Jul 11 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.23.3-1
- Initial attempt at packaging 1.23.
* Tue Jul 1 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-15
- Add perl module compat dependency, bz #453590
* Tue May 6 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-14
- Remove default runlevel, bz #441315
* Mon Apr 28 2008 Jason L Tibbitts III <tibbs@math.uh.edu> - 1.22.3-13
- Backport patch for CVE-2008-1381 from 1.23.3 to 1.22.3.
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.22.3-12
- Autorebuild for GCC 4.3
* Thu Jan 3 2008 Martin Ebourne <martin@zepler.org> - 1.22.3-11
- Fix compilation on gcc 4.3
* Thu Dec 6 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-10
- Rebuild for new openssl
* Thu Aug 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-8
- Fix licence tag
* Thu Jul 12 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-7
- Fixes from testing by Jitz including missing dependencies and database creation
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-6
- Disable crashtrace on ppc
* Sat Jun 30 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-5
- Fix uid for directories in /var/lib/zoneminder
* Tue Jun 26 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-4
- Added perl Archive::Tar dependency
- Disabled web interface due to lack of access control on the event images
* Sun Jun 10 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-3
- Changes recommended in review by Jason Tibbitts
* Mon Apr 2 2007 Martin Ebourne <martin@zepler.org> - 1.22.3-2
- Standardised on package name of zoneminder
* Thu Dec 28 2006 Martin Ebourne <martin@zepler.org> - 1.22.3-1
- First version. Uses some parts from zm-1.20.1 by Corey DeLasaux and Serg Oskin

View File

@ -0,0 +1,18 @@
# ZoneMinder systemd unit file for CentOS 7
[Unit]
Description=ZoneMinder CCTV recording and security system
After=network.target mariadb.service httpd.service
Requires=mariadb.service httpd.service
[Service]
User=@WEB_USER@
Type=forking
ExecStart=@BINDIR@/zmpkg.pl start
ExecReload=@BINDIR@/zmpkg.pl restart
ExecStop=@BINDIR@/zmpkg.pl stop
PIDFile="@ZM_RUNDIR@/zm.pid"
[Install]
WantedBy=multi-user.target

View File

View File

@ -0,0 +1,3 @@
D @ZM_RUNDIR@ 0755 @WEB_USER@ @WEB_GROUP@
D @ZM_TMPDIR@ 0755 @WEB_USER@ @WEB_GROUP@
D @ZM_SOCKDIR@ 0755 @WEB_USER@ @WEB_GROUP@

10
distros/ubuntu1204/NEWS Normal file
View File

@ -0,0 +1,10 @@
zoneminder (1.28.1-1) unstable; urgency=low
This version is no longer automatically initialize or upgrade database.
See README.Debian for details.
Changed installation paths (please correct your web server configuration):
/usr/share/zoneminder --> /usr/share/zoneminder/www
/usr/lib/cgi-bin --> /usr/lib/zoneminder/cgi-bin
-- Dmitry Smirnov <onlyjob@debian.org> Tue, 31 Mar 2015 15:12:17 +1100

View File

@ -1,9 +1,120 @@
zoneminder for Debian Zoneminder for Debian
--------------------- ---------------------
There is one manual step to get the web interface working. Initializing database
You need to link /etc/zm/apache.conf to /etc/apache2/conf.d/zoneminder.conf, ---------------------
then reload the apache config (i.e. /etc/init.d/apache2 reload)
pv /usr/share/zoneminder/db/zm_create.sql | sudo mysql --defaults-file=/etc/mysql/debian.cnf
OR
cat /usr/share/zoneminder/db/zm_create.sql | sudo mysql --defaults-file=/etc/mysql/debian.cnf
echo 'grant lock tables,alter,create,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";'\
| sudo mysql --defaults-file=/etc/mysql/debian.cnf mysql
Hint: generate secure password with `pwgen` and update "/etc/zm/zm.conf"
accordingly.
The following command can help to ensure that zoneminder can read its
configuration file:
chgrp -c www-data /etc/zm/zm.conf
Upgrading database
------------------
Prior to 1.28.1 database upgrade was performed automatically.
"zoneminder" service will refuse to start with outdated database.
Assuming that database is on "localhost" then the following command can be
used to upgrade "zm" database:
zmupdate.pl
Additional permissions may be required to perform upgrade:
echo 'grant lock tables, create, alter on zm.* to 'zmuser'@localhost identified by "zmpass";'\
| sudo mysql --defaults-file=/etc/mysql/debian.cnf mysql
The following command prints the current version of zoneminder database:
echo 'select Value from Config where Name = "ZM_DYN_CURR_VERSION";' \
| sudo mysql --defaults-file=/etc/mysql/debian.cnf --skip-column-names zm
Enabling service
----------------
By default Zoneminder service is not starting automatically and need to be
manually activated once database is configured:
On systemd:
sudo systemctl enable zoneminder.service
On SysV:
sudo update-rc.d zoneminder enable
Web server set-up
-----------------
There are few manual steps to get the web interface working:
## Apache2
Apache can be configured as folder "/zm" using sample .conf:
sudo a2enconf zoneminder
Alternatively Apache web site configuration template can be used to setup
zoneminder as "http://zoneminder":
sudo cp -v /usr/share/doc/zoneminder/examples/apache.conf /etc/apache2/sites-available/
sudo a2ensite zoneminder.conf
Common configuration steps for Apache2:
sudo a2enmod cgi
sudo service apache2 reload
## nginx / fcgiwrap
Nginx needs "php5-fpm" package to support PHP and "fcgiwrap" package
for binary "cgi-bin" applications:
sudo apt-get install php5-fpm fcgiwrap
To enable a URL alias that makes Zoneminder available from
http://yourserver/zm
the following line is to be added to "server" section of a web site
configuration:
include /usr/share/doc/zoneminder/examples/nginx.conf;
For "default" web site it would be sufficient to include the above
statement to the file
/etc/nginx/sites-enabled/default
To avoid problems with feeds from multiple cameras "fcgiwrap" should be
configured to start at least as many processes as there are cameras.
It can be done by adjusting DAEMON_OPTS in "/etc/default/fcgiwrap".
Systemd users may be affected by the following bug:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=792705
## Note:
When Zoneminder web site is running it may be necessary to set
Options/Paths/PATH_ZMS to "/zm/cgi-bin/nph-zms" or according to chosen web
site configuration.
Changing the location for images and events Changing the location for images and events
------------------------------------------- -------------------------------------------
@ -33,8 +144,6 @@ These lines in fstab could allow you to bind-mount an alternate location
/dev/sdX1 /var/cache/zoneminder/images ext3 defaults 0 2 /dev/sdX1 /var/cache/zoneminder/images ext3 defaults 0 2
/dev/sdX2 /var/cache/zoneminder/events ext3 defaults 0 2 /dev/sdX2 /var/cache/zoneminder/events ext3 defaults 0 2
-- Peter Howard <pjh@northern-ridge.com.au>, Sun, 16 Jan 2010 01:35:51 +1100 -- Peter Howard <pjh@northern-ridge.com.au>, Sun, 16 Jan 2010 01:35:51 +1100
Access to /dev/video* Access to /dev/video*

View File

@ -0,0 +1,12 @@
## Separate substantial /usr/share into its own arch-all package.
## Decide how to handle database updates.
* Consider possibility that database may be on another machine (#469239).
* Consider dbconfig-common? Probably not (what if database is not on localhost?).
### Run `zmupdate.pl` from service control scripts (init.d, service) on start?
Automatic upgrade will break "one DB, many zoneminders" setup (unimportant?).

Some files were not shown because too many files have changed in this diff Show More