Merge branch 'plugin_support_cmake' into plugin_support
This commit is contained in:
commit
1b42dd90ef
|
@ -56,7 +56,12 @@ mark_as_advanced(
|
||||||
ZM_PERL_MM_PARMS
|
ZM_PERL_MM_PARMS
|
||||||
ZM_PERL_SEARCH_PATH
|
ZM_PERL_SEARCH_PATH
|
||||||
ZM_TARGET_DISTRO
|
ZM_TARGET_DISTRO
|
||||||
ZM_CONFIG_DIR)
|
ZM_CONFIG_DIR
|
||||||
|
ZM_PLUGIN_SUPPORT
|
||||||
|
ZM_PLUGINSLIBDIR
|
||||||
|
ZM_PLUGINSPKGLIBDIR
|
||||||
|
ZM_PLUGINSCONFDIR
|
||||||
|
ZM_PLUGINSWEBDIR)
|
||||||
|
|
||||||
set(ZM_RUNDIR "/var/run/zm" CACHE PATH
|
set(ZM_RUNDIR "/var/run/zm" CACHE PATH
|
||||||
"Location of transient process files, default: /var/run/zm")
|
"Location of transient process files, default: /var/run/zm")
|
||||||
|
@ -119,6 +124,25 @@ set(ZM_PERL_SEARCH_PATH "" CACHE PATH
|
||||||
installed outside Perl's default search path.")
|
installed outside Perl's default search path.")
|
||||||
set(ZM_TARGET_DISTRO "" CACHE STRING
|
set(ZM_TARGET_DISTRO "" CACHE STRING
|
||||||
"Build ZoneMinder for a specific distribution. Currently, valid names are: f21, f20, el6, OS13")
|
"Build ZoneMinder for a specific distribution. Currently, valid names are: f21, f20, el6, OS13")
|
||||||
|
set(ZM_PLUGIN_SUPPORT "OFF" CACHE BOOL
|
||||||
|
"Set to ON to enable plugins support. This is EXPERIMENTAL. default: OFF")
|
||||||
|
if(ZM_PLUGIN_SUPPORT)
|
||||||
|
set(ZM_PREFIX ${CMAKE_INSTALL_PREFIX})
|
||||||
|
set(ZM_PLUGINSLIBDIR "\${prefix}/${CMAKE_INSTALL_LIBDIR}" CACHE PATH
|
||||||
|
"Location of the plugin files, default: ${CMAKE_INSTALL_LIBDIR}")
|
||||||
|
set(ZM_PLUGINSPKGLIBDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/plugins" CACHE PATH
|
||||||
|
"Location of the plugin files, default: <prefix>/${CMAKE_INSTALL_LIBEXECDIR}/zoneminder/plugins")
|
||||||
|
set(ZM_PLUGINSCONFDIR "/${CMAKE_INSTALL_SYSCONFDIR}/plugins.d" CACHE PATH
|
||||||
|
"Location of the plugin files, default: /${CMAKE_INSTALL_SYSCONFDIR}/plugins.d")
|
||||||
|
set(ZM_PLUGINSWEBDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder/plugins" CACHE PATH
|
||||||
|
"Location of the plugin files, default: <prefix>/${CMAKE_INSTALL_DATADIR}/zoneminder/plugins")
|
||||||
|
set(ZM_PROJECTNAME ${CMAKE_PROJECT_NAME})
|
||||||
|
set(ZM_VERSION ${zoneminder_VERSION})
|
||||||
|
set(ZM_PLUGINSEXT ".so" CACHE STRING
|
||||||
|
"Plugin extension, default: .so")
|
||||||
|
add_definitions(-DDEFAULT_PLUGIN_EXT=\"${ZM_PLUGIN_EXT}\")
|
||||||
|
add_definitions(-DZM_PLUGINS_ON=1)
|
||||||
|
endif(ZM_PLUGIN_SUPPORT)
|
||||||
|
|
||||||
# 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 "f21") OR (ZM_TARGET_DISTRO STREQUAL "f20"))
|
if((ZM_TARGET_DISTRO STREQUAL "f21") OR (ZM_TARGET_DISTRO STREQUAL "f20"))
|
||||||
|
@ -207,6 +231,7 @@ find_package(ZLIB)
|
||||||
if(ZLIB_FOUND)
|
if(ZLIB_FOUND)
|
||||||
set(HAVE_LIBZLIB 1)
|
set(HAVE_LIBZLIB 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${ZLIB_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${ZLIB_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lz")
|
||||||
include_directories("${ZLIB_INCLUDE_DIR}")
|
include_directories("${ZLIB_INCLUDE_DIR}")
|
||||||
set(CMAKE_REQUIRED_INCLUDES "${ZLIB_INCLUDE_DIR}")
|
set(CMAKE_REQUIRED_INCLUDES "${ZLIB_INCLUDE_DIR}")
|
||||||
check_include_file("zlib.h" HAVE_ZLIB_H)
|
check_include_file("zlib.h" HAVE_ZLIB_H)
|
||||||
|
@ -222,6 +247,7 @@ if(NOT ZM_NO_CURL)
|
||||||
if(CURL_FOUND)
|
if(CURL_FOUND)
|
||||||
set(HAVE_LIBCURL 1)
|
set(HAVE_LIBCURL 1)
|
||||||
list(APPEND ZM_BIN_LIBS ${CURL_LIBRARIES})
|
list(APPEND ZM_BIN_LIBS ${CURL_LIBRARIES})
|
||||||
|
set(LIBS "${LIBS} -lcurl")
|
||||||
include_directories(${CURL_INCLUDE_DIRS})
|
include_directories(${CURL_INCLUDE_DIRS})
|
||||||
set(CMAKE_REQUIRED_INCLUDES ${CURL_INCLUDE_DIRS})
|
set(CMAKE_REQUIRED_INCLUDES ${CURL_INCLUDE_DIRS})
|
||||||
check_include_file("curl/curl.h" HAVE_CURL_CURL_H)
|
check_include_file("curl/curl.h" HAVE_CURL_CURL_H)
|
||||||
|
@ -236,6 +262,7 @@ find_package(JPEG)
|
||||||
if(JPEG_FOUND)
|
if(JPEG_FOUND)
|
||||||
set(HAVE_LIBJPEG 1)
|
set(HAVE_LIBJPEG 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${JPEG_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${JPEG_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -ljpeg")
|
||||||
#link_directories(${JPEG_LIBRARY})
|
#link_directories(${JPEG_LIBRARY})
|
||||||
include_directories("${JPEG_INCLUDE_DIR}")
|
include_directories("${JPEG_INCLUDE_DIR}")
|
||||||
set(CMAKE_REQUIRED_INCLUDES "${JPEG_INCLUDE_DIR}")
|
set(CMAKE_REQUIRED_INCLUDES "${JPEG_INCLUDE_DIR}")
|
||||||
|
@ -255,6 +282,7 @@ if(OPENSSL_FOUND)
|
||||||
set(HAVE_LIBOPENSSL 1)
|
set(HAVE_LIBOPENSSL 1)
|
||||||
set(HAVE_LIBCRYPTO 1)
|
set(HAVE_LIBCRYPTO 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${OPENSSL_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${OPENSSL_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lssl -lcrypto")
|
||||||
include_directories("${OPENSSL_INCLUDE_DIR}")
|
include_directories("${OPENSSL_INCLUDE_DIR}")
|
||||||
set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}")
|
set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}")
|
||||||
check_include_file("openssl/md5.h" HAVE_OPENSSL_MD5_H)
|
check_include_file("openssl/md5.h" HAVE_OPENSSL_MD5_H)
|
||||||
|
@ -268,6 +296,7 @@ find_library(PTHREAD_LIBRARIES pthread)
|
||||||
if(PTHREAD_LIBRARIES)
|
if(PTHREAD_LIBRARIES)
|
||||||
set(HAVE_LIBPTHREAD 1)
|
set(HAVE_LIBPTHREAD 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${PTHREAD_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${PTHREAD_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lpthread")
|
||||||
find_path(PTHREAD_INCLUDE_DIR pthread.h)
|
find_path(PTHREAD_INCLUDE_DIR pthread.h)
|
||||||
if(PTHREAD_INCLUDE_DIR)
|
if(PTHREAD_INCLUDE_DIR)
|
||||||
include_directories("${PTHREAD_INCLUDE_DIR}")
|
include_directories("${PTHREAD_INCLUDE_DIR}")
|
||||||
|
@ -289,6 +318,7 @@ find_library(PCRE_LIBRARIES pcre)
|
||||||
if(PCRE_LIBRARIES)
|
if(PCRE_LIBRARIES)
|
||||||
set(HAVE_LIBPCRE 1)
|
set(HAVE_LIBPCRE 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${PCRE_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${PCRE_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lpcre")
|
||||||
find_path(PCRE_INCLUDE_DIR pcre.h)
|
find_path(PCRE_INCLUDE_DIR pcre.h)
|
||||||
if(PCRE_INCLUDE_DIR)
|
if(PCRE_INCLUDE_DIR)
|
||||||
include_directories("${PCRE_INCLUDE_DIR}")
|
include_directories("${PCRE_INCLUDE_DIR}")
|
||||||
|
@ -306,6 +336,7 @@ find_library(GCRYPT_LIBRARIES gcrypt)
|
||||||
if(GCRYPT_LIBRARIES)
|
if(GCRYPT_LIBRARIES)
|
||||||
set(HAVE_LIBGCRYPT 1)
|
set(HAVE_LIBGCRYPT 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${GCRYPT_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${GCRYPT_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lgcrypt")
|
||||||
find_path(GCRYPT_INCLUDE_DIR gcrypt.h)
|
find_path(GCRYPT_INCLUDE_DIR gcrypt.h)
|
||||||
if(GCRYPT_INCLUDE_DIR)
|
if(GCRYPT_INCLUDE_DIR)
|
||||||
include_directories("${GCRYPT_INCLUDE_DIR}")
|
include_directories("${GCRYPT_INCLUDE_DIR}")
|
||||||
|
@ -327,6 +358,7 @@ endif(NOT GNUTLS_LIBRARIES)
|
||||||
if(GNUTLS_LIBRARIES)
|
if(GNUTLS_LIBRARIES)
|
||||||
set(HAVE_LIBGNUTLS 1)
|
set(HAVE_LIBGNUTLS 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${GNUTLS_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${GNUTLS_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lgnutls-openssl")
|
||||||
find_path(GNUTLS_INCLUDE_DIR gnutls/gnutls.h)
|
find_path(GNUTLS_INCLUDE_DIR gnutls/gnutls.h)
|
||||||
if(GNUTLS_INCLUDE_DIR)
|
if(GNUTLS_INCLUDE_DIR)
|
||||||
include_directories("${GNUTLS_INCLUDE_DIR}")
|
include_directories("${GNUTLS_INCLUDE_DIR}")
|
||||||
|
@ -345,6 +377,7 @@ find_library(MYSQLCLIENT_LIBRARIES mysqlclient PATH_SUFFIXES mysql)
|
||||||
if(MYSQLCLIENT_LIBRARIES)
|
if(MYSQLCLIENT_LIBRARIES)
|
||||||
set(HAVE_LIBMYSQLCLIENT 1)
|
set(HAVE_LIBMYSQLCLIENT 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${MYSQLCLIENT_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${MYSQLCLIENT_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lmysqlclient")
|
||||||
find_path(MYSQLCLIENT_INCLUDE_DIR mysql/mysql.h)
|
find_path(MYSQLCLIENT_INCLUDE_DIR mysql/mysql.h)
|
||||||
if(MYSQLCLIENT_INCLUDE_DIR)
|
if(MYSQLCLIENT_INCLUDE_DIR)
|
||||||
include_directories("${MYSQLCLIENT_INCLUDE_DIR}")
|
include_directories("${MYSQLCLIENT_INCLUDE_DIR}")
|
||||||
|
@ -370,6 +403,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}")
|
||||||
|
set(LIBS "${LIBS} -lavformat")
|
||||||
find_path(AVFORMAT_INCLUDE_DIR "libavformat/avformat.h")
|
find_path(AVFORMAT_INCLUDE_DIR "libavformat/avformat.h")
|
||||||
if(AVFORMAT_INCLUDE_DIR)
|
if(AVFORMAT_INCLUDE_DIR)
|
||||||
include_directories("${AVFORMAT_INCLUDE_DIR}")
|
include_directories("${AVFORMAT_INCLUDE_DIR}")
|
||||||
|
@ -387,6 +421,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}")
|
||||||
|
set(LIBS "${LIBS} -lavcodec")
|
||||||
find_path(AVCODEC_INCLUDE_DIR "libavcodec/avcodec.h")
|
find_path(AVCODEC_INCLUDE_DIR "libavcodec/avcodec.h")
|
||||||
if(AVCODEC_INCLUDE_DIR)
|
if(AVCODEC_INCLUDE_DIR)
|
||||||
include_directories("${AVCODEC_INCLUDE_DIR}")
|
include_directories("${AVCODEC_INCLUDE_DIR}")
|
||||||
|
@ -404,6 +439,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}")
|
||||||
|
set(LIBS "${LIBS} -lavdevice")
|
||||||
find_path(AVDEVICE_INCLUDE_DIR "libavdevice/avdevice.h")
|
find_path(AVDEVICE_INCLUDE_DIR "libavdevice/avdevice.h")
|
||||||
if(AVDEVICE_INCLUDE_DIR)
|
if(AVDEVICE_INCLUDE_DIR)
|
||||||
include_directories("${AVDEVICE_INCLUDE_DIR}")
|
include_directories("${AVDEVICE_INCLUDE_DIR}")
|
||||||
|
@ -421,6 +457,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}")
|
||||||
|
set(LIBS "${LIBS} -lavutil")
|
||||||
find_path(AVUTIL_INCLUDE_DIR "libavutil/avutil.h")
|
find_path(AVUTIL_INCLUDE_DIR "libavutil/avutil.h")
|
||||||
if(AVUTIL_INCLUDE_DIR)
|
if(AVUTIL_INCLUDE_DIR)
|
||||||
include_directories("${AVUTIL_INCLUDE_DIR}")
|
include_directories("${AVUTIL_INCLUDE_DIR}")
|
||||||
|
@ -439,6 +476,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}")
|
||||||
|
set(LIBS "${LIBS} -lswscale")
|
||||||
find_path(SWSCALE_INCLUDE_DIR "libswscale/swscale.h")
|
find_path(SWSCALE_INCLUDE_DIR "libswscale/swscale.h")
|
||||||
if(SWSCALE_INCLUDE_DIR)
|
if(SWSCALE_INCLUDE_DIR)
|
||||||
include_directories("${SWSCALE_INCLUDE_DIR}")
|
include_directories("${SWSCALE_INCLUDE_DIR}")
|
||||||
|
@ -468,6 +506,7 @@ if(NOT ZM_NO_LIBVLC)
|
||||||
if(LIBVLC_LIBRARIES)
|
if(LIBVLC_LIBRARIES)
|
||||||
set(HAVE_LIBVLC 1)
|
set(HAVE_LIBVLC 1)
|
||||||
list(APPEND ZM_BIN_LIBS "${LIBVLC_LIBRARIES}")
|
list(APPEND ZM_BIN_LIBS "${LIBVLC_LIBRARIES}")
|
||||||
|
set(LIBS "${LIBS} -lvlc")
|
||||||
find_path(LIBVLC_INCLUDE_DIR "vlc/vlc.h")
|
find_path(LIBVLC_INCLUDE_DIR "vlc/vlc.h")
|
||||||
if(LIBVLC_INCLUDE_DIR)
|
if(LIBVLC_INCLUDE_DIR)
|
||||||
include_directories("${LIBVLC_INCLUDE_DIR}")
|
include_directories("${LIBVLC_INCLUDE_DIR}")
|
||||||
|
|
30
configure.ac
30
configure.ac
|
@ -229,33 +229,41 @@ if test "$ENABLE_PLUGIN_SUPPORT" == "yes"; then
|
||||||
If you really want plugin support you must not call configure with
|
If you really want plugin support you must not call configure with
|
||||||
--enable-shared=no or --disabled-shared])
|
--enable-shared=no or --disabled-shared])
|
||||||
fi
|
fi
|
||||||
|
ZM_PREFIX="${prefix}"
|
||||||
|
AC_SUBST(ZM_PREFIX)
|
||||||
|
ZM_PLUGINSLIBDIR="${libdir}"
|
||||||
|
AC_SUBST(ZM_PLUGINSLIBDIR)
|
||||||
AC_ARG_WITH(pluginsdir,
|
AC_ARG_WITH(pluginsdir,
|
||||||
[ --with-pluginsdir=<path> plugins directory (requires --enable-plugin-support=yes)],
|
[ --with-pluginsdir=<path> plugins directory (requires --enable-plugin-support=yes)],
|
||||||
[PLUGINSLIBDIR=$with_pluginsdir],
|
[ZM_PLUGINSPKGLIBDIR=$with_pluginsdir],
|
||||||
AC_MSG_ERROR([Plugin support is enabled.
|
AC_MSG_ERROR([Plugin support is enabled.
|
||||||
You must call configure with the --with-pluginsdir options.
|
You must call configure with the --with-pluginsdir options.
|
||||||
This tells configure where to install plugin library files.
|
This tells configure where to install plugin library files.
|
||||||
e.g. --with-pluginsdir=/usr/lib/zoneminder/plugins])
|
e.g. --with-pluginsdir=/usr/lib/zoneminder/plugins])
|
||||||
)
|
)
|
||||||
AC_SUBST(PLUGINSLIBDIR)
|
AC_SUBST(ZM_PLUGINSPKGLIBDIR)
|
||||||
PLUGINSCONFDIR="${sysconfdir}/plugins.d"
|
ZM_PLUGINSCONFDIR="${sysconfdir}/plugins.d"
|
||||||
AC_ARG_WITH(pluginsconfdir,
|
AC_ARG_WITH(pluginsconfdir,
|
||||||
[ --with-pluginsconfdir=<path> directory of plugin configuration files (requires --enable-plugin-support=yes)],
|
[ --with-pluginsconfdir=<path> directory of plugin configuration files (requires --enable-plugin-support=yes)],
|
||||||
[PLUGINSCONFDIR=$with_pluginsconfdir],
|
[ZM_PLUGINSCONFDIR=$with_pluginsconfdir],
|
||||||
AC_MSG_WARN([You can call configure with the --with-pluginsconfdir options.
|
AC_MSG_WARN([You can call configure with the --with-pluginsconfdir options.
|
||||||
This tells configure where to install the plugin configuration files.
|
This tells configure where to install the plugin configuration files.
|
||||||
The default is "${PLUGINSCONFDIR}".
|
The default is "${PLUGINSCONFDIR}".
|
||||||
e.g. --with-pluginsconfdir=/etc/zm/plugins.d])
|
e.g. --with-pluginsconfdir=/etc/zm/plugins.d])
|
||||||
)
|
)
|
||||||
AC_SUBST(PLUGINSCONFDIR)
|
AC_SUBST(ZM_PLUGINSCONFDIR)
|
||||||
PLUGINSWEBDIR="$WEB_PREFIX/plugins"
|
ZM_PLUGINSWEBDIR="$WEB_PREFIX/plugins"
|
||||||
AC_SUBST(PLUGINSWEBDIR)
|
AC_SUBST(ZM_PLUGINSWEBDIR)
|
||||||
|
ZM_PROJECTNAME="${PACKAGE}"
|
||||||
|
AC_SUBST(ZM_PROJECTNAME)
|
||||||
|
ZM_VERSION="${PACKAGE_VERSION}"
|
||||||
|
AC_SUBST(ZM_VERSION)
|
||||||
|
ZM_PLUGINSEXT=".so"
|
||||||
|
AC_SUBST(ZM_PLUGINSEXT)
|
||||||
|
AC_DEFINE_UNQUOTED(DEFAULT_PLUGIN_EXT,"${ZM_PLUGINSEXT}",[File extension to detect plugins])
|
||||||
AC_DEFINE(ZM_PLUGINS_ON,1,"Whether plugin support is switched on and compiled")
|
AC_DEFINE(ZM_PLUGINS_ON,1,"Whether plugin support is switched on and compiled")
|
||||||
PLUGINSEXT=".so"
|
|
||||||
AC_SUBST(PLUGINSEXT)
|
|
||||||
AC_DEFINE_UNQUOTED(DEFAULT_PLUGIN_EXT,"${PLUGINSEXT}",[File extension to detect plugins])
|
|
||||||
fi
|
fi
|
||||||
AM_CONDITIONAL([ZM_HAS_PLUGIN_SUPPORT], [test "x$ENABLE_PLUGIN_SUPPORT" = xyes])
|
AM_CONDITIONAL([ZM_PLUGIN_SUPPORT], [test "x$ENABLE_PLUGIN_SUPPORT" = xyes])
|
||||||
|
|
||||||
WEB_USER=apache
|
WEB_USER=apache
|
||||||
AC_ARG_WITH(webuser,
|
AC_ARG_WITH(webuser,
|
||||||
|
|
|
@ -0,0 +1,51 @@
|
||||||
|
zoneminder for Debian
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
There is one manual step to get the web interface working.
|
||||||
|
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)
|
||||||
|
|
||||||
|
Changing the location for images and events
|
||||||
|
-------------------------------------------
|
||||||
|
|
||||||
|
Zoneminder, in its upstream form, stores data in /usr/share/zoneminder/. This
|
||||||
|
package modifies that by changing /usr/share/zoneminder/images and
|
||||||
|
/usr/share/zoneminder/events to symlinks to directories under
|
||||||
|
/var/cache/zoneminder.
|
||||||
|
|
||||||
|
There are numerous places these could be put and ways to do it. But, at the
|
||||||
|
moment, if you change this, an upgrade will fail with a warning about these
|
||||||
|
locations having changed (the reason for this was that previously, an upgrade
|
||||||
|
would silently revert the changes and cause event loss - refer
|
||||||
|
bug #608793).
|
||||||
|
|
||||||
|
If you do want to change the location, here are a couple of suggestions.
|
||||||
|
|
||||||
|
These lines would mount /dev/sdX1 to /video_storage, and then 'link' /video_storage
|
||||||
|
to the locations that ZoneMinder expects them to be at.
|
||||||
|
|
||||||
|
/dev/sdX1 /video_storage ext4 defaults 0 2
|
||||||
|
/video_storage/zoneminder/images /var/cache/zoneminder/images none bind 0 2
|
||||||
|
/video_storage/zoneminder/events /var/cache/zoneminder/events none bind 0 2
|
||||||
|
|
||||||
|
or if you have a separate partition for each:
|
||||||
|
|
||||||
|
/dev/sdX1 /var/cache/zoneminder/images ext4 defaults 0 2
|
||||||
|
/dev/sdX2 /var/cache/zoneminder/events ext4 defaults 0 2
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-- Peter Howard <pjh@northern-ridge.com.au>, Sun, 16 Jan 2010 01:35:51 +1100
|
||||||
|
|
||||||
|
Access to /dev/video*
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
For cameras which require access to /dev/video*, zoneminder may need the
|
||||||
|
www-data user added to the video group in order to see those cameras:
|
||||||
|
|
||||||
|
adduser www-data video
|
||||||
|
|
||||||
|
Note that all web applications running on the zoneminder server will then have
|
||||||
|
access to all video devices on the system.
|
||||||
|
|
||||||
|
-- Vagrant Cascadian <vagrant@debian.org> Sun, 27 Mar 2011 13:06:56 -0700
|
|
@ -0,0 +1,9 @@
|
||||||
|
Alias /zm /usr/share/zoneminder
|
||||||
|
|
||||||
|
<Directory /usr/share/zoneminder>
|
||||||
|
php_flag register_globals off
|
||||||
|
Options Indexes FollowSymLinks
|
||||||
|
<IfModule mod_dir.c>
|
||||||
|
DirectoryIndex index.php
|
||||||
|
</IfModule>
|
||||||
|
</Directory>
|
|
@ -0,0 +1,48 @@
|
||||||
|
zoneminder (1.28.1+nmu1) experimental; urgency=medium
|
||||||
|
|
||||||
|
* Non-maintainer upload.
|
||||||
|
* Add plugin support
|
||||||
|
|
||||||
|
-- Emmanuel Papin <manupap01@gmail.com> Tue, 27 Jan 2015 19:23:07 +0100
|
||||||
|
|
||||||
|
zoneminder (1.28.0+nmu1) testing; urgency=medium
|
||||||
|
|
||||||
|
* Non-maintainer upload
|
||||||
|
* Split the debian package into several packages
|
||||||
|
* Switch to native source format
|
||||||
|
|
||||||
|
-- Emmanuel Papin <manupap01@gmail.com> Thu, 15 Jan 2015 20:00:08 +0100
|
||||||
|
|
||||||
|
zoneminder (1.28.0-0.2) testing; urgency=medium
|
||||||
|
|
||||||
|
* Non-maintainer upload.
|
||||||
|
* Upstream release for debian jessie
|
||||||
|
* Package dependencies updated
|
||||||
|
* debhelper version upgraded
|
||||||
|
* Standards-Version upgraded
|
||||||
|
* Use debhelper commands instead of standard commands
|
||||||
|
* Install man pages in /usr/share/man (patch added)
|
||||||
|
* Switch to quilt
|
||||||
|
* Switch to systemd
|
||||||
|
* Some lintian fixes
|
||||||
|
|
||||||
|
-- Emmanuel Papin <manupap01@gmail.com> Wed, 26 Nov 2014 00:26:01 +0100
|
||||||
|
|
||||||
|
zoneminder (1.28.0-0.1) stable; 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
|
|
@ -0,0 +1 @@
|
||||||
|
9
|
|
@ -0,0 +1,131 @@
|
||||||
|
Source: zoneminder
|
||||||
|
Section: net
|
||||||
|
Priority: optional
|
||||||
|
Maintainer: Isaac Connor <iconnor@connortechnology.com>
|
||||||
|
Build-Depends: debhelper (>= 9), po-debconf (>= 1.0), dh-systemd (>= 1.5), autoconf, automake, libphp-serialization-perl, libgnutls28-dev, libmysqlclient-dev | libmariadbclient-dev, libdbd-mysql-perl, libdate-manip-perl, libwww-perl, libjpeg8-dev | libjpeg9-dev | libjpeg62-turbo-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, libnetpbm10-dev, libavdevice-dev, libdevice-serialport-perl, libarchive-zip-perl, libmime-lite-perl, dh-autoreconf, libvlccore-dev, libvlc-dev, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev, libgcrypt11-dev | libgcrypt20-dev, libpolkit-gobject-1-dev, libdbi-perl, libnet-sftp-foreign-perl, libexpect-perl, libmime-tools-perl
|
||||||
|
Standards-Version: 3.9.6
|
||||||
|
|
||||||
|
Package: zoneminder
|
||||||
|
Section: metapackages
|
||||||
|
Architecture: all
|
||||||
|
Depends: ${misc:Depends},
|
||||||
|
libzoneminder-perl (>= ${source:Version}),
|
||||||
|
zoneminder-database (>= ${source:Version}),
|
||||||
|
zoneminder-core (>= ${binary:Version}),
|
||||||
|
zoneminder-ui-base (>= ${source:Version}),
|
||||||
|
zoneminder-ui-classic (>= ${source:Version}),
|
||||||
|
zoneminder-ui-mobile (>= ${source:Version}),
|
||||||
|
zoneminder-ui-xml (>= ${source:Version})
|
||||||
|
Description: Video camera security and surveillance solution (metapackage)
|
||||||
|
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: libzoneminder-perl
|
||||||
|
Section: perl
|
||||||
|
Architecture: all
|
||||||
|
Depends: ${misc:Depends}, ${perl:Depends}, libdbi-perl,
|
||||||
|
libdevice-serialport-perl, libimage-info-perl, libjson-any-perl,
|
||||||
|
libsys-mmap-perl, liburi-encode-perl, libwww-perl
|
||||||
|
Description: Perl libraries for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the libraries for the perl scripts, it can be used to
|
||||||
|
write custom interfaces as well.
|
||||||
|
|
||||||
|
Package: libzoneminder-dev
|
||||||
|
Section: libdevel
|
||||||
|
Architecture: any
|
||||||
|
Depends: ${misc:Depends}
|
||||||
|
Description: Development library for ZoneMinder plugins
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the necessary files to develop video analysis plugins.
|
||||||
|
|
||||||
|
Package: zoneminder-database
|
||||||
|
Section: database
|
||||||
|
Architecture: all
|
||||||
|
Depends: ${misc:Depends}, debconf, dbconfig-common,
|
||||||
|
mysql-client | mariadb-client
|
||||||
|
Recommends: mysql-server | mariadb-server
|
||||||
|
Description: Database management package for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the sql files and maintenance scripts to perform all the
|
||||||
|
database operations (installation, upgrade or removal) on a local or a remote
|
||||||
|
server.
|
||||||
|
|
||||||
|
Package: zoneminder-core
|
||||||
|
Section: video
|
||||||
|
Architecture: any
|
||||||
|
Depends: libzoneminder-perl (= ${source:Version}),
|
||||||
|
zoneminder-database (= ${source:Version}), ${shlibs:Depends}, ${misc:Depends},
|
||||||
|
${perl:Depends}, libarchive-tar-perl, libarchive-zip-perl, libdate-manip-perl,
|
||||||
|
libdbi-perl, libmodule-load-conditional-perl, libmime-lite-perl,
|
||||||
|
libmime-tools-perl, libnet-sftp-foreign-perl, libphp-serialization-perl,
|
||||||
|
debconf, ffmpeg | libav-tools, rsyslog | system-log-daemon, netpbm, zip,
|
||||||
|
policykit-1, apache2
|
||||||
|
Description: Core binaries and perl scripts for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the executable compiled binaries which do the main video
|
||||||
|
processing work and the perl scripts which perform helper and/or external
|
||||||
|
interface tasks.
|
||||||
|
|
||||||
|
Package: zoneminder-core-dbg
|
||||||
|
Priority: extra
|
||||||
|
Section: debug
|
||||||
|
Architecture: any
|
||||||
|
Depends: zoneminder-core (= ${binary:Version}), ${misc:Depends}
|
||||||
|
Description: Debugging symbols for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the debugging symbols for the executable compiled
|
||||||
|
binaries.
|
||||||
|
|
||||||
|
Package: zoneminder-ui-base
|
||||||
|
Section: web
|
||||||
|
Architecture: any
|
||||||
|
Depends: zoneminder-core (= ${binary:Version}), ${shlibs:Depends},
|
||||||
|
${misc:Depends}, debconf, apache2, libapache2-mod-php5 | libapache2-mod-fcgid,
|
||||||
|
php5, php5-mysql | php5-mysqlnd
|
||||||
|
Description: Essential files for ZoneMinder's web user interface
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the essential web files and maintenance scripts to set up
|
||||||
|
a basic web environment.
|
||||||
|
|
||||||
|
Package: zoneminder-ui-classic
|
||||||
|
Section: web
|
||||||
|
Architecture: all
|
||||||
|
Depends: zoneminder-ui-base (>= ${source:Version}), ${misc:Depends}
|
||||||
|
Description: Classic web user interface for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the classic web user interface.
|
||||||
|
|
||||||
|
Package: zoneminder-ui-mobile
|
||||||
|
Section: web
|
||||||
|
Architecture: all
|
||||||
|
Depends: zoneminder-ui-base (>= ${source:Version}), ${misc:Depends}
|
||||||
|
Description: Mobile web user interface for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides the web user interface for mobile devices.
|
||||||
|
|
||||||
|
Package: zoneminder-ui-xml
|
||||||
|
Section: web
|
||||||
|
Architecture: all
|
||||||
|
Depends: zoneminder-ui-base (>= ${source:Version}), ${misc:Depends}
|
||||||
|
Description: XML interface for ZoneMinder
|
||||||
|
ZoneMinder is a video camera security and surveillance solution.
|
||||||
|
.
|
||||||
|
This package provides a XML interface mainly intended for use with the eyeZm
|
||||||
|
iPhone Application, but can be used with any other custom programs as well.
|
|
@ -0,0 +1,22 @@
|
||||||
|
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.
|
|
@ -0,0 +1 @@
|
||||||
|
README.md
|
|
@ -0,0 +1,3 @@
|
||||||
|
usr/include/zoneminder
|
||||||
|
usr/lib/*/libzoneminder.a
|
||||||
|
usr/lib/*/pkgconfig/libzoneminder.pc
|
|
@ -0,0 +1,4 @@
|
||||||
|
usr/share/perl5/ZoneMinder
|
||||||
|
usr/share/perl5/ZoneMinder.pm
|
||||||
|
debian/tmp/usr/share/man/man3/ZoneMinder.3pm
|
||||||
|
debian/tmp/usr/share/man/man3/ZoneMinder::*
|
|
@ -0,0 +1,3 @@
|
||||||
|
[type: gettext/rfc822deb] zoneminder-core.templates
|
||||||
|
[type: gettext/rfc822deb] zoneminder-database.templates
|
||||||
|
[type: gettext/rfc822deb] zoneminder-ui-base.templates
|
|
@ -0,0 +1,252 @@
|
||||||
|
# debconf french translation file for ZoneMinder.
|
||||||
|
# Copyright (C) 2001-2008 Philip Coombes
|
||||||
|
# This file is distributed under the same license as the zoneminder package.
|
||||||
|
# First author: Emmanuel Papin <manupap01@gmail.com>, 2014.
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: zoneminder\n"
|
||||||
|
"Report-Msgid-Bugs-To: zoneminder@packages.debian.org\n"
|
||||||
|
"POT-Creation-Date: 2014-12-16 12:34+0100\n"
|
||||||
|
"PO-Revision-Date: 2014-12-07 00:40+0100\n"
|
||||||
|
"Last-Translator: Emmanuel Papin <manupap01@gmail.com>\n"
|
||||||
|
"Language-Team: French <debian-l10n-french@lists.debian.org>\n"
|
||||||
|
"Language: fr\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid "Delete this non empty directory?"
|
||||||
|
msgstr "Supprimer ce répertoire non vide ?"
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"A purge of the ZoneMinder package is performed but the directory '/var/cache/"
|
||||||
|
"zoneminder' is not empty so it will not be deleted."
|
||||||
|
msgstr ""
|
||||||
|
"Une purge du paquet ZoneMinder est en cours mais le répertoire '/var/cache/"
|
||||||
|
"zoneminder' n'est pas vide et sera donc conservé."
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"Please consider that this directory is designed to contain data resulting "
|
||||||
|
"from event detection. Therefore, \"proof of evidence\" could be lost!\""
|
||||||
|
msgstr ""
|
||||||
|
"Veuillez considérer que ce répertoire est conçu pour contenir des données "
|
||||||
|
"résultants de la détection d'événements. Par conséquent, des preuves "
|
||||||
|
"pourraient être perdues !"
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"If you are not sure of your decision, please do not delete this directory "
|
||||||
|
"but perform a manual checkup."
|
||||||
|
msgstr ""
|
||||||
|
"Si vous n'êtes pas sûr de votre décision, veuillez conserver ce répertoire "
|
||||||
|
"et effectuer une vérification manuelle."
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:2001
|
||||||
|
msgid "Deletion confirmed?"
|
||||||
|
msgstr "Supression confirmée ?"
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"You have allowed the deletion of directory '/var/cache/zoneminder' although "
|
||||||
|
"it may contain critical data."
|
||||||
|
msgstr ""
|
||||||
|
"Vous avez autorisé la suppression du répertoire '/var/cache/zoneminder' bien "
|
||||||
|
"qu'il puisse contenir des données critiques."
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Choices
|
||||||
|
#: ../zoneminder-database.templates:1001
|
||||||
|
msgid "local"
|
||||||
|
msgstr "local"
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Choices
|
||||||
|
#: ../zoneminder-database.templates:1001
|
||||||
|
msgid "remote"
|
||||||
|
msgstr "distant"
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid "Database location:"
|
||||||
|
msgstr "Emplacement de la base de donnée :"
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid ""
|
||||||
|
"A database server is required to run ZoneMinder. The database can be "
|
||||||
|
"installed either locally or remotely on a machine of your network."
|
||||||
|
msgstr ""
|
||||||
|
"Un serveur de base de données est requis pour ZoneMinder. La base de donnée "
|
||||||
|
"peut être installée localement ou à distance sur une machine de votre réseau."
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid ""
|
||||||
|
"If you choose a remote location, you will have to select the 'tcp/ip' "
|
||||||
|
"connection method and enter the hostname or ip address of the remote machine "
|
||||||
|
"in the next configuration screens."
|
||||||
|
msgstr ""
|
||||||
|
"Si vous choisissez un emplacement distant, vous devrez sélectionner la "
|
||||||
|
"méthode de connexion 'tcp/ip' et entrer le nom réseau ou l'adresse ip de la "
|
||||||
|
"machine distante dans les écrans de configuration suivants."
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid "No local database server is available:"
|
||||||
|
msgstr "Aucun serveur local de base de données n'est disponible :"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"Currently ZoneMinder supports mysql or mariadb database server but none of "
|
||||||
|
"them appears to be installed on this machine."
|
||||||
|
msgstr ""
|
||||||
|
"Actuellement ZoneMinder supporte les serveurs de base de données mysql et "
|
||||||
|
"mariadb mais aucun d'entre eux n'est installé sur cette machine."
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"In order to complete ZoneMinder's installation, after ending of this "
|
||||||
|
"assistant, please install a compatible database server and then restart the "
|
||||||
|
"assistant by invoking:"
|
||||||
|
msgstr ""
|
||||||
|
"Afin de compléter l'installation de ZoneMinder, après la fermeture de cet "
|
||||||
|
"assitant, veuillez installer un serveur de base de données compatible et "
|
||||||
|
"ensuite redémarrez l'assistant en invoquant :"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001 ../zoneminder-database.templates:3001
|
||||||
|
msgid "$ sudo dpkg-reconfigure zoneminder"
|
||||||
|
msgstr "$ sudo dpkg-reconfigure zoneminder"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid "Remote database servers are not allowed:"
|
||||||
|
msgstr "Les serveurs de base de données distants ne sont pas autorisés :"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"The current configuration of dbconfig-common does not allow installation of "
|
||||||
|
"a database on remote servers."
|
||||||
|
msgstr ""
|
||||||
|
"La configuration actuelle de dbconfig-common ne permet pas l'installation de "
|
||||||
|
"bases de données sur des serveurs distants."
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"In order to reconfigure dbconfig-common, please invoke the following command "
|
||||||
|
"after ending of this assistant:"
|
||||||
|
msgstr ""
|
||||||
|
"Afin de reconfigurer dbconfig-common, veuillez invoquer la commande suivante "
|
||||||
|
"après la fermeture de cet assitant :"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid "$ sudo dpkg-reconfigure dbconfig-common"
|
||||||
|
msgstr "$ sudo dpkg-reconfigure dbconfig-common"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"Then, to complete ZoneMinder's installation, please restart this assistant "
|
||||||
|
"by invoking:"
|
||||||
|
msgstr ""
|
||||||
|
"Ensuite, pour compléter l'installation de ZoneMinder, veuillez redémarrer "
|
||||||
|
"cet assistant en invoquant :"
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "New password for the ZoneMinder 'admin' user:"
|
||||||
|
msgstr "Nouveau mot de passe pour le compte 'admin' de ZoneMinder :"
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "Please enter the password of the default administrative user."
|
||||||
|
msgstr "Veuillez entrer le mot de passe du compte administrateur par défaut."
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid ""
|
||||||
|
"While not mandatory, it is highly recommended that you set a custom password "
|
||||||
|
"for the administrative 'admin' user."
|
||||||
|
msgstr ""
|
||||||
|
"Bien que cela ne soit pas obligatoire, il est fortement recommandé de "
|
||||||
|
"fournir un mot de passe personnalisé pour le compte administrateur 'admin'."
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "If this field is left blank, the password will not be changed."
|
||||||
|
msgstr "Si le champ est laissé vide, le mot de passe ne sera pas changé."
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:5001
|
||||||
|
msgid "Repeat password for the ZoneMinder 'admin' user:"
|
||||||
|
msgstr "Répéter le mot de passe pour le compte 'admin' de ZoneMinder :"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:6001
|
||||||
|
msgid "Password input error"
|
||||||
|
msgstr "Erreur de mot de passe"
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:6001
|
||||||
|
msgid "The two passwords you entered were not the same. Please try again."
|
||||||
|
msgstr ""
|
||||||
|
"Les deux mots de passe saisis ne sont pas les mêmes. Veuillez essayer à "
|
||||||
|
"nouveau."
|
||||||
|
|
||||||
|
#. Type: multiselect
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-ui-base.templates:1001
|
||||||
|
msgid "Web server to reconfigure automatically:"
|
||||||
|
msgstr "Serveur web à reconfigurer automatiquement :"
|
||||||
|
|
||||||
|
#. Type: multiselect
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-ui-base.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"Please choose the web server that should be automatically configured for "
|
||||||
|
"ZoneMinder's web portal access."
|
||||||
|
msgstr ""
|
||||||
|
"Veuillez choisir le serveur web à reconfigurer automatiquement pour l'accès "
|
||||||
|
"au portail web de ZoneMinder."
|
|
@ -0,0 +1,222 @@
|
||||||
|
# SOME DESCRIPTIVE TITLE.
|
||||||
|
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||||
|
# This file is distributed under the same license as the PACKAGE package.
|
||||||
|
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||||
|
#
|
||||||
|
#, fuzzy
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: zoneminder\n"
|
||||||
|
"Report-Msgid-Bugs-To: zoneminder@packages.debian.org\n"
|
||||||
|
"POT-Creation-Date: 2014-12-16 12:34+0100\n"
|
||||||
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
"Language: \n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=CHARSET\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid "Delete this non empty directory?"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"A purge of the ZoneMinder package is performed but the directory '/var/cache/"
|
||||||
|
"zoneminder' is not empty so it will not be deleted."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"Please consider that this directory is designed to contain data resulting "
|
||||||
|
"from event detection. Therefore, \"proof of evidence\" could be lost!\""
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"If you are not sure of your decision, please do not delete this directory "
|
||||||
|
"but perform a manual checkup."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:2001
|
||||||
|
msgid "Deletion confirmed?"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: boolean
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-core.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"You have allowed the deletion of directory '/var/cache/zoneminder' although "
|
||||||
|
"it may contain critical data."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Choices
|
||||||
|
#: ../zoneminder-database.templates:1001
|
||||||
|
msgid "local"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Choices
|
||||||
|
#: ../zoneminder-database.templates:1001
|
||||||
|
msgid "remote"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid "Database location:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid ""
|
||||||
|
"A database server is required to run ZoneMinder. The database can be "
|
||||||
|
"installed either locally or remotely on a machine of your network."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: select
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:1002
|
||||||
|
msgid ""
|
||||||
|
"If you choose a remote location, you will have to select the 'tcp/ip' "
|
||||||
|
"connection method and enter the hostname or ip address of the remote machine "
|
||||||
|
"in the next configuration screens."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid "No local database server is available:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"Currently ZoneMinder supports mysql or mariadb database server but none of "
|
||||||
|
"them appears to be installed on this machine."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001
|
||||||
|
msgid ""
|
||||||
|
"In order to complete ZoneMinder's installation, after ending of this "
|
||||||
|
"assistant, please install a compatible database server and then restart the "
|
||||||
|
"assistant by invoking:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:2001 ../zoneminder-database.templates:3001
|
||||||
|
msgid "$ sudo dpkg-reconfigure zoneminder"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid "Remote database servers are not allowed:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"The current configuration of dbconfig-common does not allow installation of "
|
||||||
|
"a database on remote servers."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"In order to reconfigure dbconfig-common, please invoke the following command "
|
||||||
|
"after ending of this assistant:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid "$ sudo dpkg-reconfigure dbconfig-common"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:3001
|
||||||
|
msgid ""
|
||||||
|
"Then, to complete ZoneMinder's installation, please restart this assistant "
|
||||||
|
"by invoking:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "New password for the ZoneMinder 'admin' user:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "Please enter the password of the default administrative user."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid ""
|
||||||
|
"While not mandatory, it is highly recommended that you set a custom password "
|
||||||
|
"for the administrative 'admin' user."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:4001
|
||||||
|
msgid "If this field is left blank, the password will not be changed."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: password
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:5001
|
||||||
|
msgid "Repeat password for the ZoneMinder 'admin' user:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:6001
|
||||||
|
msgid "Password input error"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: error
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-database.templates:6001
|
||||||
|
msgid "The two passwords you entered were not the same. Please try again."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: multiselect
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-ui-base.templates:1001
|
||||||
|
msgid "Web server to reconfigure automatically:"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Type: multiselect
|
||||||
|
#. Description
|
||||||
|
#: ../zoneminder-ui-base.templates:1001
|
||||||
|
msgid ""
|
||||||
|
"Please choose the web server that should be automatically configured for "
|
||||||
|
"ZoneMinder's web portal access."
|
||||||
|
msgstr ""
|
|
@ -0,0 +1,101 @@
|
||||||
|
#!/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
|
||||||
|
|
||||||
|
%:
|
||||||
|
dh $@ --buildsystem=cmake --parallel --with systemd
|
||||||
|
|
||||||
|
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 \
|
||||||
|
-DCMAKE_INSTALL_SYSCONFDIR=etc/zm \
|
||||||
|
-DZM_PLUGIN_SUPPORT=ON \
|
||||||
|
-DZM_PLUGINSPKGLIBDIR=/usr/lib/zoneminder/plugins
|
||||||
|
|
||||||
|
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_installinit:
|
||||||
|
dh_installinit --package=zoneminder-core --name=zoneminder
|
||||||
|
|
||||||
|
override_dh_systemd_start:
|
||||||
|
dh_systemd_start --package=zoneminder-core --name=zoneminder \
|
||||||
|
--restart-after-upgrade
|
||||||
|
|
||||||
|
override_dh_systemd_enable:
|
||||||
|
dh_systemd_enable --package=zoneminder-core --name=zoneminder
|
||||||
|
|
||||||
|
override_dh_fixperms:
|
||||||
|
dh_fixperms
|
||||||
|
#
|
||||||
|
# As requested by the Debian Webapps Policy Manual §3.2.1
|
||||||
|
chown root:www-data debian/zoneminder-core/etc/zm/zm.conf
|
||||||
|
chmod 640 debian/zoneminder-core/etc/zm/zm.conf
|
||||||
|
|
||||||
|
override_dh_auto_test:
|
||||||
|
# do not run tests...
|
||||||
|
|
||||||
|
.PHONY: override_dh_strip
|
||||||
|
override_dh_strip:
|
||||||
|
dh_strip --dbg-package=zoneminder-core-dbg
|
||||||
|
|
||||||
|
# Inspired by https://wiki.debian.org/onlyjob/get-orig-source
|
||||||
|
.PHONY: get-orig-source
|
||||||
|
get-orig-source: $(TARBALL) $(info I: $(PKG)_$(VER)$(DTYPE))
|
||||||
|
@
|
||||||
|
|
||||||
|
$(TARBALL):
|
||||||
|
$(if $(wildcard $(PKG)-$(VER)),$(error folder '$(PKG)-$(VER)' exists, aborting...))
|
||||||
|
@echo "# Cloning origin repository..."; \
|
||||||
|
if ! git clone $(UURL) $(PKG)-$(VER); then \
|
||||||
|
$(RM) -r $(PKG)-$(VER); \
|
||||||
|
echo "failed to clone repository, aborting..."; \
|
||||||
|
false; \
|
||||||
|
fi
|
||||||
|
@if [ $(BRANCH) != "master" ]; then \
|
||||||
|
cd $(PKG)-$(VER); \
|
||||||
|
echo "# Not on master branch, fetching origin branch '$(BRANCH)'..."; \
|
||||||
|
git fetch origin $(BRANCH):$(BRANCH) || false; \
|
||||||
|
echo "# Switching to branch '$(BRANCH)'..."; \
|
||||||
|
git checkout $(BRANCH) || false; \
|
||||||
|
fi
|
||||||
|
@echo "# Checking local source..."
|
||||||
|
@if [ $$(cd $(PKG)-$(VER) && git rev-parse HEAD) = $(HEAD) ]; then \
|
||||||
|
echo "even with origin, ok"; \
|
||||||
|
true; \
|
||||||
|
else \
|
||||||
|
echo "not even with origin, aborting..."; \
|
||||||
|
false; \
|
||||||
|
fi
|
||||||
|
@echo "# Setting times..."
|
||||||
|
@cd $(PKG)-$(VER) \
|
||||||
|
&& for F in $$(git ls-tree -r --name-only HEAD | sed -e "s/\s/\*/g"); do \
|
||||||
|
touch --no-dereference -d "$$(git log -1 --format="%ai" -- $$F)" "$$F"; \
|
||||||
|
done
|
||||||
|
@echo "# Cleaning-up..."
|
||||||
|
cd $(PKG)-$(VER) && $(RM) -r .git
|
||||||
|
@echo "# Packing file '$(TARBALL)'..."
|
||||||
|
@find -L "$(PKG)-$(VER)" -xdev -type f -print | sort \
|
||||||
|
| XZ_OPT="-6v" tar -caf "$(TARBALL)" -T- --owner=root --group=root --mode=a+rX \
|
||||||
|
&& $(RM) -r "$(PKG)-$(VER)"
|
|
@ -0,0 +1 @@
|
||||||
|
3.0 (native)
|
|
@ -0,0 +1 @@
|
||||||
|
extend-diff-ignore = "(^|/)(config\.sub|config\.guess|Makefile|aclocal.m4|compile|config.h.in|configure|depcomp|install-sh|missing)$"
|
|
@ -0,0 +1,11 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# config maintainer script for zoneminder-core package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,4 @@
|
||||||
|
var/log/zm
|
||||||
|
var/cache/zoneminder/events
|
||||||
|
var/cache/zoneminder/images
|
||||||
|
var/cache/zoneminder/temp
|
|
@ -0,0 +1,5 @@
|
||||||
|
etc/zm/zm.conf
|
||||||
|
etc/zm/plugins.conf
|
||||||
|
usr/bin
|
||||||
|
usr/share/polkit-1/actions
|
||||||
|
usr/share/polkit-1/rules.d
|
|
@ -0,0 +1,3 @@
|
||||||
|
var/cache/zoneminder/events usr/share/zoneminder/events
|
||||||
|
var/cache/zoneminder/images usr/share/zoneminder/images
|
||||||
|
var/cache/zoneminder/temp usr/share/zoneminder/temp
|
|
@ -0,0 +1,80 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postinst maintainer script for zoneminder-core package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
# Source the config file
|
||||||
|
CONFIGFILE=/etc/zm/zm.conf
|
||||||
|
. $CONFIGFILE
|
||||||
|
|
||||||
|
# Do this when the package is installed, upgraded or reconfigured
|
||||||
|
if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
|
||||||
|
|
||||||
|
# Retrieve data from dbconfig (inputs from user)
|
||||||
|
. /etc/dbconfig-common/zoneminder.conf
|
||||||
|
|
||||||
|
# ZoneMinder config file handling
|
||||||
|
# Inspired by: http://manpages.debian.org/cgi-bin/man.cgi?query=debconf-devel&sektion=7
|
||||||
|
|
||||||
|
# Backup the config file
|
||||||
|
cp -a -f $CONFIGFILE ${CONFIGFILE}.postinst.bak
|
||||||
|
|
||||||
|
# Redeclare variables if missing in config file
|
||||||
|
test -z $dbc_dbserver || grep -Eq "^ *ZM_DB_HOST=" $CONFIGFILE \
|
||||||
|
|| echo "ZM_DB_HOST=" >> ${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbname || grep -Eq "^ *ZM_DB_NAME=" $CONFIGFILE \
|
||||||
|
|| echo "ZM_DB_NAME=" >> ${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbuser || grep -Eq "^ *ZM_DB_USER=" $CONFIGFILE \
|
||||||
|
|| echo "ZM_DB_USER=" >> ${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbpass || grep -Eq "^ *ZM_DB_PASS=" $CONFIGFILE \
|
||||||
|
|| echo "ZM_DB_PASS=" >> ${CONFIGFILE}.postinst.bak
|
||||||
|
|
||||||
|
# Prevent ZM_DB_HOST to be empty if user selected the 'unix socket' method
|
||||||
|
if test -z $dbc_dbserver; then
|
||||||
|
dbc_dbserver_override="localhost"
|
||||||
|
else
|
||||||
|
dbc_dbserver_override=$dbc_dbserver
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Update variables in config file
|
||||||
|
sed -i "s/^ *ZM_DB_HOST=.*/ZM_DB_HOST=$dbc_dbserver_override/" \
|
||||||
|
${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbname || sed -i "s/^ *ZM_DB_NAME=.*/ZM_DB_NAME=$dbc_dbname/" \
|
||||||
|
${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbuser || sed -i "s/^ *ZM_DB_USER=.*/ZM_DB_USER=$dbc_dbuser/" \
|
||||||
|
${CONFIGFILE}.postinst.bak
|
||||||
|
test -z $dbc_dbpass || sed -i "s/^ *ZM_DB_PASS=.*/ZM_DB_PASS=$dbc_dbpass/" \
|
||||||
|
${CONFIGFILE}.postinst.bak
|
||||||
|
|
||||||
|
# Clean-up backup file
|
||||||
|
mv -f ${CONFIGFILE}.postinst.bak $CONFIGFILE
|
||||||
|
|
||||||
|
|
||||||
|
# Set some file permissions
|
||||||
|
chown $ZM_WEB_USER:$ZM_WEB_GROUP /var/log/zm
|
||||||
|
if [ -z "$2" ]; then
|
||||||
|
chown $ZM_WEB_USER:$ZM_WEB_GROUP -R /var/cache/zoneminder
|
||||||
|
fi
|
||||||
|
# As requested by the Debian Webapps Policy Manual §3.2.1
|
||||||
|
chown root:${ZM_WEB_GROUP} $CONFIGFILE
|
||||||
|
chmod 640 $CONFIGFILE
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Do this every time the package is installed or upgraded
|
||||||
|
# Test for database presence to avoid failure of zmupdate.pl
|
||||||
|
if [ "$dbc_install" = "true" ] && [ "$1" = "configure" ]; then
|
||||||
|
|
||||||
|
# Ensure zoneminder is stopped
|
||||||
|
deb-systemd-invoke stop zoneminder.service || exit $?
|
||||||
|
|
||||||
|
# Run the ZoneMinder update tool
|
||||||
|
zmupdate.pl --nointeractive
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,37 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postrm maintainer script for zoneminder-core package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
if [ -f /usr/share/debconf/confmodule ]; then
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "purge" ]; then
|
||||||
|
|
||||||
|
# Ask the user if we have to remove the cache directory even if not empty
|
||||||
|
if [ -d /var/cache/zoneminder ] \
|
||||||
|
&& [ ! $(find /var/cache/zoneminder -maxdepth 0 -type d -empty 2>/dev/null) ]; then
|
||||||
|
RET=""
|
||||||
|
db_input high zoneminder/ask_delete || true
|
||||||
|
db_go || true
|
||||||
|
db_get zoneminder/ask_delete
|
||||||
|
if [ "$RET" = "true" ]; then
|
||||||
|
RET=""
|
||||||
|
db_input high zoneminder/ask_delete_again || true
|
||||||
|
db_go || true
|
||||||
|
db_get zoneminder/ask_delete_again
|
||||||
|
if [ "$RET" = "true" ]; then
|
||||||
|
rm -rf /var/cache/zoneminder
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
# postrm rm may freeze without that
|
||||||
|
db_stop
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,33 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# preinst maintainer script for zoneminder-core package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
abort=false
|
||||||
|
if [ -L /usr/share/zoneminder/events ]; then
|
||||||
|
l=$(readlink /usr/share/zoneminder/events)
|
||||||
|
if [ "$l" != "/var/cache/zoneminder/events" ]; then
|
||||||
|
abort=true
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ -L /usr/share/zoneminder/images ]; then
|
||||||
|
l=$(readlink /usr/share/zoneminder/images )
|
||||||
|
if [ "$l" != "/var/cache/zoneminder/images" ]; then
|
||||||
|
abort=true
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$abort" = "true" ]; then
|
||||||
|
cat >&2 << EOF
|
||||||
|
Aborting installation of zoneminder due to non-default symlinks in
|
||||||
|
/usr/share/zoneminder for the images and/or events directory, which could
|
||||||
|
result in loss of data. Please move your data in each of these directories to
|
||||||
|
/var/cache/zoneminder before installing zoneminder from the package.
|
||||||
|
EOF
|
||||||
|
exit 1
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,19 @@
|
||||||
|
Template: zoneminder/ask_delete
|
||||||
|
Type: boolean
|
||||||
|
Default: false
|
||||||
|
_Description: Delete this non empty directory?
|
||||||
|
A purge of the ZoneMinder package is performed but the directory
|
||||||
|
'/var/cache/zoneminder' is not empty so it will not be deleted.
|
||||||
|
.
|
||||||
|
Please consider that this directory is designed to contain data resulting from
|
||||||
|
event detection. Therefore, "proof of evidence" could be lost!"
|
||||||
|
.
|
||||||
|
If you are not sure of your decision, please do not delete this directory but
|
||||||
|
perform a manual checkup.
|
||||||
|
|
||||||
|
Template: zoneminder/ask_delete_again
|
||||||
|
Type: boolean
|
||||||
|
Default: false
|
||||||
|
_Description: Deletion confirmed?
|
||||||
|
You have allowed the deletion of directory '/var/cache/zoneminder' although
|
||||||
|
it may contain critical data.
|
|
@ -0,0 +1,36 @@
|
||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
### BEGIN INIT INFO
|
||||||
|
# Provides: zoneminder
|
||||||
|
# Required-Start:
|
||||||
|
# Required-Stop:
|
||||||
|
# Default-Start: 2 3 4 5
|
||||||
|
# Default-Stop: 0 1 6
|
||||||
|
# Short-Description: Do nothing more than fixing a lintian error
|
||||||
|
# Description: This script is provided by the Zoneminder package
|
||||||
|
# Zomeminder init configuration has been switched to systemd
|
||||||
|
# This dummy script can be safely deleted; It does nothing
|
||||||
|
# more than fixing a lintian error when testing the package
|
||||||
|
### END INIT INFO
|
||||||
|
|
||||||
|
. /lib/lsb/init-functions
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
start)
|
||||||
|
;;
|
||||||
|
stop)
|
||||||
|
;;
|
||||||
|
status)
|
||||||
|
;;
|
||||||
|
restart|reload)
|
||||||
|
;;
|
||||||
|
force-reload)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Usage: ${0:-} {start|stop|status|restart|reload|force-reload}" >&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
# ZoneMinder systemd unit file
|
||||||
|
# This file is intended to work with debian distributions
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=ZoneMinder CCTV recording and security system
|
||||||
|
After=network.target mysql.service apache2.service
|
||||||
|
Requires=apache2.service
|
||||||
|
Wants=mysql.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
User=www-data
|
||||||
|
Type=forking
|
||||||
|
ExecStart=/usr/bin/zmpkg.pl start
|
||||||
|
ExecReload=/usr/bin/zmpkg.pl restart
|
||||||
|
ExecStop=/usr/bin/zmpkg.pl stop
|
||||||
|
PIDFile=/var/run/zm/zm.pid
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
|
@ -0,0 +1 @@
|
||||||
|
d /var/run/zm 0755 www-data www-data
|
|
@ -0,0 +1,142 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# config maintainer script for zoneminder
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
# Set the first version in which dbconfig-common was introduced in the package
|
||||||
|
dbc_first_version="1.28.0"
|
||||||
|
|
||||||
|
CONFIGFILE=/etc/zm/zm.conf
|
||||||
|
if [ -e $CONFIGFILE ]; then
|
||||||
|
# Source the config file if exists
|
||||||
|
. $CONFIGFILE
|
||||||
|
elif [ -e ${CONFIGFILE}.dpkg-new ]; then
|
||||||
|
# If no config file, source the config file which is going to be installed
|
||||||
|
# by the core package
|
||||||
|
. ${CONFIGFILE}.dpkg-new
|
||||||
|
else
|
||||||
|
# If no config file is going to be installed, set some default values
|
||||||
|
ZM_DB_HOST=
|
||||||
|
ZM_DB_NAME="zm"
|
||||||
|
ZM_DB_USER="zmuser"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set some variables for the dbconfig-common stuff
|
||||||
|
dbc_dbserver="$ZM_DB_HOST"
|
||||||
|
dbc_dbname="$ZM_DB_NAME"
|
||||||
|
dbc_dbuser="$ZM_DB_USER"
|
||||||
|
|
||||||
|
if [ -f /usr/share/dbconfig-common/dpkg/config ]; then
|
||||||
|
|
||||||
|
# Default use dbconfig-common
|
||||||
|
dbc_install="true"
|
||||||
|
|
||||||
|
# Currently we only support mysql database
|
||||||
|
dbc_dbtypes="mysql"
|
||||||
|
|
||||||
|
# Set authentication method to password
|
||||||
|
dbc_authmethod_user="password"
|
||||||
|
|
||||||
|
# Source the dbconfig-common stuff
|
||||||
|
. /usr/share/dbconfig-common/dpkg/config
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Do this when the package is installed, upgraded or reconfigured
|
||||||
|
# Most of answers are cached so the questions will not be asked again
|
||||||
|
if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
|
||||||
|
|
||||||
|
# Ask the user if the database shall be installed locally or remotely
|
||||||
|
db_input high zoneminder/debconf_dblocation || true
|
||||||
|
db_go || true
|
||||||
|
db_get zoneminder/debconf_dblocation
|
||||||
|
|
||||||
|
if [ "$RET" = "local" ]; then
|
||||||
|
if [ ! -e "/usr/sbin/mysqld" ]; then
|
||||||
|
# Display a message and exit if the user want a local database but
|
||||||
|
# no database server is available
|
||||||
|
db_input high zoneminder/debconf_dblocalmissingerror || true
|
||||||
|
db_go || true
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
# Set the database server to localhost
|
||||||
|
dbc_dbserver="localhost"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
# Source the dbconfig main configuration file
|
||||||
|
if [ -f /etc/dbconfig-common/config ]; then
|
||||||
|
. /etc/dbconfig-common/config
|
||||||
|
fi
|
||||||
|
if [ "$dbc_remote_questions_default" = "false" ]; then
|
||||||
|
# Display a message and exit if the dbconfig configuration does not
|
||||||
|
# allow installation of remote databases
|
||||||
|
# Note: To overcome this issue, we could think to override the
|
||||||
|
# default setting by using dbc_remote_questions_default='true' in
|
||||||
|
# maintainer scripts but unfortunately this does not work due to
|
||||||
|
# current dbconfig design
|
||||||
|
# More information here:
|
||||||
|
# https://bugs.launchpad.net/ubuntu/+source/dbconfig-common/+bug/1065331
|
||||||
|
db_input high zoneminder/debconf_dbconfigerror || true
|
||||||
|
db_go || true
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Ask the user for all database settings
|
||||||
|
dbc_go zoneminder $@
|
||||||
|
|
||||||
|
# Ask the user for the password of the database administrator if the user
|
||||||
|
# has not yet answered to this question.
|
||||||
|
# This situation may occur if the user skipped the database creation step
|
||||||
|
# when reconfiguring the package.
|
||||||
|
RET=""
|
||||||
|
db_get zoneminder/mysql/admin-pass
|
||||||
|
if [ -z "$RET" ]; then
|
||||||
|
db_input high zoneminder/mysql/admin-pass || true
|
||||||
|
db_go || true
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Do this only when not upgrading the package (no old version in argument)
|
||||||
|
if [ -z "$2" ]; then
|
||||||
|
# Ask for the password of 'admin' user
|
||||||
|
while :; do
|
||||||
|
RET=""
|
||||||
|
db_input high zoneminder/admin_password || true
|
||||||
|
db_go || true
|
||||||
|
db_get zoneminder/admin_password
|
||||||
|
# If password isn't empty we ask for password verification
|
||||||
|
if [ -z "$RET" ]; then
|
||||||
|
db_fset zoneminder/admin_password seen false
|
||||||
|
db_fset zoneminder/admin_password_again seen false
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
ROOT_PW="$RET"
|
||||||
|
db_input high zoneminder/admin_password_again || true
|
||||||
|
db_go || true
|
||||||
|
db_get zoneminder/admin_password_again
|
||||||
|
if [ "$RET" = "$ROOT_PW" ]; then
|
||||||
|
ROOT_PW=""
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
db_fset zoneminder/password_mismatch seen false
|
||||||
|
db_input critical zoneminder/password_mismatch || true
|
||||||
|
db_set zoneminder/admin_password ""
|
||||||
|
db_set zoneminder/admin_password_again ""
|
||||||
|
db_go || true
|
||||||
|
done
|
||||||
|
else
|
||||||
|
# If we are upgrading the package, set an empty password to disable
|
||||||
|
# password update in ZoneMinder database
|
||||||
|
db_set zoneminder/admin_password ""
|
||||||
|
fi
|
||||||
|
# Set the seen flag to not ask this question again if no password is
|
||||||
|
# provided
|
||||||
|
db_fset zoneminder/admin_password seen true
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,5 @@
|
||||||
|
usr/share/zoneminder/db
|
||||||
|
usr/share/dbconfig-common/data/zoneminder/install
|
||||||
|
usr/share/dbconfig-common/data/zoneminder/upgrade/mysql
|
||||||
|
etc/zm/plugins.d
|
||||||
|
usr/share/zoneminder/plugins
|
|
@ -0,0 +1 @@
|
||||||
|
usr/share/zoneminder/db
|
|
@ -0,0 +1,79 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postinst maintainer script for zoneminder-db package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
mysql_update() {
|
||||||
|
|
||||||
|
# Source the dbconfig stuff
|
||||||
|
. /usr/share/dbconfig-common/internal/mysql
|
||||||
|
|
||||||
|
# Update the password of the hard-coded default 'admin' account
|
||||||
|
test -z $ADMIN_PASSWORD || dbc_mysql_exec_command "UPDATE Users SET Password = password('$ADMIN_PASSWORD') WHERE Username = 'admin';" || true
|
||||||
|
|
||||||
|
# Update the database version
|
||||||
|
dbc_mysql_exec_command "UPDATE Config SET Value = '$DB_VERSION' WHERE Name = 'ZM_DYN_DB_VERSION';" || true
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ -f /usr/share/dbconfig-common/dpkg/postinst ]; then
|
||||||
|
|
||||||
|
# Set the first version in which dbconfig-common was introduced in the package
|
||||||
|
dbc_first_version="1.28.0"
|
||||||
|
|
||||||
|
# Set the database type
|
||||||
|
dbc_dbtypes="mysql"
|
||||||
|
|
||||||
|
# Source the dbconfig-common stuff
|
||||||
|
. /usr/share/dbconfig-common/dpkg/postinst
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Do this when the package is installed, upgraded or reconfigured
|
||||||
|
if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
|
||||||
|
|
||||||
|
# Install sql database create file for dbconfig
|
||||||
|
# (needed at first package installation)
|
||||||
|
if [ ! -f /usr/share/dbconfig-common/data/zoneminder/install/mysql ]; then
|
||||||
|
install -m 644 /usr/share/zoneminder/db/zm_create.sql \
|
||||||
|
/usr/share/dbconfig-common/data/zoneminder/install/mysql
|
||||||
|
# Remove unneeded sql requests
|
||||||
|
# dbconfig will create the underlying database
|
||||||
|
sed -i "/^ *CREATE DATABASE /d" \
|
||||||
|
/usr/share/dbconfig-common/data/zoneminder/install/mysql
|
||||||
|
sed -i "/^ *USE /d" \
|
||||||
|
/usr/share/dbconfig-common/data/zoneminder/install/mysql
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Symlink sql update files for dbconfig (needed when upgrading the package)
|
||||||
|
for sqlfile in /usr/share/zoneminder/db/zm_update-*.sql; do
|
||||||
|
lnk=`echo $sqlfile | sed "s/^\/usr\/share\/zoneminder\/db\/zm_update-\(.*\)\.sql/\1/"`
|
||||||
|
if [ ! -L /usr/share/dbconfig-common/data/zoneminder/upgrade/mysql/$lnk ]; then
|
||||||
|
ln -sf $sqlfile \
|
||||||
|
/usr/share/dbconfig-common/data/zoneminder/upgrade/mysql/$lnk
|
||||||
|
fi
|
||||||
|
done || true
|
||||||
|
|
||||||
|
# Create the underlying database and populate it
|
||||||
|
# dbconfig will take care of applying any updates which are newer than the
|
||||||
|
# previously installed version
|
||||||
|
dbc_go zoneminder $@
|
||||||
|
|
||||||
|
# Get the password of ZoneMinder user 'admin' from debconf
|
||||||
|
db_get zoneminder/admin_password
|
||||||
|
ADMIN_PASSWORD=$RET
|
||||||
|
|
||||||
|
# Remove the password from debconf database
|
||||||
|
test -z $ADMIN_PASSWORD || db_reset zoneminder/admin_password || true
|
||||||
|
|
||||||
|
# Get the lastest database version from dbconfig upgrade folder
|
||||||
|
DB_VERSION=$(ls -rv /usr/share/dbconfig-common/data/zoneminder/upgrade/$dbc_dbtypes | head -1)
|
||||||
|
|
||||||
|
# Update the default admin account and database version
|
||||||
|
mysql_update
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,34 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postrm maintainer script for zoneminder-db package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
if [ -f /usr/share/debconf/confmodule ]; then
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Source the dbconfig stuff
|
||||||
|
if [ -f /usr/share/dbconfig-common/dpkg/postrm ]; then
|
||||||
|
. /usr/share/dbconfig-common/dpkg/postrm
|
||||||
|
# Ask the user what do to with dbconfig when removing the package
|
||||||
|
dbc_go zoneminder $@
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "remove" ] || [ "$1" = "purge" ]; then
|
||||||
|
# Remove dbconfig stuff added in postinst script
|
||||||
|
rm -rf /usr/share/dbconfig-common/data/zoneminder
|
||||||
|
# No need to manually remove the zm database, dbconfig take care of this
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "purge" ]; then
|
||||||
|
# Delete a potential remaining file used in postinst script
|
||||||
|
rm -f /etc/zm/zm.conf.postinst.bak
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
# postrm rm may freeze without that
|
||||||
|
db_stop
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,22 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# prerm script for zoneminder-db package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff if file exists
|
||||||
|
if [ -f /usr/share/debconf/confmodule ]; then
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
fi
|
||||||
|
|
||||||
|
# If dbconfig-common is installed and has been used by zoneminder
|
||||||
|
if [ -f /usr/share/dbconfig-common/dpkg/prerm ] \
|
||||||
|
&& [ -f /etc/dbconfig-common/zoneminder.conf ]; then
|
||||||
|
# Source the dbconfig stuff
|
||||||
|
. /usr/share/dbconfig-common/dpkg/prerm
|
||||||
|
# Ask the user what do to with dbconfig before removing the package
|
||||||
|
dbc_go zoneminder $@
|
||||||
|
fi
|
||||||
|
|
||||||
|
# #DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,58 @@
|
||||||
|
Template: zoneminder/debconf_dblocation
|
||||||
|
Type: select
|
||||||
|
__Choices: local, remote
|
||||||
|
Default: local
|
||||||
|
_Description: Database location:
|
||||||
|
A database server is required to run ZoneMinder. The database can be installed
|
||||||
|
either locally or remotely on a machine of your network.
|
||||||
|
.
|
||||||
|
If you choose a remote location, you will have to select the 'tcp/ip'
|
||||||
|
connection method and enter the hostname or ip address of the remote machine
|
||||||
|
in the next configuration screens.
|
||||||
|
|
||||||
|
Template: zoneminder/debconf_dblocalmissingerror
|
||||||
|
Type: error
|
||||||
|
_Description: No local database server is available:
|
||||||
|
Currently ZoneMinder supports mysql or mariadb database server but none of them
|
||||||
|
appears to be installed on this machine.
|
||||||
|
.
|
||||||
|
In order to complete ZoneMinder's installation, after ending of this assistant,
|
||||||
|
please install a compatible database server and then restart the assistant by
|
||||||
|
invoking:
|
||||||
|
.
|
||||||
|
$ sudo dpkg-reconfigure zoneminder
|
||||||
|
|
||||||
|
Template: zoneminder/debconf_dbconfigerror
|
||||||
|
Type: error
|
||||||
|
_Description: Remote database servers are not allowed:
|
||||||
|
The current configuration of dbconfig-common does not allow installation of
|
||||||
|
a database on remote servers.
|
||||||
|
.
|
||||||
|
In order to reconfigure dbconfig-common, please invoke the following command
|
||||||
|
after ending of this assistant:
|
||||||
|
.
|
||||||
|
$ sudo dpkg-reconfigure dbconfig-common
|
||||||
|
.
|
||||||
|
Then, to complete ZoneMinder's installation, please restart this assistant by
|
||||||
|
invoking:
|
||||||
|
.
|
||||||
|
$ sudo dpkg-reconfigure zoneminder
|
||||||
|
|
||||||
|
Template: zoneminder/admin_password
|
||||||
|
Type: password
|
||||||
|
_Description: New password for the ZoneMinder 'admin' user:
|
||||||
|
Please enter the password of the default administrative user.
|
||||||
|
.
|
||||||
|
While not mandatory, it is highly recommended that you set a custom password
|
||||||
|
for the administrative 'admin' user.
|
||||||
|
.
|
||||||
|
If this field is left blank, the password will not be changed.
|
||||||
|
|
||||||
|
Template: zoneminder/admin_password_again
|
||||||
|
Type: password
|
||||||
|
_Description: Repeat password for the ZoneMinder 'admin' user:
|
||||||
|
|
||||||
|
Template: zoneminder/password_mismatch
|
||||||
|
Type: error
|
||||||
|
_Description: Password input error
|
||||||
|
The two passwords you entered were not the same. Please try again.
|
|
@ -0,0 +1,20 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# config maintainer script for zoneminder-ui-base package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
# Do this when the package is installed, upgraded or reconfigured
|
||||||
|
# Most of answers are cached so the questions will not be asked again
|
||||||
|
if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
|
||||||
|
|
||||||
|
# Ask the user for the web server(s) to configure
|
||||||
|
db_input high zoneminder/webserver || true
|
||||||
|
db_go || true
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,11 @@
|
||||||
|
debian/apache.conf etc/zm
|
||||||
|
usr/lib/cgi-bin
|
||||||
|
usr/share/zoneminder/ajax
|
||||||
|
usr/share/zoneminder/css
|
||||||
|
usr/share/zoneminder/graphics
|
||||||
|
usr/share/zoneminder/includes
|
||||||
|
usr/share/zoneminder/index.php
|
||||||
|
usr/share/zoneminder/js
|
||||||
|
usr/share/zoneminder/lang
|
||||||
|
usr/share/zoneminder/tools
|
||||||
|
usr/share/zoneminder/views
|
|
@ -0,0 +1 @@
|
||||||
|
usr/lib/cgi-bin usr/share/zoneminder/cgi-bin
|
|
@ -0,0 +1,48 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postinst maintainer script for zoneminder-ui-base package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
|
||||||
|
apache_install() {
|
||||||
|
|
||||||
|
mkdir -p /etc/apache2/conf-available
|
||||||
|
ln -sf ../../zm/apache.conf /etc/apache2/conf-available/zoneminder.conf
|
||||||
|
|
||||||
|
COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)
|
||||||
|
|
||||||
|
if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
|
||||||
|
. /usr/share/apache2/apache2-maintscript-helper
|
||||||
|
apache2_invoke enconf zoneminder
|
||||||
|
elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
|
||||||
|
[ -d /etc/apache2/conf.d/ ] && [ ! -L /etc/apache2/conf.d/zoneminder.conf ] && ln -s ../conf-available/zoneminder.conf /etc/apache2/conf.d/zoneminder.conf
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Enable CGI script module in apache (not enabled by default on jessie)
|
||||||
|
a2enmod cgi >/dev/null 2>&1
|
||||||
|
|
||||||
|
# Reload the web server
|
||||||
|
deb-systemd-invoke reload apache2.service || true
|
||||||
|
}
|
||||||
|
|
||||||
|
# Do this when the package is installed, upgraded or reconfigured
|
||||||
|
if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
|
||||||
|
|
||||||
|
# Configure the web server
|
||||||
|
db_get zoneminder/webserver
|
||||||
|
webservers="$RET"
|
||||||
|
|
||||||
|
for webserver in $webservers; do
|
||||||
|
webserver=${webserver%,}
|
||||||
|
# Currently we only support apache2
|
||||||
|
if [ "$webserver" = "apache2" ] ; then
|
||||||
|
apache_install $1
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,41 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# postrm maintainer script for zoneminder-ui-base package
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Source the debconf stuff
|
||||||
|
if [ -f /usr/share/debconf/confmodule ]; then
|
||||||
|
. /usr/share/debconf/confmodule
|
||||||
|
fi
|
||||||
|
|
||||||
|
apache_remove() {
|
||||||
|
COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)
|
||||||
|
if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
|
||||||
|
. /usr/share/apache2/apache2-maintscript-helper
|
||||||
|
apache2_invoke disconf zoneminder
|
||||||
|
elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
|
||||||
|
rm -f /etc/apache2/conf.d/zoneminder.conf
|
||||||
|
fi
|
||||||
|
rm -f /etc/apache2/conf-available/zoneminder.conf
|
||||||
|
# Reload the web server
|
||||||
|
deb-systemd-invoke reload apache2.service || true
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ "$1" = "remove" ] || [ "$1" = "purge" ]; then
|
||||||
|
# Deconfigure the web server
|
||||||
|
db_get zoneminder/webserver
|
||||||
|
for webserver in $RET; do
|
||||||
|
webserver=${webserver%,}
|
||||||
|
# Currently we only support apache2
|
||||||
|
if [ "$webserver" = "apache2" ] ; then
|
||||||
|
apache_remove $1
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
#DEBHELPER#
|
||||||
|
|
||||||
|
# postrm rm may freeze without that
|
||||||
|
db_stop
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,7 @@
|
||||||
|
Template: zoneminder/webserver
|
||||||
|
Type: multiselect
|
||||||
|
Choices: apache2
|
||||||
|
Default: apache2
|
||||||
|
_Description: Web server to reconfigure automatically:
|
||||||
|
Please choose the web server that should be automatically configured for
|
||||||
|
ZoneMinder's web portal access.
|
|
@ -0,0 +1 @@
|
||||||
|
usr/share/zoneminder/skins/classic
|
|
@ -0,0 +1 @@
|
||||||
|
usr/share/zoneminder/skins/mobile
|
|
@ -0,0 +1 @@
|
||||||
|
usr/share/zoneminder/skins/xml
|
|
@ -2,12 +2,12 @@ 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 (>= 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
|
Build-Depends: debhelper (>= 9), cmake, libphp-serialization-perl, libgnutls-dev | libgnutls28-dev, libmysqlclient-dev | libmariadbclient-dev, libdbd-mysql-perl, libdate-manip-perl, libwww-perl, libjpeg8-dev | libjpeg9-dev | libjpeg62-turbo-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 | libgcrypt20-dev, libpolkit-gobject-1-dev
|
||||||
Standards-Version: 3.9.4
|
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-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
|
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 | libjpeg9 | libjpeg62-turbo, 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
|
Recommends: mysql-server | mariadb-server
|
||||||
Description: Video camera security and surveillance solution
|
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
|
||||||
|
@ -38,3 +38,11 @@ Description: debugging syumbols for zoneminder.
|
||||||
video security system and for commercial or professional video security
|
video security system and for commercial or professional video security
|
||||||
and surveillance. It can also be integrated into a home automation system
|
and surveillance. It can also be integrated into a home automation system
|
||||||
via X.10 or other protocols.
|
via X.10 or other protocols.
|
||||||
|
|
||||||
|
Package: libzoneminder-dev
|
||||||
|
Section: libdevel
|
||||||
|
Architecture: any
|
||||||
|
Depends: ${misc:Depends}
|
||||||
|
Description: Development files for ZoneMinder plugins
|
||||||
|
This package add the necessary files to develop video analysis plugins for
|
||||||
|
the ZoneMinder camera security and surveillance solution.
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
usr/include/zoneminder/*
|
||||||
|
usr/lib/*/libzoneminder.a
|
||||||
|
usr/lib/*/pkgconfig/libzoneminder.pc
|
|
@ -22,7 +22,9 @@ override_dh_auto_configure:
|
||||||
-DZM_CGIDIR=/usr/lib/cgi-bin \
|
-DZM_CGIDIR=/usr/lib/cgi-bin \
|
||||||
-DZM_WEB_USER=www-data \
|
-DZM_WEB_USER=www-data \
|
||||||
-DZM_WEB_GROUP=www-data \
|
-DZM_WEB_GROUP=www-data \
|
||||||
-DCMAKE_INSTALL_SYSCONFDIR=etc/zm
|
-DCMAKE_INSTALL_SYSCONFDIR=etc/zm \
|
||||||
|
-DZM_PLUGIN_SUPPORT=ON \
|
||||||
|
-DZM_PLUGINSPKGLIBDIR=/usr/lib/zoneminder/plugins
|
||||||
|
|
||||||
override_dh_auto_install:
|
override_dh_auto_install:
|
||||||
dh_auto_install --buildsystem=cmake
|
dh_auto_install --buildsystem=cmake
|
||||||
|
|
|
@ -16,3 +16,12 @@ configure_file(zoneminder-tmpfiles.conf.in "${CMAKE_CURRENT_BINARY_DIR}/zonemind
|
||||||
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/com.zoneminder.systemctl.policy" DESTINATION "${PC_POLKIT_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/polkit-1/actions")
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/com.zoneminder.systemctl.policy" DESTINATION "${PC_POLKIT_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/polkit-1/actions")
|
||||||
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/com.zoneminder.systemctl.rules" DESTINATION "${PC_POLKIT_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/polkit-1/rules.d")
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/com.zoneminder.systemctl.rules" DESTINATION "${PC_POLKIT_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/polkit-1/rules.d")
|
||||||
|
|
||||||
|
if(ZM_PLUGIN_SUPPORT)
|
||||||
|
configure_file(plugins.conf.in "${CMAKE_CURRENT_BINARY_DIR}/plugins.conf" @ONLY)
|
||||||
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/plugins.conf" DESTINATION "${ZM_CONFIG_DIR}")
|
||||||
|
include(FindPkgConfig QUIET)
|
||||||
|
if(PKG_CONFIG_FOUND)
|
||||||
|
configure_file(libzoneminder.pc.in "${CMAKE_CURRENT_BINARY_DIR}/libzoneminder.pc" @ONLY)
|
||||||
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/libzoneminder.pc" DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
|
||||||
|
endif()
|
||||||
|
endif(ZM_PLUGIN_SUPPORT)
|
||||||
|
|
|
@ -9,12 +9,12 @@ EXTRA_DIST = \
|
||||||
com.zoneminder.systemctl.policy.in \
|
com.zoneminder.systemctl.policy.in \
|
||||||
com.zoneminder.systemctl.rules.in
|
com.zoneminder.systemctl.rules.in
|
||||||
|
|
||||||
if ZM_HAS_PLUGIN_SUPPORT
|
if ZM_PLUGIN_SUPPORT
|
||||||
EXTRA_DIST += plugins.conf.in
|
EXTRA_DIST += plugins.conf.in
|
||||||
|
|
||||||
# Install a pkg-config file for a proper handling of the libzm
|
# Install a pkg-config file for a proper handling of the libzoneminder
|
||||||
# convenience library
|
# convenience library
|
||||||
pkgconfigdir = $(libdir)/pkgconfig
|
pkgconfigdir = ${libdir}/pkgconfig
|
||||||
pkgconfig_DATA = libzoneminder.pc
|
pkgconfig_DATA = libzoneminder.pc
|
||||||
|
|
||||||
sysconf_DATA = plugins.conf
|
sysconf_DATA = plugins.conf
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
prefix=@prefix@
|
prefix = @ZM_PREFIX@
|
||||||
exec_prefix=${prefix}
|
exec_prefix = ${prefix}
|
||||||
libdir=@libdir@
|
libdir = @ZM_PLUGINSLIBDIR@
|
||||||
pkglibdir = @PLUGINSLIBDIR@
|
pkglibdir = @ZM_PLUGINSPKGLIBDIR@
|
||||||
includedir=@includedir@
|
includedir = ${prefix}/include
|
||||||
sysconfdir = @PLUGINSCONFDIR@
|
sysconfdir = @ZM_PLUGINSCONFDIR@
|
||||||
webdir = @PLUGINSWEBDIR@
|
webdir = @ZM_PLUGINSWEBDIR@
|
||||||
|
|
||||||
Name: : ZoneMinder convenience library for plugin development.
|
Name: @ZM_PROJECTNAME@
|
||||||
Description: ZoneMinder convenience library for plugin development.
|
Description: ZoneMinder convenience library for plugin development.
|
||||||
Version: @PACKAGE_VERSION@
|
Version: @ZM_VERSION@
|
||||||
Requires:
|
Requires:
|
||||||
Requires.private:
|
Requires.private:
|
||||||
Conflicts:
|
Conflicts:
|
||||||
Libs: -L${libdir} -lzoneminder @LIBS@
|
Libs: -L${libdir} -lzoneminder @LIBS@
|
||||||
Libs.private :
|
Libs.private:
|
||||||
Cflags: -I${includedir}/@PACKAGE@
|
Cflags: -I${includedir}/zoneminder
|
||||||
|
|
|
@ -3993,7 +3993,7 @@ body = "ZM alarm detected - %EL% secs, %EF%/%EFA% frames, t%EST%/m%ESM%/a%ESA% s
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name => "ZM_PATH_PLUGINS",
|
name => "ZM_PATH_PLUGINS",
|
||||||
default => "@PLUGINSLIBDIR@",
|
default => "@ZM_PLUGINSPKGLIBDIR@",
|
||||||
description => "Path to the plugin folder",
|
description => "Path to the plugin folder",
|
||||||
help => "3d-party plugins have to be placed here.",
|
help => "3d-party plugins have to be placed here.",
|
||||||
type => $types{abs_path},
|
type => $types{abs_path},
|
||||||
|
@ -4001,7 +4001,7 @@ body = "ZM alarm detected - %EL% secs, %EF%/%EFA% frames, t%EST%/m%ESM%/a%ESA% s
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name => "ZM_PLUGIN_EXTENSION",
|
name => "ZM_PLUGIN_EXTENSION",
|
||||||
default => "@PLUGINSEXT@",
|
default => "@ZM_PLUGINSEXT@",
|
||||||
description => "Default extension of plugins to found.",
|
description => "Default extension of plugins to found.",
|
||||||
help => "Default extension of plugins to found.",
|
help => "Default extension of plugins to found.",
|
||||||
type => $types{rel_path},
|
type => $types{rel_path},
|
||||||
|
@ -4017,7 +4017,7 @@ body = "ZM alarm detected - %EL% secs, %EF%/%EFA% frames, t%EST%/m%ESM%/a%ESA% s
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name => "ZM_PLUGINS_CONFIG_DIR",
|
name => "ZM_PLUGINS_CONFIG_DIR",
|
||||||
default => "@PLUGINSCONFDIR@",
|
default => "@ZM_PLUGINSCONFDIR@",
|
||||||
description => "Path to the config folder for plugins.",
|
description => "Path to the config folder for plugins.",
|
||||||
help => "Path to the config folder for plugins.",
|
help => "Path to the config folder for plugins.",
|
||||||
type => $types{abs_path},
|
type => $types{abs_path},
|
||||||
|
|
|
@ -6,8 +6,24 @@ configure_file(zm_config.h.in "${CMAKE_CURRENT_BINARY_DIR}/zm_config.h" @ONLY)
|
||||||
# Group together all the source files that are used by all the binaries (zmc, zma, zmu, zms etc)
|
# Group together all the source files that are used by all the binaries (zmc, zma, zmu, zms etc)
|
||||||
set(ZM_BIN_SRC_FILES zm_box.cpp zm_buffer.cpp zm_camera.cpp zm_comms.cpp zm_config.cpp zm_coord.cpp zm_curl_camera.cpp zm.cpp zm_db.cpp zm_logger.cpp zm_event.cpp zm_exception.cpp zm_file_camera.cpp zm_ffmpeg_camera.cpp zm_image.cpp zm_jpeg.cpp zm_libvlc_camera.cpp zm_local_camera.cpp zm_monitor.cpp zm_ffmpeg.cpp zm_mpeg.cpp zm_poly.cpp zm_regexp.cpp zm_remote_camera.cpp zm_remote_camera_http.cpp zm_remote_camera_rtsp.cpp zm_rtp.cpp zm_rtp_ctrl.cpp zm_rtp_data.cpp zm_rtp_source.cpp zm_rtsp.cpp zm_rtsp_auth.cpp zm_sdp.cpp zm_signal.cpp zm_stream.cpp zm_thread.cpp zm_time.cpp zm_timer.cpp zm_user.cpp zm_utils.cpp zm_zone.cpp)
|
set(ZM_BIN_SRC_FILES zm_box.cpp zm_buffer.cpp zm_camera.cpp zm_comms.cpp zm_config.cpp zm_coord.cpp zm_curl_camera.cpp zm.cpp zm_db.cpp zm_logger.cpp zm_event.cpp zm_exception.cpp zm_file_camera.cpp zm_ffmpeg_camera.cpp zm_image.cpp zm_jpeg.cpp zm_libvlc_camera.cpp zm_local_camera.cpp zm_monitor.cpp zm_ffmpeg.cpp zm_mpeg.cpp zm_poly.cpp zm_regexp.cpp zm_remote_camera.cpp zm_remote_camera_http.cpp zm_remote_camera_rtsp.cpp zm_rtp.cpp zm_rtp_ctrl.cpp zm_rtp_data.cpp zm_rtp_source.cpp zm_rtsp.cpp zm_rtsp_auth.cpp zm_sdp.cpp zm_signal.cpp zm_stream.cpp zm_thread.cpp zm_time.cpp zm_timer.cpp zm_user.cpp zm_utils.cpp zm_zone.cpp)
|
||||||
|
|
||||||
|
if(ZM_PLUGIN_SUPPORT)
|
||||||
|
set(ZM_BIN_SRC_FILES ${ZM_BIN_SRC_FILES} zm_detector.cpp zm_image_analyser.cpp zm_plugin.cpp zm_plugin_manager.cpp)
|
||||||
|
endif(ZM_PLUGIN_SUPPORT)
|
||||||
|
|
||||||
|
# with -fPIC
|
||||||
|
IF(UNIX AND NOT WIN32)
|
||||||
|
FIND_PROGRAM(CMAKE_UNAME uname /bin /usr/bin /usr/local/bin )
|
||||||
|
IF(CMAKE_UNAME)
|
||||||
|
EXEC_PROGRAM(uname ARGS -m OUTPUT_VARIABLE CMAKE_SYSTEM_PROCESSOR)
|
||||||
|
SET(CMAKE_SYSTEM_PROCESSOR ${CMAKE_SYSTEM_PROCESSOR} CACHE INTERNAL "processor type (i386 and x86_64)")
|
||||||
|
IF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
|
||||||
|
ADD_DEFINITIONS(-fPIC)
|
||||||
|
ENDIF(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
|
||||||
|
ENDIF(CMAKE_UNAME)
|
||||||
|
ENDIF(UNIX AND NOT WIN32)
|
||||||
|
|
||||||
# A fix for cmake recompiling the source files for every target.
|
# A fix for cmake recompiling the source files for every target.
|
||||||
add_library(zm STATIC ${ZM_BIN_SRC_FILES})
|
add_library(zoneminder STATIC ${ZM_BIN_SRC_FILES})
|
||||||
|
|
||||||
add_executable(zmc zmc.cpp)
|
add_executable(zmc zmc.cpp)
|
||||||
add_executable(zma zma.cpp)
|
add_executable(zma zma.cpp)
|
||||||
|
@ -16,14 +32,18 @@ add_executable(zmf zmf.cpp)
|
||||||
add_executable(zms zms.cpp)
|
add_executable(zms zms.cpp)
|
||||||
add_executable(zmstreamer zmstreamer.cpp)
|
add_executable(zmstreamer zmstreamer.cpp)
|
||||||
|
|
||||||
target_link_libraries(zmc zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zmc -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
target_link_libraries(zma zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zma -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
target_link_libraries(zmu zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zmu -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
target_link_libraries(zmf zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zmf -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
target_link_libraries(zms zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zms -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
target_link_libraries(zmstreamer zm ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
target_link_libraries(zmstreamer -ldl zoneminder ${ZM_EXTRA_LIBS} ${ZM_BIN_LIBS})
|
||||||
|
|
||||||
install(TARGETS zmc zma zmu zmf zmstreamer RUNTIME DESTINATION "${CMAKE_INSTALL_FULL_BINDIR}" PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
|
install(TARGETS zmc zma zmu zmf zmstreamer RUNTIME DESTINATION "${CMAKE_INSTALL_FULL_BINDIR}" PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
|
||||||
install(TARGETS zms RUNTIME DESTINATION "${ZM_CGIDIR}" PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
|
install(TARGETS zms RUNTIME DESTINATION "${ZM_CGIDIR}" PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
|
||||||
install(CODE "execute_process(COMMAND ln -sf zms nph-zms WORKING_DIRECTORY \"\$ENV{DESTDIR}${ZM_CGIDIR}\")")
|
install(CODE "execute_process(COMMAND ln -sf zms nph-zms WORKING_DIRECTORY \"\$ENV{DESTDIR}${ZM_CGIDIR}\")")
|
||||||
|
|
||||||
|
if(ZM_PLUGIN_SUPPORT)
|
||||||
|
install(FILES jinclude.h zm_db.h zm_detector.h zm_logger.h zm_poly.h zm_mem_utils.h zm_box.h zm_ffmpeg.h zm_plugin_manager.h zm_plugin.h zm_config.h zm_config_defines.h zm_jpeg.h zm_mpeg.h zm_image_analyser.h zm_zone.h zm_rgb.h zm_utils.h zm.h zm_event.h zm_stream.h zm_coord.h zm_image.h DESTINATION include/zoneminder)
|
||||||
|
install(TARGETS zoneminder ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}")
|
||||||
|
endif(ZM_PLUGIN_SUPPORT)
|
||||||
|
|
|
@ -144,7 +144,7 @@ noinst_HEADERS = \
|
||||||
zm_timer.h \
|
zm_timer.h \
|
||||||
zm_user.h
|
zm_user.h
|
||||||
|
|
||||||
if ZM_HAS_PLUGIN_SUPPORT
|
if ZM_PLUGIN_SUPPORT
|
||||||
# Add objects to zm binaries for plugins management
|
# Add objects to zm binaries for plugins management
|
||||||
zm_SOURCES += \
|
zm_SOURCES += \
|
||||||
zm_detector.cpp \
|
zm_detector.cpp \
|
||||||
|
|
Loading…
Reference in New Issue