diff --git a/CMakeLists.txt b/CMakeLists.txt index 198686939..6196d37a6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -726,6 +726,11 @@ endif(zmconfgen_result EQUAL 0) # Install zm.conf install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm.conf" DESTINATION "${ZM_CONFIG_DIR}") +if(ZM_PLUGIN_SUPPORT) + # Install config.h + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/config.h" DESTINATION include/zoneminder) +endif(ZM_PLUGIN_SUPPORT) + # Uninstall target configure_file( "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in" diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index effdd5b2b..b4ac10ed8 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -44,6 +44,7 @@ install(TARGETS zms RUNTIME DESTINATION "${ZM_CGIDIR}" PERMISSIONS OWNER_WRITE O 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(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_jpeg.h zm_mpeg.h zm_image_analyser.h zm_zone.h zm_rgb.h zm_utils.h zm_event.h zm_stream.h zm_coord.h zm_image.h DESTINATION include/zoneminder) + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_config.h" "${CMAKE_CURRENT_BINARY_DIR}/zm_config_defines.h"DESTINATION include/zoneminder) install(TARGETS zoneminder ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}") endif(ZM_PLUGIN_SUPPORT) diff --git a/src/Makefile.am b/src/Makefile.am index bd5b8ee58..410e10104 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -73,7 +73,6 @@ SOURCES_common = \ # convenience library HEADERS_common = \ jinclude.h \ - zm.h \ zm_box.h \ zm_config_defines.h \ zm_config.h \ diff --git a/src/zm_box.h b/src/zm_box.h index 8aa341d73..7880f1580 100644 --- a/src/zm_box.h +++ b/src/zm_box.h @@ -20,7 +20,6 @@ #ifndef ZM_BOX_H #define ZM_BOX_H -#include "zm.h" #include "zm_coord.h" #ifndef SOLARIS diff --git a/src/zm_buffer.h b/src/zm_buffer.h index af043ae13..908642a2c 100644 --- a/src/zm_buffer.h +++ b/src/zm_buffer.h @@ -20,7 +20,7 @@ #ifndef ZM_BUFFER_H #define ZM_BUFFER_H -#include "zm.h" +#include "zm_logger.h" #include diff --git a/src/zm_comms.h b/src/zm_comms.h index ef1dda833..9987364fe 100644 --- a/src/zm_comms.h +++ b/src/zm_comms.h @@ -21,6 +21,7 @@ #define ZM_COMMS_H #include "zm_exception.h" +#include "zm_logger.h" #include #include diff --git a/src/zm_coord.h b/src/zm_coord.h index 6a6620529..1ca28a0ca 100644 --- a/src/zm_coord.h +++ b/src/zm_coord.h @@ -20,8 +20,6 @@ #ifndef ZM_COORD_H #define ZM_COORD_H -#include "zm.h" - // // Class used for storing an x,y pair, i.e. a coordinate // diff --git a/src/zm_event.h b/src/zm_event.h index b06da823b..9ed310ea2 100644 --- a/src/zm_event.h +++ b/src/zm_event.h @@ -34,7 +34,6 @@ #include #include -#include "zm.h" #include "zm_image.h" #include "zm_stream.h" diff --git a/src/zm_exception.h b/src/zm_exception.h index 4af60bfa6..bec028321 100644 --- a/src/zm_exception.h +++ b/src/zm_exception.h @@ -20,8 +20,6 @@ #ifndef ZM_EXCEPTION_H #define ZM_EXCEPTION_H -#include "zm.h" - #include class Exception diff --git a/src/zm_ffmpeg.h b/src/zm_ffmpeg.h index fd124ca37..4c824ec84 100644 --- a/src/zm_ffmpeg.h +++ b/src/zm_ffmpeg.h @@ -20,7 +20,7 @@ #ifndef ZM_FFMPEG_H #define ZM_FFMPEG_H #include -#include "zm.h" + #include "zm_image.h" #ifdef __cplusplus diff --git a/src/zm_image.h b/src/zm_image.h index 46c7a031b..bcd152ed3 100644 --- a/src/zm_image.h +++ b/src/zm_image.h @@ -20,7 +20,6 @@ #ifndef ZM_IMAGE_H #define ZM_IMAGE_H -#include "zm.h" extern "C" { #include "zm_jpeg.h" @@ -31,6 +30,7 @@ extern "C" #include "zm_poly.h" #include "zm_mem_utils.h" #include "zm_utils.h" +#include "zm_logger.h" #include diff --git a/src/zm_image_analyser.h b/src/zm_image_analyser.h index b89aa11a9..cd8c46b35 100644 --- a/src/zm_image_analyser.h +++ b/src/zm_image_analyser.h @@ -1,8 +1,6 @@ #ifndef ZM_IMAGE_ANALYSER_H #define ZM_IMAGE_ANALYSER_H - - #include #include #include @@ -10,18 +8,14 @@ #include #include -#include "zm.h" #include "zm_detector.h" #include "zm_image.h" #include "zm_zone.h" #include "zm_event.h" #include "zm_db.h" - - using namespace std; - //! List of available detectors. typedef std::list DetectorsList; diff --git a/src/zm_local_camera.h b/src/zm_local_camera.h index 89c6799ca..132fb567f 100644 --- a/src/zm_local_camera.h +++ b/src/zm_local_camera.h @@ -20,7 +20,6 @@ #ifndef ZM_LOCAL_CAMERA_H #define ZM_LOCAL_CAMERA_H -#include "zm.h" #include "zm_camera.h" #include "zm_image.h" diff --git a/src/zm_mem_utils.h b/src/zm_mem_utils.h index 8ce1ceea1..f89dbe2db 100644 --- a/src/zm_mem_utils.h +++ b/src/zm_mem_utils.h @@ -21,7 +21,6 @@ #define ZM_MEM_UTILS_H #include -#include "zm.h" inline void* zm_mallocaligned(unsigned int reqalignment, size_t reqsize) { uint8_t* retptr; diff --git a/src/zm_monitor.h b/src/zm_monitor.h index 00307519d..a982ea720 100644 --- a/src/zm_monitor.h +++ b/src/zm_monitor.h @@ -23,7 +23,6 @@ #include #include -#include "zm.h" #include "zm_coord.h" #include "zm_image.h" #include "zm_rgb.h" diff --git a/src/zm_poly.h b/src/zm_poly.h index 854a3c322..fe7463078 100644 --- a/src/zm_poly.h +++ b/src/zm_poly.h @@ -20,7 +20,6 @@ #ifndef ZM_POLY_H #define ZM_POLY_H -#include "zm.h" #include "zm_coord.h" #include "zm_box.h" diff --git a/src/zm_regexp.h b/src/zm_regexp.h index f1c9d705d..177d083b4 100644 --- a/src/zm_regexp.h +++ b/src/zm_regexp.h @@ -17,8 +17,6 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "zm.h" - #ifndef ZM_REGEXP_H #define ZM_REGEXP_H diff --git a/src/zm_rgb.h b/src/zm_rgb.h index bfef10501..4c440489b 100644 --- a/src/zm_rgb.h +++ b/src/zm_rgb.h @@ -20,6 +20,8 @@ #ifndef ZM_RGB_H #define ZM_RGB_H +#include + typedef uint32_t Rgb; // RGB colour type #define WHITE 0xff diff --git a/src/zm_rtp.h b/src/zm_rtp.h index 6fbeeabe6..9637a734f 100644 --- a/src/zm_rtp.h +++ b/src/zm_rtp.h @@ -20,8 +20,6 @@ #ifndef ZM_RTP_H #define ZM_RTP_H -#include "zm.h" - #define RTP_VERSION 2 #endif // ZM_RTP_H diff --git a/src/zm_rtsp.h b/src/zm_rtsp.h index 937646b6d..c1dea8b39 100644 --- a/src/zm_rtsp.h +++ b/src/zm_rtsp.h @@ -20,7 +20,6 @@ #ifndef ZM_RTSP_H #define ZM_RTSP_H -#include "zm.h" #include "zm_ffmpeg.h" #include "zm_comms.h" #include "zm_thread.h" diff --git a/src/zm_sdp.h b/src/zm_sdp.h index fb56a2886..b348abc81 100644 --- a/src/zm_sdp.h +++ b/src/zm_sdp.h @@ -20,8 +20,6 @@ #ifndef ZM_SDP_H #define ZM_SDP_H -#include "zm.h" - #include "zm_utils.h" #include "zm_exception.h" #include "zm_ffmpeg.h" diff --git a/src/zm_signal.h b/src/zm_signal.h index 0302b47ee..5d61c9a51 100644 --- a/src/zm_signal.h +++ b/src/zm_signal.h @@ -29,9 +29,6 @@ #include #endif - -#include "zm.h" - typedef RETSIGTYPE (SigHandler)( int ); extern bool zm_reload; diff --git a/src/zm_stream.h b/src/zm_stream.h index ef442ab8e..edab321d8 100644 --- a/src/zm_stream.h +++ b/src/zm_stream.h @@ -23,7 +23,6 @@ #include #include -#include "zm.h" #include "zm_mpeg.h" class Monitor; diff --git a/src/zm_thread.h b/src/zm_thread.h index 615bec6aa..5e9107b37 100644 --- a/src/zm_thread.h +++ b/src/zm_thread.h @@ -20,6 +20,8 @@ #ifndef ZM_THREAD_H #define ZM_THREAD_H +#include "zm_config.h" + #include #include #include diff --git a/src/zm_time.h b/src/zm_time.h index 646133feb..502dc1a59 100644 --- a/src/zm_time.h +++ b/src/zm_time.h @@ -20,7 +20,12 @@ #ifndef ZM_TIME_H #define ZM_TIME_H -#include "zm.h" +#include "zm_config.h" +#include "zm_logger.h" + +#ifdef HAVE_STDDEF_H +#include +#endif #include diff --git a/src/zm_user.h b/src/zm_user.h index 95fb71474..94fc9ec16 100644 --- a/src/zm_user.h +++ b/src/zm_user.h @@ -17,7 +17,6 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "zm.h" #include "zm_db.h" #ifndef ZM_USER_H