Compare commits

...

1217 Commits

Author SHA1 Message Date
Isaac Connor e943f0a411
Merge pull request #3450 from gonzalezcalleja/fix_zmpkg
Fix when using a custom state with zmpkg.pl
2022-03-08 11:21:00 -05:00
Javier Gonzalez 858ab62fc4 Fix when using a custom state 2022-03-08 17:10:29 +01:00
Isaac Connor 05b5ca9b15 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-03-08 09:06:37 -05:00
Isaac Connor 0785e3571c code style, remove duplicated code. 2022-03-08 09:06:31 -05:00
Isaac Connor a748b0ed0a When connecting to a monitor, if it fails, disconnect. This should fix a bug in zmtrigger and others where it would never reconnect. The idea is that we asked for a successful connection, if it failed, we shouldn't be in a failed connected state, we should be disconnected. 2022-03-08 09:06:06 -05:00
Isaac Connor 8fe0cb5e33 tidy up the mem_info hash and turn into a hash instead of a pointer to a hash. Check for validity flah before checking sizes. Improve debug logging. 2022-03-08 09:04:41 -05:00
Isaac Connor b13fd68376
Merge pull request #3449 from jp-bennett/master
Add rtsp_quirk to Janus mountpoints.
2022-03-05 12:48:47 -05:00
Jonathan Bennett 9f4df40ac5 Add rtsp_quirk to Janus mountpoints.
Workaround for Vivotek and possibly other cameras that use nonstandard RTSP URIs,
2022-03-04 20:40:56 -06:00
Isaac Connor 10402fdabe Use template backticks for the Notes string to handle multi-line 2022-03-04 13:41:19 -05:00
Isaac Connor 8db08f5a10 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-03-04 12:09:44 -05:00
Isaac Connor 69856f2b8c Delete zm_update-1.37.multistream.sql asit has been merged to 1.37.12 2022-03-04 12:09:41 -05:00
Isaac Connor 1fb42d0b77 Change api of selectLayout. Now takes a value. use MonitorStream.setScale to set image scale. In general fix behaviour when switching between fixed sizes, scales and layouts 2022-03-04 12:08:29 -05:00
Isaac Connor 920f5470a8 Don't set width&height on img. img is always 100% of container. Don't show zoom unless it is != 1.0. Only update buttons if there is a change, to reduce redraws 2022-03-04 12:07:32 -05:00
Isaac Connor 0c31e35b4e Add classes to fields of monitor status so we can style them as needed 2022-03-04 12:06:49 -05:00
Isaac Connor 9b9746113e If we asked for stream, keep streaming even not decoding or other problem. We will wait for the situation to change 2022-03-04 12:06:24 -05:00
Isaac Connor 5b9ca3f164
Merge pull request #3447 from jp-bennett/master
Adds support for Janus 1.x
2022-02-28 20:49:56 -05:00
Jonathan Bennett c28c043773 Adds support for Janus 1.x 2022-02-28 18:05:17 -06:00
Isaac Connor 3a8b46b7df
Merge pull request #3446 from jp-bennett/master
Add additional Firefox streaming workaround
2022-02-28 15:50:49 -05:00
Isaac Connor 494da65b9a Replace use of Function with Recording 2022-02-28 15:46:38 -05:00
Isaac Connor 7283f8629a Function dropdown no longer exists 2022-02-28 15:44:15 -05:00
Isaac Connor addfdcd330 Remove sets::isin references 2022-02-28 15:41:57 -05:00
Jonathan Bennett 1749afc8e2 Add additional Firefox streaming workaround 2022-02-28 14:17:19 -06:00
Isaac Connor eee6053293 Only startup a new event if recording==ALWAYS 2022-02-28 13:35:11 -05:00
Isaac Connor 433782bd6e disable yellow dot when analysing turned off. Enabled is gone... need to do a more interesting check 2022-02-28 13:34:51 -05:00
Isaac Connor 980aaa5942 Fix case of recording events when Recording==NONE 2022-02-28 12:10:14 -05:00
Isaac Connor e31b18a1a6 Use a define to disable y-channel use 2022-02-28 12:02:09 -05:00
Isaac Connor a32b77510d Fix logic on error reporting of failure to connect to db 2022-02-28 09:38:54 -05:00
Isaac Connor 7ef9824736 Handle NoDect case 2022-02-28 09:11:48 -05:00
Isaac Connor 1ae8fcae63 add a label for rateControl 2022-02-27 14:31:04 -05:00
Isaac Connor 5b319258c4 fix eslint 2022-02-27 14:26:05 -05:00
Isaac Connor abb8aa5da5 bump version for function replacement 2022-02-27 14:17:14 -05:00
Isaac Connor 3b9d13eb8e rename to 1.37.12 and add missing updates for other functions 2022-02-27 14:16:40 -05:00
Isaac Connor cf31db0bad Merge branch 'master' into replace_function_concept 2022-02-27 14:05:34 -05:00
Isaac Connor 133553e630 Revert "Merge pull request #3119 from Carbenium/fmt"
This reverts commit 90d930c7c3, reversing
changes made to 0bcb9d276f.
2022-02-27 14:05:14 -05:00
Isaac Connor e33b41745d Merge branch 'master' into replace_function_concept 2022-02-27 14:04:01 -05:00
Isaac Connor 1d15de0534 Make getMonitorCapturingOptions a member of the class, so can call it getCapturingOptions. Same with Analysing and Recording options 2022-02-27 14:03:48 -05:00
Isaac Connor 13251b133a Make getMonitorCapturingOptions a member of the class, so can call it getCapturingOptions. Same with Analysing and Recording options 2022-02-27 14:03:37 -05:00
Isaac Connor 46c43ca508 Revert "Fix fmt=>Fmt and add it's libs to list of libraries to link to"
This reverts commit d5101ef32a.
2022-02-27 13:46:52 -05:00
Isaac Connor c5b9ed9451 Revert "Fix zms build"
This reverts commit e6b36bb186.
2022-02-27 13:46:51 -05:00
Isaac Connor 57da477f69 Revert "Install fmt-devel"
This reverts commit fad152e93d.
2022-02-27 13:46:50 -05:00
Isaac Connor c3485a6840 Revert "Add libfmt-dev"
This reverts commit d8eaaa4a50.
2022-02-27 13:46:32 -05:00
Isaac Connor d8eaaa4a50 Add libfmt-dev 2022-02-27 11:07:10 -05:00
Isaac Connor fad152e93d Install fmt-devel 2022-02-27 10:53:07 -05:00
Isaac Connor e6b36bb186 Fix zms build 2022-02-27 10:41:42 -05:00
Isaac Connor d5101ef32a Fix fmt=>Fmt and add it's libs to list of libraries to link to 2022-02-27 10:41:40 -05:00
Isaac Connor 90d930c7c3
Merge pull request #3119 from Carbenium/fmt
Add fmt library for type-safe string formatting
2022-02-27 10:37:41 -05:00
Isaac Connor 47fae7a296 spacing, improve debug 2022-02-26 19:18:28 -05:00
Isaac Connor 0bcb9d276f code style. 2022-02-26 18:25:51 -05:00
Isaac Connor 914581bc57 add libavdevice-dev and libgsoap-dev to build 2022-02-26 18:25:51 -05:00
Isaac Connor 2bd85089f4 Put integers in quotes as well. Proper JSON has all values in quotes. This is important because integers like 0123 are invalid 2022-02-26 18:25:51 -05:00
Isaac Connor cad57df0bb
Merge branch 'master' into fmt 2022-02-26 13:56:20 -05:00
Isaac Connor 6fc5803e16 Add another clearInterval to prevent looping during window.location 2022-02-25 15:54:56 -05:00
Isaac Connor 9b0714d20d Fix use of value instead of val in filter term 2022-02-25 14:14:02 -05:00
Isaac Connor 813fd36b0a clearInterval when location.replacing so that timer stops. Prevents infinite loop 2022-02-25 14:13:18 -05:00
Isaac Connor 372e493b9c
Merge pull request #3442 from BHMSD-bdailey/lazy-load-images
Lazy load images
2022-02-22 08:57:49 -05:00
Ben Dailey b2428b5522 Merge branch 'master' into lazy-load-images 2022-02-22 08:47:26 -05:00
Isaac Connor 831dca814f Include EndDateTimeShort in event stats 2022-02-22 08:31:41 -05:00
Isaac Connor dfb6a96b42 Handle empty endtime more gracefully. If there is a next event just jump to it. 2022-02-22 08:31:41 -05:00
Isaac Connor 959b08f46a Include EndDateTimeShort in event ajax response 2022-02-22 08:31:41 -05:00
Isaac Connor 347d3c08b6 Spacing, remove dead code, add comments. When implementing CLOSE_ALARM mode, check Alarm Frames against alarm_frame_count instead of 0. 2022-02-22 08:31:41 -05:00
Isaac Connor 968acc2d43 Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. 2022-02-22 08:31:41 -05:00
Isaac Connor 26d89292d7 Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. 2022-02-22 08:31:41 -05:00
Isaac Connor e9b3269278 cleanup and add fallback to read/write if no sendfile support. 2022-02-22 08:31:41 -05:00
Isaac Connor 00b4ed9c53 Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. Use new reworked zm_sendfile and handle if not all bytes are sent. Fixes #3437. 2022-02-22 08:31:41 -05:00
Isaac Connor d7c8e32ec9 Remove non-translations 2022-02-22 08:31:41 -05:00
Isaac Connor 0da942a14b rework zm_sendfile to try again if not all bytes were sent. According to the docs, this is entirely possible. 2022-02-22 08:31:41 -05:00
Isaac Connor 88a68af775 DefaultCodec is for event view, not live 2022-02-22 08:31:41 -05:00
Isaac Connor cf7b3b9f9f DefaultCodec is for event view, not live 2022-02-22 08:31:41 -05:00
Andrew Bauer bcd590aede use rockylinux:8 container for ci workflow 2022-02-22 08:31:41 -05:00
Andrew Bauer b5e2cb4220 include arp-scan polkit files in rpm 2022-02-22 08:31:41 -05:00
Andrew Bauer 2c7e90d61d bump rpm specfile rtsp commit
anytime the rtsp commit is bumped in packpack, it must also be bumped in the rpm specfile
2022-02-22 08:31:41 -05:00
Isaac Connor 3a2e5a580b Debug the contents of REQUEST on every hit. 2022-02-22 08:31:41 -05:00
Isaac Connor 5aef8408a4 serialize form instead of just passing filter id because the modal can now handle unsaved filters 2022-02-22 08:31:41 -05:00
Isaac Connor b32164e992 Add handling of NOT IN and =\[\] and \!\[\] 2022-02-22 08:31:41 -05:00
Isaac Connor e523777ece Sync up n_frames, frame_count, curr_frame_id on int instead of a mix of long int, int and unsigned long int 2022-02-22 08:31:41 -05:00
Ben Dailey e4f5f59e8d 3 more img tags 2022-02-22 08:31:41 -05:00
Ben Dailey ce267c7e3c Most programmatic images are lazy. 2022-02-22 08:31:02 -05:00
Isaac Connor fc21fb643e Release lock before notify 2022-02-20 10:33:13 -05:00
Isaac Connor 02ccf13c7b Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-02-20 10:32:43 -05:00
Isaac Connor b896974a29 Should get lock before testing for connected 2022-02-20 10:32:40 -05:00
Isaac Connor f4412c81d1
Merge pull request #3441 from peat-psuwit/for-upstream/dbqueue-stop-mutex
db: fix dead lock in zmDbQueue::stop()
2022-02-20 10:32:19 -05:00
Isaac Connor a40b305065 Merge branch 'master' into replace_function_concept 2022-02-20 09:52:03 -05:00
Ratchanan Srirattanamet ebe502a747 db: fix dead lock in zmDbQueue::stop()
Notifying `mCondition` without taking the lock causes a race condition
in ::process() between checking `mTerminate` and waiting for the
`mCondition`, which causes a dead lock. This commit moves writing to
`mTerminate` and notifying `mCondition` under the lock to eliminate race
condition and dead lock.

This is not theoretical. It has caused zmu to hang at exit on a
Raspberry Pi 4, exhuasting PHP-FPM process pool. The stacks below are
captured when running ZoneMinder 1.36.12-focal1 on Ubuntu 20.04:

(gdb) thread apply all bt

Thread 2 (Thread 0xffff80c1c880 (LWP 259988)):
#0  futex_wait_cancelable (private=0, expected=0, futex_word=0xaaaae0584e80 <dbQueue+176>) at ../sysdeps/nptl/futex-internal.h:183
#1  __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0xaaaae0584e28 <dbQueue+88>, cond=0xaaaae0584e58 <dbQueue+136>) at pthread_cond_wait.c:508
#2  __pthread_cond_wait (cond=0xaaaae0584e58 <dbQueue+136>, mutex=0xaaaae0584e28 <dbQueue+88>) at pthread_cond_wait.c:638
#3  0x0000ffff8700d670 in std::condition_variable::wait(std::unique_lock<std::mutex>&) () from /lib/aarch64-linux-gnu/libstdc++.so.6
#4  0x0000aaaae0438f08 in zmDbQueue::process (this=0xaaaae0584dd0 <dbQueue>) at ./src/zm_db.cpp:250
#5  0x0000ffff87013fac in ?? () from /lib/aarch64-linux-gnu/libstdc++.so.6
#6  0x0000ffff891264fc in start_thread (arg=0xffffe60d84bf) at pthread_create.c:477
#7  0x0000ffff86dd767c in thread_start () at ../sysdeps/unix/sysv/linux/aarch64/clone.S:78

Thread 1 (Thread 0xffff80c23010 (LWP 259987)):
#0  __pthread_clockjoin_ex (threadid=281472841926784, thread_return=0x0, clockid=0, abstime=<optimized out>, block=<optimized out>) at pthread_join_common.c:145
#1  0x0000ffff87014240 in std:🧵:join() () from /lib/aarch64-linux-gnu/libstdc++.so.6
#2  0x0000aaaae04314d0 in exit_zmu (exit_code=0) at ./src/zmu.cpp:200
#3  0x0000aaaae042f4c8 in main (argc=<optimized out>, argv=<optimized out>) at ./src/zmu.cpp:797
2022-02-20 09:58:03 +00:00
Isaac Connor fe69261f10 Include MonitorId as second argument of EventStartCommand and EventEndCOmmand at @baudneo's request. 2022-02-19 15:33:05 -05:00
Isaac Connor dc8f1bc8ed Set shared_data->score before state transitions so that linked monitors pick it up. Should help with missed linked events 2022-02-18 17:44:23 -05:00
Isaac Connor fc541ac57d fix potential double lock of jpeg mutex 2022-02-18 17:11:18 -05:00
Isaac Connor 1a54a96c04 Improve title on alarm buttons when we don't have permission. Move onclick from data-on-click to setup in initPage only if permitted 2022-02-18 17:11:18 -05:00
Isaac Connor 002b2c39aa fix button assignments. Don't abort ajax, as it might be important 2022-02-18 17:11:18 -05:00
Isaac Connor 28f3cb18e4 Make std function warning into a debug. Warning will happen if they are actually used 2022-02-18 15:59:00 -05:00
Isaac Connor adf8413333 Include EndDateTimeShort in event stats 2022-02-17 13:31:25 -05:00
Isaac Connor 8dedac1a21 Handle empty endtime more gracefully. If there is a next event just jump to it. 2022-02-17 13:30:50 -05:00
Isaac Connor 909c0e903f Include EndDateTimeShort in event ajax response 2022-02-17 13:30:01 -05:00
Isaac Connor 1983801004 Merge branch 'master' into replace_function_concept 2022-02-16 18:49:01 -05:00
Isaac Connor b9e6cf8038 Spacing, remove dead code, add comments. When implementing CLOSE_ALARM mode, check Alarm Frames against alarm_frame_count instead of 0. 2022-02-16 17:27:17 -05:00
Isaac Connor cd2c977ed8 Merge branch 'master' into replace_function_concept 2022-02-16 14:25:38 -05:00
Isaac Connor c9de883a7c Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. 2022-02-16 14:18:37 -05:00
Isaac Connor 67563737c3 Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. 2022-02-16 14:16:46 -05:00
Isaac Connor 243c780a6a cleanup and add fallback to read/write if no sendfile support. 2022-02-16 14:16:25 -05:00
Isaac Connor 2336926d90 Rework to remove static temp_img_buffer. Is now a class member. Must be allocated as needed. Use new reworked zm_sendfile and handle if not all bytes are sent. Fixes #3437. 2022-02-16 14:16:01 -05:00
Isaac Connor f3d3cad419 Remove non-translations 2022-02-16 09:59:48 -05:00
Isaac Connor 2d3f99eabb rework zm_sendfile to try again if not all bytes were sent. According to the docs, this is entirely possible. 2022-02-16 09:59:48 -05:00
Isaac Connor 055414c778 DefaultCodec is for event view, not live 2022-02-16 09:59:48 -05:00
Isaac Connor 93ab345a3a DefaultCodec is for event view, not live 2022-02-16 09:59:48 -05:00
Andrew Bauer 9d400b9f6c
use rockylinux:8 container for ci workflow 2022-02-16 08:33:44 -06:00
Andrew Bauer a2a4a8e74f
include arp-scan polkit files in rpm 2022-02-16 08:22:37 -06:00
Andrew Bauer 59d283095d
bump rpm specfile rtsp commit
anytime the rtsp commit is bumped in packpack, it must also be bumped in the rpm specfile
2022-02-16 07:54:01 -06:00
Isaac Connor efc1ec770c Debug the contents of REQUEST on every hit. 2022-02-15 18:52:46 -05:00
Isaac Connor b67e7b8111 serialize form instead of just passing filter id because the modal can now handle unsaved filters 2022-02-15 18:52:46 -05:00
Isaac Connor 8b14885541 Add handling of NOT IN and =\[\] and \!\[\] 2022-02-15 18:52:46 -05:00
Isaac Connor 33f23cbd84 Sync up n_frames, frame_count, curr_frame_id on int instead of a mix of long int, int and unsigned long int 2022-02-15 18:52:46 -05:00
Isaac Connor 2bc0ec269a Merge branch 'master' into replace_function_concept 2022-02-15 17:02:03 -05:00
Isaac Connor 4f8aba0801 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-02-15 10:41:51 -05:00
Isaac Connor 956579d557 handle snap->in_frame being null. 2022-02-15 10:41:42 -05:00
Isaac Connor a149fa37fc Make filter debug modal work on non-saved filter 2022-02-15 10:37:14 -05:00
Isaac Connor b2e0f805bd Add NOT IN case. Also, fix bad SQL when value evals to false. Test for empty string instead. Fixes #3425 2022-02-15 10:29:58 -05:00
Isaac Connor 59039de985 Use =[] instead of IN as operator. Fixes #3432 2022-02-15 10:23:30 -05:00
Isaac Connor ecd27d033c
Merge pull request #3435 from ZoneMinder/revert-3434-3432-fix-events-view-filter-monitorid
Revert "Add SQL opTypes IN, NOT IN to filter view, #3432"
2022-02-15 10:07:59 -05:00
Isaac Connor 554840d811
Revert "Add SQL opTypes IN, NOT IN to filter view, #3432" 2022-02-15 10:07:48 -05:00
Isaac Connor 03bc24362f
Merge pull request #3434 from jjakob/3432-fix-events-view-filter-monitorid
Add SQL opTypes IN, NOT IN to filter view, #3432
2022-02-15 10:05:57 -05:00
Isaac Connor 5fd5c7fdd1 Maybe fix build on freebsd by including unistd.h 2022-02-15 10:04:37 -05:00
Jernej Jakob 13f2076dc9 Add SQL opTypes IN, NOT IN to filter view, #3432
This possibly fixes the issue where changing the filter for an event
view via the filter button would produce invalid SQL and SQL errors.

web_php[43835].ERR [1.2.3.4] [SQL-ERR 'SQLSTATE[HY000]: General error: 4078 Illegal parameter data types int and row for operation '='', statement was 'SELECT E.*, M.Name AS Monitor FROM `Events` AS E INNER JOIN Monitors AS M ON E.MonitorId = M.Id WHERE ( ( E.StartDateTime >= '2022-02-14 00:47:41'
 and E.StartDateTime <= '2022-02-14 11:47:41' )
 and E.MonitorId = ('1','3')
) ORDER BY E.StartDateTime DESC' params:] at /usr/share/zoneminder/www/includes/database.php line 161

When in the events view, clicking the filterBtn sends us to the filter view with this query term (url-decoded):

&filter[Query][terms][2][attr]=MonitorId&filter[Query][terms][2][op]=IN&filter[Query][terms][2][val]=1,3&filter[Query][sort_asc]=0

but the filter view displays this as "equals", not "in set", because it doesn't know IN from opTypes, only =[].
2022-02-15 14:15:08 +01:00
Isaac Connor c8a2b6d679 Merge branch 'master' into replace_function_concept 2022-02-14 12:03:25 -05:00
Isaac Connor b6d2d96d11 Remove offending extra comma 2022-02-14 09:47:59 -05:00
Isaac Connor 91b536b868 Change the test for slow functions to mod4. The unrolled and SSE function work on 4 pixels at a time or 16 or 12 bytes depending on colours.This will improve cpu use on resolutions like 1280x800 2022-02-14 09:43:48 -05:00
Isaac Connor 485cc26065 Merge branch 'master' into replace_function_concept 2022-02-12 22:17:47 -05:00
Isaac Connor f47aa98b43 html is not a global.. confusing yes. 2022-02-12 22:17:03 -05:00
Isaac Connor e3631099f6 Rename v_image to y_image cuz that's what it is 2022-02-12 22:14:51 -05:00
Isaac Connor 552974c5b7 Pass full packet to AddFrame so that we can also write other contents out 2022-02-12 22:14:21 -05:00
Isaac Connor 0e2f2cf572 Merge branch 'timeline_multi_monitor' 2022-02-11 18:08:41 -05:00
Isaac Connor 6e7e6d9e8e small code cleanup, add Warnings when using slow blend functions. 2022-02-11 18:06:43 -05:00
Isaac Connor 94bc40a6cf Split the data by monitor and display a monitor image/info for each monitor. 2022-02-11 18:06:42 -05:00
Isaac Connor 3250e0edfe simplify some code, pass around zm_event json objects instead of event_id. Each monitor has it's own image so when loading event data put it into a div/img referenced by monitor Id 2022-02-11 18:06:08 -05:00
Isaac Connor 4cc82e24f3 convert some tags to classes instead of ids. Add margin: 0 auto so that monitor images are centered 2022-02-11 18:04:54 -05:00
Isaac Connor cb80283398 Merge branch 'master' into timeline_multi_monitor
update code to use jquery instead of mootools
when only viewing 1 monitor, split view in half
load first event image righ toff the bat
2022-02-11 18:03:35 -05:00
Isaac Connor 514a64ad45 small code cleanup, add Warnings when using slow blend functions. 2022-02-11 12:43:10 -05:00
Isaac Connor b700e7b5ce
Merge pull request #3424 from r01k/master
Fixed in export.php "Class 'Filter' not found" and SQL query with wrong syntax
2022-02-10 21:39:50 -05:00
Isaac Connor 4507b06e29 libcurl4-gnutls-dev is actually a runtime dependency 2022-02-10 11:57:57 -05:00
Isaac Connor bcd0b6430b Convert Fatal()s to Errors() which is really more appropriate anyways. Maybe Fixes #3426 2022-02-08 18:12:06 -05:00
Isaac Connor b866888062 Change title of settings button to give an indication WHY it isn't enabled 2022-02-08 17:52:59 -05:00
Isaac Connor 9fee64b62f detaint language file. 2022-02-08 14:31:01 -05:00
Isaac Connor 2db781ed44 Test for valid language file when saving user. 2022-02-08 14:30:53 -05:00
Isaac Connor b1d235f991 Use getBodyTopHTML so that we get error messages in UI 2022-02-08 13:33:22 -05:00
Isaac Connor d7a8947e05 Only include janus.js if needed 2022-02-08 13:33:02 -05:00
Isaac Connor cc9306afe3 Change the error message banner to always take up space and be seen. 2022-02-08 13:32:37 -05:00
Isaac Connor 8cdd96f286 Implement a check on change of language. Make sure that the specified language file exists. Reports errors to UI 2022-02-08 13:29:51 -05:00
Isaac Connor 684078e72f re-enable y-channel motion detection 2022-02-08 12:08:41 -05:00
Isaac Connor f66a463574 Merge branch 'master' into replace_function_concept 2022-02-08 12:07:30 -05:00
Isaac Connor e7cd63a6ff replace Function with Recording, Analysing, Capturing 2022-02-08 11:22:41 -05:00
Isaac Connor b005927ea3 debug when no data.frames 2022-02-08 11:21:56 -05:00
Isaac Connor 390d77a924 Replace Function with Capturing 2022-02-08 11:21:36 -05:00
Isaac Connor 01fad8a0dc Replace Function monitor filter with Capturing, Analysing, Recording filters. 2022-02-08 11:21:16 -05:00
Isaac Connor dcf6e5da46 If there is an ajax error, and the error is unauthorized, then reload the page. 2022-02-08 11:20:54 -05:00
Isaac Connor 38c9ac1521 Update state action, replacing Function with Recording, Analysing, Capturing. Redirect to console instead of switching view. 2022-02-08 11:20:27 -05:00
Isaac Connor aad79d3407 Rename MonitorAnalysingOptions => AnalysingOptions as they will have to be prefixed with module name anyways. 2022-02-08 11:19:36 -05:00
Isaac Connor 03f6637060 Only load janus.js if we are using it 2022-02-08 11:03:25 -05:00
Isaac Connor a7dc9d4e36 Implement General::jsonLoad 2022-02-08 10:14:00 -05:00
Isaac Connor 2768975f96 Only notify one. Anyone waiting is waiting on a lock and only 1 process can get that lock, so only one should try. 2022-02-08 10:12:29 -05:00
Isaac Connor 8c13aa7d3a Cleanup LockedPacket, use RAII 2022-02-08 10:10:00 -05:00
Isaac Connor 8e689340ce Don't need to check for end of queue as we already did that when adding packet to the queue 2022-02-08 10:06:32 -05:00
Isaac Connor 2f5a403fc4 Handle when no swap is configured 2022-02-08 10:04:19 -05:00
Isaac Connor fe01af6966 Don't need to test for end() because we added our packet to the queue and still have the lock 2022-02-08 09:57:56 -05:00
Isaac Connor 33473eac6a Add arp-scan as a tool for getting list of devices on network. Add an interface specifier to monitor probe just like on onvif-probe. Rough in support for Hikvision cameras 2022-02-07 12:33:53 -05:00
Isaac Connor 2c23e18ea0 Add system path for arp-scan 2022-02-07 12:33:05 -05:00
Isaac Connor 2b468fa115 Add policykit rules for arp-scan 2022-02-07 12:32:50 -05:00
Isaac Connor d056f15e54 Add arp-scan to executable for use in network probing for cameras. 2022-02-07 12:32:16 -05:00
Isaac Connor 5078eecdfd Add in get_networks and get_subnets as utilities to parse devices and networks in preparation for scanning/probing 2022-02-07 12:31:31 -05:00
Isaac Connor 69053424cd When adding a new monitor, ModelId and ManufacturerId are not defined, so handle that 2022-02-06 19:06:35 -05:00
r01k 02d896abe2 Fixed in export.php "Class 'Filter' not found" and construction of SQL query with wrong syntax 2022-02-04 22:19:15 -05:00
Isaac Connor ac909d404a Use the reported move with x=0 y=0 for autostop in addition to old stop movement code 2022-02-03 18:19:07 -05:00
Isaac Connor 1982c21e1f
Merge pull request #3423 from jp-bennett/master
Starts moving elements from zm_monitor.cpp into nested classes and dedicated files.
2022-02-03 17:53:31 -05:00
Isaac Connor b3092f2f59 Add special handling for skip_locked, as it is a checkbox. Don't update REQUEST['Id'] on execute so we can redirect to the original filter. 2022-02-03 17:31:37 -05:00
Jonathan Bennett dde3884084 Moves Janus and Amcrest into their own nested classes 2022-02-03 16:31:07 -06:00
Isaac Connor a6dc7ba0fc Add debugging, but commented out 2022-02-03 17:30:38 -05:00
Isaac Connor ac39be33f5 Don't assume filename of mp4. We store it in the event record for a reason. Fixes #3422 2022-02-03 17:24:33 -05:00
Isaac Connor 3c655807e8 Use new Event->Server function to return the correct (and matching url to zms) url to use for ajax status calls. Fixes errors in a multi-server environment. 2022-02-03 14:47:32 -05:00
Isaac Connor 7a95aa7210 Don't render cues if we don't have any. This occurs on initial load we call changeScale which would re-render the cues but the cur ajax hasn't completed yet, so this just avoids an error being logged 2022-02-03 14:46:39 -05:00
Isaac Connor 7515711eb8 Implement Server function which figures out which Server likely has the video. Use it to remove duplicate logic 2022-02-03 14:45:17 -05:00
Isaac Connor 524662e6c7 Merge branch 'master' into replace_function_concept 2022-02-03 12:41:46 -05:00
Isaac Connor caebef3103 Replace uses of Function 2022-02-03 12:38:26 -05:00
Isaac Connor f40279b745 Remove active, add capturing, analysing, recording 2022-02-03 12:38:09 -05:00
Isaac Connor f7099bc6cb Replace another use of Function 2022-02-03 12:37:51 -05:00
Isaac Connor da4c880233 0 out another used of y-image 2022-02-03 12:16:01 -05:00
Isaac Connor d24b419f0e Only create packages for master 2022-02-03 12:06:00 -05:00
Isaac Connor 02a2c783e4 Disable alleged y-channel image motion detection. Doesn't work. 2022-02-03 11:57:27 -05:00
Isaac Connor 67ac0fdffd Disable alleged y-channel image motion detection. Doesn't work. 2022-02-03 11:57:00 -05:00
Isaac Connor 838704e58e Add more stop_ tests so that when we are told to terminate, we actually do so. 2022-02-03 11:40:17 -05:00
Isaac Connor b05bc211f7 Apparently it is actually the Y channel that we want. 2022-02-03 10:50:40 -05:00
Isaac Connor 7e9c707f92 V plane is actually the 3rd array entry, not the 4th 2022-02-03 10:06:36 -05:00
Isaac Connor fd7f7f851a V plane is actually the 3rd array entry, not the 4th 2022-02-03 08:19:08 -05:00
Jonathan Bennett 89e1c5d53c Move Monitor::MonitorLink to dedicated file 2022-02-02 16:51:27 -06:00
Isaac Connor bd68b9e3af Not ready for OutputSource yet 2022-02-02 17:10:05 -05:00
Isaac Connor 10e39b3b13 :wqMerge branch 'master' into replace_function_concept 2022-02-02 17:08:01 -05:00
Isaac Connor a4c91e9a3c Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-02-02 14:36:15 -05:00
Isaac Connor 339f102196 Implement reboot and ping methods for Trendnet PTZ Control 2022-02-02 14:36:11 -05:00
Isaac Connor 48fc99a0e3 Implement reboot and ping methods for Trendnet PTZ Control 2022-02-02 14:34:53 -05:00
Isaac Connor 606c47ba87 If possible, use the v-channel from the yuv420p image for motion detection instead of the rgba data. 2022-02-02 14:33:58 -05:00
Isaac Connor 70f4a68269 bump version for use_Amcrest_API 2022-02-02 13:13:00 -05:00
Isaac Connor 1f9e654821 Default limit to 0 which means no limit 2022-02-02 12:28:58 -05:00
Isaac Connor faabbabfd5
Merge pull request #3415 from jp-bennett/master
Adds Amcrest MD, makes libcurl a hard requirement, and removes a redundant JS define.
2022-02-02 12:28:35 -05:00
Isaac Connor 3feb4fcc51
Merge branch 'master' into master 2022-02-02 12:28:17 -05:00
Isaac Connor 31eff49a46 Implement filter limits. Which go before pagination/advanced search limits 2022-02-02 10:49:05 -05:00
Isaac Connor 4874dedc1f Bump version of RtspServer used 2022-02-02 10:28:23 -05:00
Isaac Connor 5b10f6ace6
Merge pull request #3421 from JedMeister/patch-1
Update MariaDB Bullseye info in docs
2022-02-01 22:47:58 -05:00
Jeremy Davis 63b3042d37
fix typo 2022-02-02 14:18:26 +11:00
Jeremy Davis ad0a095886
Update MariaDB Bullseye info
Specifically note that setting a root password is not required (or recommended; unix socket authentication is better than simple password auth).
2022-02-02 11:35:36 +11:00
Isaac Connor 1c1630e5b4 add require Filter and fix missing $ 2022-02-01 17:23:16 -05:00
Isaac Connor 4d87b49f07 Remove weird cutnpaste User modules stuff from top of Filter.pm 2022-02-01 17:22:56 -05:00
Isaac Connor e69095a9b4 Fix == to = 2022-02-01 17:22:23 -05:00
Isaac Connor 3d5767b326 Merge branch 'master' into multistream 2022-02-01 16:52:42 -05:00
Isaac Connor 18532096c5 Need full commits to get # of commits since last version change 2022-02-01 16:10:46 -05:00
Isaac Connor 4949159b88 Rough in pcm alaw support. Untested. 2022-02-01 14:06:12 -05:00
Isaac Connor 80461cb135 add libcurl4 as a dependency as it was in build-depends. 2022-02-01 13:36:11 -05:00
Isaac Connor bc4884afe5 fix replacement on escape. For some reason needs double bacl slash 2022-02-01 10:07:04 -05:00
Isaac Connor 462ec45a07 Escape newlines in config values. 2022-02-01 09:46:37 -05:00
Isaac Connor 34d7f192b4 Remove field that ffmpeg 5.0 doesn't have. 2022-02-01 07:23:12 -05:00
Isaac Connor 0eb4d95d0e remove geolocation copies from config to javscript land. Now all of config is brought in my skin.js.php 2022-01-31 18:33:03 -05:00
Isaac Connor ad32466aa4 Remove function, replacing with capturing, analysing, recording. Adjust formatting of list function 2022-01-31 18:17:31 -05:00
Isaac Connor 6b8cc14723 Don't free image data if we added the packet to an event. The lock moves to the event so it's not safe 2022-01-31 12:07:09 -05:00
Isaac Connor b00ca5ce91 upload entire build dir as shell expansions don't seem to work 2022-01-31 11:47:42 -05:00
Isaac Connor 3a2484b874 Try a different ssh implementation 2022-01-31 11:19:36 -05:00
Isaac Connor 46ad8e74e6 Add publish 2022-01-31 11:01:51 -05:00
Isaac Connor 61028a3ae1 Remove travis badge, use Isaac's full name. Fixes #3417 2022-01-31 10:09:31 -05:00
Isaac Connor 51f6a53b6c Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-01-28 15:38:32 -05:00
Isaac Connor e5792c21c9 Push locked packets into event packetqueue instead of unlcoked contents. Prevents freeing of data before writing to event, hence crashing. 2022-01-28 15:38:18 -05:00
Isaac Connor a91e7d96f8 Merge fix for VP8 2022-01-28 12:42:41 -05:00
Isaac Connor d567d8aafc Merge upstream patches to RTSPServer 2022-01-27 17:06:18 -05:00
Isaac Connor c524298f8e Rough in State module 2022-01-27 13:42:46 -05:00
Isaac Connor 86f393565e Remove Function references and swap with appropriate Capturing, Analysing, Recording 2022-01-27 13:42:31 -05:00
Isaac Connor 8e62562afd Move onclick to the surrounding div instead of the img. Fixes clicking on montage 2022-01-26 21:39:29 -05:00
Isaac Connor fe8747e5e7 Make ONVIF inputs 100% 2022-01-26 11:45:07 -05:00
Isaac Connor 42e24614d6 Include filename in debugs when writing out jpegs 2022-01-26 11:45:07 -05:00
Isaac Connor 138bada095 Add libdatetime-perl. Some Control modules need it 2022-01-26 11:45:07 -05:00
Isaac Connor 23bfbcd6ce Merge branch 'master' into multistream 2022-01-26 10:13:20 -05:00
Jonathan Bennett a2a2f1a781 Move variables out of the ifdef gsoap block, as they are used for Amcrest support, too 2022-01-25 22:46:09 -06:00
Jonathan Bennett 57a697093e Remove redundant JS define 2022-01-25 22:38:06 -06:00
Jonathan Bennett ec9403fb6f Adds Amcrest On-camera Motion Detection 2022-01-25 22:38:00 -06:00
Isaac Connor 961256d2e7 terminate when zm_terminate is set. Do a countdown instead of countup. Sleeo for 10000 microseconds instead of 100. This restores the old value 2022-01-25 16:24:21 -05:00
Isaac Connor 17e01cb58f Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-01-25 16:23:02 -05:00
Isaac Connor 4d90a816f8 Put a lock around jpeg writing. libjpeg is not thread safe 2022-01-25 16:22:33 -05:00
Isaac Connor 38da3b4d52 add some brackets to make logic more clear 2022-01-25 14:28:26 -05:00
Isaac Connor c8c09e560f Fix mTerminate not being initialised. 2022-01-25 14:27:39 -05:00
Isaac Connor cf82d767de Remove the decoding code, just populate the av_packet. This fixes rtsp decoding because we weren't copying the decoded frame to shm raw image. 2022-01-25 14:27:32 -05:00
Isaac Connor 26ae5052f4 Fix fail to get Sources in RTSP. the string msg although initially reserved to ZM_NETWORK_BUFSIZ, after use it's capacity is changed whatever it's contents are. So need to re-reserve. 2022-01-25 11:55:21 -05:00
Isaac Connor 3cc243b9a8 Don't freshing config when doing update. That is it's own command 2022-01-24 09:24:16 -05:00
Isaac Connor 146ea4822d Bump the db queue limit to 30 before we warn. I only have 1 server that gets over 20 and it is still ok. 2022-01-24 09:24:16 -05:00
Isaac Connor f10d0fd3f5
Merge pull request #3413 from jp-bennett/master
Adds janus updates
2022-01-23 12:35:42 -05:00
Jonathan Bennett 5485c04bc6 Rework of the Janus polling loop 2022-01-23 01:07:48 -06:00
Jonathan Bennett d110987935 Fix indentation for ESLint 2022-01-22 13:37:44 -06:00
Jonathan Bennett abbd27d1cb Remove hard-coded config Vars 2022-01-22 13:31:47 -06:00
Jonathan Bennett 07c5b23aa6 Adds Janus streaming checks to polling thread 2022-01-22 12:49:08 -06:00
Isaac Connor 9443aaa2d8 Do state changes when in RECORD mode as well as it doesn't do motion detection Fixes #3411 2022-01-22 13:33:39 -05:00
Jonathan Bennett 8125aa633b
Merge branch 'ZoneMinder:master' into master 2022-01-22 12:20:13 -06:00
Isaac Connor 90f75dae93 Make config entries const 2022-01-22 12:33:48 -05:00
Isaac Connor 47aa1d1913 Bump version to 1.37.10 2022-01-22 12:31:56 -05:00
Isaac Connor 3a0b88c013 Don't make private config entries available to js land. 2022-01-22 12:31:36 -05:00
Isaac Connor ce2d605b3d load Private as well as Name,Value from Config 2022-01-22 12:31:15 -05:00
Isaac Connor 35efb111ac Add Private to Config 2022-01-22 12:30:59 -05:00
Isaac Connor 45db266ede Put full config available to javascript 2022-01-22 12:07:18 -05:00
Isaac Connor 4910ec752f Merge branch 'master' into multistream 2022-01-22 11:52:19 -05:00
Jonathan Bennett 2e9bda1af1 Add firefox specific workaround for Janus streaming 2022-01-21 23:21:41 -06:00
Jonathan Bennett 52e48c02b6 Add janus_path and janus_secret, allowing for more secure and flexible Janus installs 2022-01-21 22:23:41 -06:00
Isaac Connor 4eb4e0eb18 ignore ajaxQueue.js 2022-01-20 12:02:17 -05:00
Isaac Connor 5ce701f5cb Use Monitor->getStatusHTML to generate status html 2022-01-20 11:53:44 -05:00
Isaac Connor 91d6ff2029 Use Monitor->getStatusHTML to generate status html 2022-01-20 11:53:35 -05:00
Isaac Connor 57bb91e105 add connKey to monitorData 2022-01-20 11:53:05 -05:00
Isaac Connor 9c3509a620 put an mid in imageFeed id so we can use MOnitorStream.js. Use Monitor->getStatusHTML to generate status html 2022-01-20 11:52:54 -05:00
Isaac Connor e73659843a Rework to use MonitorStream.js 2022-01-20 11:52:01 -05:00
Isaac Connor 7748616992 If rate > 1600, limit it to 1600 to prevent logged errors 2022-01-20 11:51:08 -05:00
Isaac Connor 24a9dcbf47 If rate > 1600, limit it to 1600 to prevent logged errors 2022-01-20 11:50:53 -05:00
Isaac Connor 97f2c0a02b Load ajaxQueue 2022-01-20 11:50:25 -05:00
Isaac Connor 2da9c20c08 Add ajaxQueue 2022-01-20 11:49:59 -05:00
Isaac Connor 22b6337752 Merge code from watch.js. Add an ajaxQueue. Link up buttons from UI 2022-01-20 11:47:28 -05:00
Isaac Connor 4bf55b1af1 Use net zm_setcookie 2022-01-20 09:48:09 -05:00
Isaac Connor 3cd6fbdc12 Use net zm_setcookie 2022-01-20 09:48:02 -05:00
Isaac Connor 9395b7e47c Use net zm_setcookie 2022-01-20 09:47:53 -05:00
Isaac Connor a57206ef54 Implement getMonitorStateHTML to synchronize it between montage and live view, cycle etc. Reuseable code. Also the structure is required by MonitorStream.js 2022-01-20 09:47:36 -05:00
Isaac Connor db866fa668 Implement zm_setcookie to simplify setting cookies, set samesite, deal with older php etc. Use it. 2022-01-20 09:46:38 -05:00
Isaac Connor dec440ead1 Unset holdbuffer so that when we connect, we reset the shm buffer pointer. cleanup initializers in Image 2022-01-19 15:01:37 -05:00
Isaac Connor 05043a37b1 include image index in debug 2022-01-19 12:27:16 -05:00
Isaac Connor 062cde54a0 Bump version for janus audio 2022-01-19 10:45:38 -05:00
Isaac Connor ebcb3abf2e image_count is only relevant to capture. decode and analysis should use packet->image_index for indexing into image_buffer, etc. 2022-01-19 09:33:33 -05:00
Isaac Connor e6edf5b7db
Merge pull request #3410 from jp-bennett/master
Adds janus_enable_audio, a switch to try to enable audio in live stre…
2022-01-19 09:32:22 -05:00
Jonathan Bennett 04cfe372f8 Wrap public access function in Gsoap ifdef to remove build warning 2022-01-19 00:56:36 -06:00
Jonathan Bennett fb832e7d1b Adds janus_enable_audio, a switch to try to enable audio in live stream viewing. 2022-01-19 00:14:52 -06:00
Isaac Connor d00aaa11e9 default JanusEnabled to 0 so that we can turn it off 2022-01-18 23:02:26 -05:00
Isaac Connor 388735e942 Fix relating auth_hash causing repeated reloads. If https, then assume a reverse proxy setup to janus. If video feed is not an img, log it and return 2022-01-18 23:02:26 -05:00
Isaac Connor 13ee39b1e9 Log errors talking to Janus. Log if janus is turned on but not compiled in 2022-01-18 23:02:26 -05:00
Isaac Connor d2d9721c4e spacing, remove redundant debug 2022-01-18 23:02:26 -05:00
Isaac Connor 3241fa59c5 Don't redirect if there was an error so that we display it 2022-01-18 23:02:26 -05:00
Isaac Connor ec1f0d87af fix HEAD left behind 2022-01-18 20:20:38 -05:00
Isaac Connor 3835087c9d Merge branch 'master' into multistream 2022-01-18 20:16:08 -05:00
Isaac Connor 0c055edb5e I think in all my changes I got rid of the code that opens events on Alarm. 2022-01-18 12:20:19 -05:00
Isaac Connor 90492d332c Put back to brand 3.0 of upstream 2022-01-18 10:39:24 -05:00
Isaac Connor 24c2efeb00 fix eslint 2022-01-17 16:19:27 -05:00
Isaac Connor eab29babea
Merge pull request #3409 from jp-bennett/master
Refactor Montage view js -- Janus in MonitorStream
2022-01-17 15:14:43 -05:00
Isaac Connor 32a5dcbda9 ignore janus for eslint 2022-01-17 14:52:43 -05:00
Isaac Connor 4374a6e70e Bump versions of eslint to latest 2022-01-17 14:35:59 -05:00
Isaac Connor 08b3277aa8 bump version for janus 2022-01-17 14:09:27 -05:00
Jonathan Bennett 5026008482 Changes due to janus packaging 2022-01-16 19:55:53 -06:00
Jonathan Bennett 688f505f28 Adds better error handling, changes expected location of janus.js 2022-01-16 19:44:52 -06:00
Jonathan Bennett f27f7e9d27
Merge branch 'ZoneMinder:master' into master 2022-01-16 12:25:58 -06:00
Isaac Connor 5f17cb6e9a Debug the size returned as compared to the file size 2022-01-15 17:19:35 -05:00
Isaac Connor 1891002c65 Remove Freenode from the badges. 2022-01-15 17:19:35 -05:00
Isaac Connor 4cd085e085 Bump eslint to ECMA2017 2022-01-15 17:19:35 -05:00
Jonathan Bennett 59056b4103 Refactor Montage view js -- Janus in MonitorStream 2022-01-15 01:33:17 -06:00
Isaac Connor 8d757d37a6 fix eslint 2022-01-14 16:43:59 -05:00
Isaac Connor 1ae61afd47
Merge pull request #3408 from jp-bennett/janus
Adds Janus h264 streaming
2022-01-14 16:34:19 -05:00
Isaac Connor aba387f202 Fix !== which should be >= 2022-01-14 16:31:52 -05:00
Isaac Connor 3296e14264 Move RECORD/MOCORD length close code after the state machine. If the state machine has taken action, this code likely won't trigger, but the way it was before it could ignore current state. Plus I think it logically keeps relevant logic closer together. Must use packetqueue.unlock after decoding as analysis might be waiting in the packetqueue. Doing this will do both notifies. Disable de-interlacing for decoding style monitors. 2022-01-14 15:19:28 -05:00
Jonathan Bennett 9e9bdd183c
Merge branch 'ZoneMinder:master' into janus 2022-01-14 14:05:23 -06:00
Isaac Connor da538f7d1d Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-01-14 14:46:00 -05:00
Isaac Connor a4b0aa442a Introduce event->Duration() 2022-01-14 14:35:26 -05:00
Isaac Connor 1fe4bbedc0 use min_section_length instead of 0 when testing minimumm section length. Use event->Duration instead of snap-event->StartTime because this snap will not be included in the event. This results in events of 29.59 seconds instead of 30 seconds. 2022-01-14 14:35:16 -05:00
Isaac Connor eb59b4de7f Clear out dead code 2022-01-14 14:20:17 -05:00
Isaac Connor 8b99b15b41 Use a scope to shorten the lock on event_lock 2022-01-14 14:17:07 -05:00
Isaac Connor 9240a93ef5 Revert my idea of having ONVIF and TRIGGER code start/end events. Move code to tst for Ready() up above ONVIF and TRIGGER code. When waiting for decode, junk the idea of locking in the packetqueue. Since waiting releases the lock, we should be ok waiting and notifying in the packet. (I know there was a time when I felt this was necessary and I think it had to do with the deinterlacing case, but I've simplified that code too). 2022-01-14 14:09:18 -05:00
Isaac Connor 7c1ba721aa Preface Debug with ZM 2022-01-13 22:15:02 -05:00
Isaac Connor 0e91825d5a Fix merge 2022-01-13 22:14:54 -05:00
Isaac Connor 27abe85036 replace active with analysing, capturing, recording 2022-01-13 22:14:44 -05:00
Isaac Connor a414506a5e Preface Debug with ZM 2022-01-13 22:14:14 -05:00
Jonathan Bennett 212d51f933
Merge branch 'ZoneMinder:master' into janus 2022-01-13 12:16:16 -06:00
Isaac Connor 3504b13e2a Merge branch 'master' into multistream 2022-01-13 12:29:34 -05:00
Isaac Connor 9b8ca69203 default interactive to whether we have stdio. So now when running from console it will default to interactive and when running from zmdc.pl will be non-interactive. Do check regardless of ZM_UPDATE_CHECK setting. 2022-01-13 12:26:47 -05:00
Isaac Connor 274ffd7da0 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-01-13 12:02:14 -05:00
Isaac Connor 44b11389ce Merge pseudo:sandbox/ZoneMinder.connortechnology into event_thread 2022-01-13 12:00:17 -05:00
Isaac Connor 13e2f5e03b remove Enabled from sql 2022-01-13 11:05:14 -05:00
Isaac Connor 3cc1b74b4e Merge branch 'master' into multistream 2022-01-13 10:21:58 -05:00
Isaac Connor 162e12bf92 default interactive to whether we have stdio. So now when running from console it will default to interactive and when running from zmdc.pl will be non-interactive. Do check regardless of ZM_UPDATE_CHECK setting. 2022-01-13 10:21:32 -05:00
Isaac Connor 58bd09d83d Fix debug output from zmDbDo 2022-01-13 09:56:04 -05:00
Isaac Connor 3ec6c7e32f Fix behaviour of update check to support interactive mode. Use zmDbDo functions to simplify code. When interactive print out lastVersion, latestVersion and currentVersion 2022-01-13 09:55:26 -05:00
Isaac Connor 3dad3a5200 update description to reflect that zmupdate.pl now does all the things it will someday do. Meantion how -c works better. When in interactive mode, check once and print out the result instead of daemonising. Fix formatting osf usage 2022-01-13 09:55:16 -05:00
Isaac Connor e4f0c7cd98 Fix debug output from zmDbDo 2022-01-13 09:54:47 -05:00
Isaac Connor b178b0af5e Fix behaviour of update check to support interactive mode. Use zmDbDo functions to simplify code. When interactive print out lastVersion, latestVersion and currentVersion 2022-01-13 09:54:36 -05:00
Isaac Connor cb1cbed8e7 update description to reflect that zmupdate.pl now does all the things it will someday do. Meantion how -c works better. When in interactive mode, check once and print out the result instead of daemonising. Fix formatting osf usage 2022-01-13 09:37:54 -05:00
Jonathan Bennett 2beffeb1b4 Add Janus to Cycle view. Remove debug Alert() messages 2022-01-12 22:47:35 -06:00
Isaac Connor f764cfbc32 Fix deadlock on deleting event. Cannot race for the lock, joining will do the job 2022-01-12 23:11:19 -05:00
Isaac Connor 3d04228485 rework ::Analyse. The state engine will only go into alarm on actual motion, not on a skipped frame. TRIGGERS and ONVIF events will immediately create events. 2022-01-12 23:10:17 -05:00
Isaac Connor e4693c251c add backticks around field names because some like Function are reserved 2022-01-12 23:08:29 -05:00
Isaac Connor 8d06175024 Rework to use ZoneMinder::Monitor class. Simplify loadMonitors and get rid of loadMonitor. Add in ServerId change handling. 2022-01-12 23:07:48 -05:00
Isaac Connor a9f7b257ea Rough in a queue and a thread into the event to process packets. We do this so that the event creator can get back to analysis as fast as possible so as to avoid the packetqueue filling up. 2022-01-12 17:16:49 -05:00
Jonathan Bennett aeefc512ab
Merge branch 'master' into janus 2022-01-12 13:04:13 -06:00
Isaac Connor c9db5f44a4 cherry pick Add check to prevent tight busy loop if ONVIF setup fails 2022-01-12 12:05:33 -05:00
Isaac Connor 134d80a91d Replace Requires with BindsTo and add comment explaining how to override 2022-01-12 11:32:08 -05:00
Jonathan Bennett 84a73bb007 Add check to prevent tight busy loop if ONVIF setup fails 2022-01-12 09:37:48 -06:00
Jonathan Bennett 7a5a05fe94 Clean up warnings 2022-01-12 01:29:32 -06:00
Jonathan Bennett cb46b94ea1 Add error handling to libcurl calls to Janus 2022-01-12 00:19:54 -06:00
Jonathan Bennett 50c824f3bb Janus cleanup, adds support to the "watch" view 2022-01-11 21:21:58 -06:00
Isaac Connor c27b0aff97 Move analysis image assignment up to where motion detection is done do remove duplication and simplify logic. Free analysis images as well as captured images after analysis. remove extra copy of image to analysis_image. Replae a packetqueue.unlock with just deleting the locked packet. No one waits for analysis. Re-introduce sleeping in the analysis thread on error to prevent spinning 2022-01-11 22:11:28 -05:00
Isaac Connor ff91ac62fb add comment documenting why we sleep 2022-01-11 17:02:05 -05:00
Isaac Connor cd6c44db47 Revert "Remove sleeping from Analysis thread. It is uneccessary and results in us starting off way behind the capture thread. It also limits us to 30fps."
This reverts commit 6c4156a483.
2022-01-11 17:01:04 -05:00
Isaac Connor 04bdf0ac6b change Enable/Disable to act on capture. suspend/resume is for motion 2022-01-11 13:44:11 -05:00
Isaac Connor b42190ee3c Remove referencest to enabled. replace shared_data->active with shared_data->capturing shared_data->analysing and shared_data->recording. actionEnable/Disable act on capture. actionSuspend/Resume act on analysing. 2022-01-11 13:42:54 -05:00
Isaac Connor 9243b1d081 Add debugging to zmDbDo 2022-01-11 12:43:42 -05:00
Isaac Connor 152efd0987 make aud_print add a newline if printing. Tidy up Event Summary updating, using zmDbDo. 2022-01-11 12:39:52 -05:00
Isaac Connor 1891537e91 Remove redundant logLevel from docs 2022-01-11 12:38:57 -05:00
Isaac Connor 3dcfd3e26e reduce debug logging 2022-01-11 12:02:33 -05:00
Isaac Connor 71c7b324e9 Update new Capturing, Analysing, Recording based on Function. 2022-01-11 12:01:07 -05:00
Jonathan Bennett 2729e1de22
Merge branch 'ZoneMinder:master' into janus 2022-01-11 10:37:29 -06:00
Isaac Connor 1f9d3c46aa Merge branch 'master' into multistream 2022-01-11 10:48:27 -05:00
Isaac Connor 2a83e26fb2 Move Recording to General tab. Improve help links 2022-01-11 10:46:08 -05:00
Isaac Connor 4c16557192 When error with ajax, delay fetchImage and add logging 2022-01-11 10:45:40 -05:00
Isaac Connor 6219989884 replace function with appropriate Analysing/Capturing settings. Remove function popup. 2022-01-11 10:45:11 -05:00
Isaac Connor c97db738a3 fix OPTIONS_CAPTURING 2022-01-11 10:44:42 -05:00
Isaac Connor 52aed5b0bf Use analysinng instead of function 2022-01-11 10:44:23 -05:00
Isaac Connor aaaf87abdb Don't try again if the error was ENOSPACE. it crashes and there is just no point. 2022-01-11 09:08:01 -05:00
Isaac Connor 90cbf5a018 Fix == instead of = 2022-01-11 09:06:43 -05:00
Isaac Connor 0728c04bf4 rough in options help for capturing 2022-01-11 06:58:10 -05:00
Jonathan Bennett 3a9c16aeea First working Janus build 2022-01-10 23:22:37 -06:00
Isaac Connor b88e699d7e Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-01-10 19:56:04 -05:00
Isaac Connor 81fc392bc2 If error is ENOSPACE just give up. ffmpeg crashes if we try again. 2022-01-10 19:56:00 -05:00
Isaac Connor f110afa6ec Remove Function language entries 2022-01-10 18:52:13 -05:00
Isaac Connor cb30f7639f revert broken commit. Isaac doesn't know what he's doing. 2022-01-10 18:47:26 -05:00
Isaac Connor a0c34f0d96 Fix. cppcheck was wrong about divider being able to go into deeper scope. 2022-01-10 18:33:01 -05:00
Isaac Connor fd3a70172d Merge branch 'master' into multistream 2022-01-10 17:51:50 -05:00
Isaac Connor 3f7b9dfff7 fix cppcheck error about lo_x. Inner scope overwriting it. 2022-01-10 17:36:50 -05:00
Isaac Connor 376d7fd7e5 log error if avcodec_parameters_to_context fails. Mostly to quiet cppcheck. Remove duplicated assignment to sample_fmt. 2022-01-10 17:36:50 -05:00
Isaac Connor 78a10b6095 cppcheck fixes 2022-01-10 17:36:49 -05:00
Isaac Connor 9f86fd3b16 add default_width and height to constructor 2022-01-10 17:36:49 -05:00
Isaac Connor 4697e36f11 add explicit 2022-01-10 17:36:49 -05:00
Isaac Connor 037771539d spacing, return a success value from setupCodec instead of using Fatal 2022-01-10 17:36:49 -05:00
Isaac Connor b406bf8fd1 remove last_send_image_width/height. Not really useful or relevant 2022-01-10 17:36:49 -05:00
Isaac Connor ed7bc7c4b4 whitespace 2022-01-10 15:25:15 -05:00
Isaac Connor ec95c8da57 Rename the monitor type define from CURL to LIBCURL to fix namespace conflict 2022-01-10 15:25:15 -05:00
Isaac Connor 3f7e4c67a0 Provide better logging when there is no data passwed to setAlarmCues 2022-01-10 15:25:15 -05:00
Isaac Connor 947132284d When transitioning from ALERT to IDLE, close the event if CLOSE_MODE is IDLE as well as ALARM. 2022-01-10 14:44:52 -05:00
Isaac Connor 701045393c fix typo 2022-01-10 09:07:59 -05:00
Isaac Connor e9db12ca94 Fix importance got cutnpasted to where it shouldn't be 2022-01-09 14:46:48 -05:00
Isaac Connor 21762585d9 rework getting second packet for de-interlace. Pass notesetmap by reference 2022-01-09 14:43:23 -05:00
Isaac Connor 1f6874dd53 add explicit 2022-01-09 14:43:23 -05:00
Isaac Connor f0c6413dc8 solve ccpcheck complaints 2022-01-09 14:43:23 -05:00
Isaac Connor c832fabafd solve ccpcheck complaints 2022-01-09 14:43:23 -05:00
Isaac Connor af8964c043
Merge pull request #3406 from jp-bennett/master
Continued work on ONVIF
2022-01-08 15:19:51 -05:00
Jonathan Bennett 52b377ca86 Adds the 'closes_event" ONVIF option, to handle motionDetection message quirks. 2022-01-08 14:05:57 -06:00
Jonathan Bennett a3c298ca93 Add nullptr checks to prevent a crash when in NODECT mode 2022-01-08 13:17:04 -06:00
Isaac Connor a153798b47 fix init when no GSOAP 2022-01-08 12:37:23 -05:00
Isaac Connor f01ecf2a16 Add libgsoap to dependencies 2022-01-08 12:37:05 -05:00
Isaac Connor dc975daa7a init soap to null in constructor. Stop analysis thread before destroying soap. 2022-01-08 12:21:29 -05:00
Isaac Connor c8bc0661b1 Have to clear src before resetting or some browsers won't load the new image 2022-01-08 12:14:28 -05:00
Isaac Connor 36a493ad5e bump to 1.37.7 2022-01-07 16:35:52 -05:00
Isaac Connor a2a04edcf7 Only init gsoap if we are capturing 2022-01-07 16:31:45 -05:00
Isaac Connor 71ff1e3cea Add translates for analyse button. Fixup styles 2022-01-07 16:30:14 -05:00
Isaac Connor a679455a0b Merge branch 'master' into merge_work_on_zms 2022-01-07 16:22:51 -05:00
Isaac Connor deaff43f66 use let/const 2022-01-07 16:22:24 -05:00
Isaac Connor 8f372e6a6c Add useful title to frame image telling us which we are looking at 2022-01-07 16:22:11 -05:00
Isaac Connor cfac99be4e better debugging when the row has no Id 2022-01-07 16:21:49 -05:00
Isaac Connor 79c45f50d5 define raw as an empty array so we don't generate js errors 2022-01-07 16:21:34 -05:00
Isaac Connor 038bff0df2 Add analyse button 2022-01-07 16:06:53 -05:00
Isaac Connor 1a3bee102f analyze->analyse, fixup how we show enabled/disabled and start with analysis frame displayed 2022-01-07 16:06:38 -05:00
Isaac Connor 939f165b22 rename analyze to analyse 2022-01-07 16:05:52 -05:00
Isaac Connor 76fe20c69f Only send analysis_frame if doing motion detection. Add debuging. Remove other debugging 2022-01-07 15:57:28 -05:00
Isaac Connor f4c813a26f Assign image to analysis_image before doing motion detection so there is always an image to see. Fix crash. 2022-01-07 15:57:01 -05:00
Isaac Connor 7219809364 Add CMD_ANALYZE_ON/OFF 2022-01-07 14:00:36 -05:00
Isaac Connor c914f00126 browser doesn't seem to like step=0.01
add analyze_frames button handling and update to jquery instead of mootools styles
2022-01-07 13:59:45 -05:00
Isaac Connor 6f5eee6c0f Add show_analyze_frames function to tell zms to send analysis frames 2022-01-07 13:53:49 -05:00
Isaac Connor df0a0c7853 Add CMD_ANALYZE_ON and OFF 2022-01-07 13:50:40 -05:00
Isaac Connor 24bb43bbeb finish merge. Assign the alarm image to the shmem 2022-01-07 13:16:51 -05:00
Isaac Connor 58858d2d25 Include alarm_image in shared_mem 2022-01-07 13:12:44 -05:00
Isaac Connor 7ae9bebea4 Add analysis boolean query param 2022-01-07 12:40:21 -05:00
Isaac Connor 8863fc0e0f Add FrameType to StreamBase so we can sends analysis frames 2022-01-07 12:32:31 -05:00
Isaac Connor 16964cf327 fix zms running past end of event 2022-01-07 12:30:56 -05:00
Isaac Connor 657fc5cad5 convert function to relevant capturing/analysing 2022-01-07 11:52:19 -05:00
Isaac Connor 2ba0757fca Remove references to function, add Capturing_Strings, Analysing_Strings, Recording_Strings. 2022-01-07 11:51:43 -05:00
Isaac Connor 5840602b6e
Merge pull request #3404 from jp-bennett/master
Adds ONVIF motion Detection
2022-01-07 10:35:32 -05:00
Isaac Connor 6d3c6330df Fix freebsd build by fixing incorrect use of SystemTimePoint when we want TimePoint 2022-01-07 10:34:44 -05:00
Jonathan Bennett 1333d8c751 Adds ONVIF Motion Detection Support 2022-01-06 16:45:15 -06:00
Isaac Connor c5ae080746 further replace function with recording/analysing. One result of this is we can be in ALERT/ALARM status without recording. 2022-01-05 21:26:46 -05:00
Isaac Connor dadf53f99d Merge branch 'master' into multistream 2022-01-05 20:20:45 -05:00
Isaac Connor 738c252948 load onvif settings and provide accessors 2022-01-05 20:15:39 -05:00
Isaac Connor f7c90f5c41 Replace some function with recording == and analysis== 2022-01-05 19:53:30 -05:00
Isaac Connor 99900e8c1d Merge branch 'master' into multistream 2022-01-05 18:04:10 -05:00
Isaac Connor aefed4e174 Merge branch 'master' into multistream 2022-01-05 18:03:44 -05:00
Isaac Connor bc67493f91 Alter log level of restart events based on Importance setting 2022-01-05 16:49:20 -05:00
Isaac Connor bfac696fb7 return logger from loginit so that we can use it 2022-01-05 16:49:00 -05:00
Isaac Connor cce24ea427 Add RTSPServer and Importance fields 2022-01-05 16:48:46 -05:00
Isaac Connor 198ee73d0e Add alarm_cause to zm_packet. Clean up code dealing with decoding not being ready 2022-01-04 17:38:25 -05:00
Isaac Connor a59e33d8b0 remove unused last_section_mod 2022-01-03 19:14:27 -05:00
Isaac Connor b1353823cf clean up signal change code a bit, using new event notesetmap update function. So now when we lose signal, the event will close but it will have signal change :Lost added to it's notes. A new event will only be created if in RECORD/MOCORD. 2022-01-03 19:04:21 -05:00
Isaac Connor 7215756fed Introduce a method update the noteSetMap after event creation (addNote). 2022-01-03 19:03:04 -05:00
Isaac Connor 205ff6c033 apply fix to RtspServer 2022-01-02 19:25:52 -05:00
Isaac Connor e2a81cc2c5 make max_score an int to get rid of the casts. Move assignment of it above the event UPDATE sql so that it is immediately accurate. 2022-01-02 19:25:52 -05:00
Isaac Connor a76128e9c4 include monitor->Importance when logging failed camera connects 2022-01-01 18:56:13 -05:00
Isaac Connor e73765c5bf add basic readthedocs config 2022-01-01 17:55:28 -05:00
Isaac Connor 698fe14453 set zm_terminate instead of exit() so that all the cleanup code happens 2022-01-01 17:55:18 -05:00
Isaac Connor a250567e74 add sleeping when no viewers and in ondemand mode 2022-01-01 17:54:47 -05:00
Isaac Connor 8c8a9ca32a Rework the logic around waiting for capture to be in both single jpeg mode and streaming. 2022-01-01 17:54:20 -05:00
Isaac Connor fd489c2c8d Fix. Need to use system_clock 2022-01-01 17:53:45 -05:00
Isaac Connor a66adb6dcd fix SteadyClock vs Systemclock issues 2021-12-31 18:36:23 -05:00
Isaac Connor 6bd04de5f6 Merge branch 'master' into multistream 2021-12-31 17:53:36 -05:00
Isaac Connor 5933aa8a6f Use > 0.0 instead of boolean when testing maxfps 2021-12-28 15:34:31 -05:00
Isaac Connor e7a33a3dbe Add Importance to monitors view 2021-12-28 13:51:47 -05:00
Isaac Connor 46b95e28ec Fix commas 2021-12-28 13:51:36 -05:00
Isaac Connor 87962a3723 Invert Importance so that Normal is the auto-selected first value 2021-12-28 13:48:37 -05:00
Isaac Connor e81384bba4 Fix fail to build 2021-12-28 12:45:02 -05:00
Isaac Connor 0e148d809a cleanup logic and fix the zone names coming before the Motion: label 2021-12-28 12:33:23 -05:00
Isaac Connor f9f8764507 Change Event->Cause to a TEXT instead of varchar(32) because we now inclue Alarmed Zone name and could include other info as well.
Fixes #3403
2021-12-28 12:33:03 -05:00
Isaac Connor 82a5f3a059 set zm_terminate instead of exit() so that all the cleanup code happens 2021-12-26 15:19:13 -05:00
Isaac Connor bdcb7950cd Fix export from event view due to conflict with function name in skin.js 2021-12-26 11:51:32 -05:00
Isaac Connor 2aacbf790a handle warning due to not defined last_run 2021-12-26 11:51:32 -05:00
Isaac Connor 185dc4a50d Do a git pull instead of fetch so as to actually get the changes 2021-12-22 11:28:00 -05:00
Isaac Connor 96a450db3d Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-22 11:27:39 -05:00
Isaac Connor 80166a1ab5 Fix preset labels not being populated and causing javascript errors when they are. 2021-12-22 11:25:46 -05:00
Isaac Connor 81048b6191 Reduce code 2021-12-17 13:29:30 -05:00
Isaac Connor 77793da70e If no max_fps set we don't care how long it takes to send frame 2021-12-17 13:29:30 -05:00
Isaac Connor edbe726e86 Implement semaphore retry. Make not getting the semaphore an error 2021-12-17 09:41:45 -05:00
Isaac Connor d128e3befc Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-16 17:02:33 -05:00
Isaac Connor 1bc0e1820e fix build on older c++ 2021-12-16 17:02:20 -05:00
Isaac Connor ee129ba2e3 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-16 16:38:39 -05:00
Isaac Connor c081637036 Fixes to specifying width and height of image due to us jquery. Implement changeRate/MaxFPS. Cleanup use of auth_hash in JSON. 2021-12-16 16:38:15 -05:00
Isaac Connor 4dd454325c use options[maxfps] instead of always specifying 30fps. 2021-12-16 16:36:38 -05:00
Isaac Connor 30e4d72c1d Implement CMD_MAXFPS 2021-12-16 16:36:12 -05:00
Isaac Connor 7101a70774 Switch to steady_clock 2021-12-16 16:35:42 -05:00
Isaac Connor 60d2186ff4 Move from SystemTimePoint to SteadyTimePoint where possible. Implement MAXFPS command. Change the logic of calculating sleep time to make more sense. Get rid of frame_mod use in favour of calculating when then next frame should get sent and just waiting till then. 2021-12-16 16:35:20 -05:00
Isaac Connor 7b7ac8fc7e Add utility functions TimePointToString and SystemTimePointToString 2021-12-16 16:30:26 -05:00
Isaac Connor 3f3f607a6a Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-16 09:35:31 -05:00
Isaac Connor 7c3ab46408 fix missing quote 2021-12-16 09:35:21 -05:00
Isaac Connor 4bd98d756c Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-15 16:58:12 -05:00
Isaac Connor d10d5201ac log max fps 2021-12-15 16:57:27 -05:00
Isaac Connor 4edd5c1bf5 Don't alter maxfps. Just report that we are too slow. Don't use ZM_RATE_BASE in sleep time calculations it amplifies the sleep seconds by 100 times. Removing allows us to view a full framerate. 2021-12-15 16:57:17 -05:00
Isaac Connor 8215b04fb0 remove padding from container in watch view so that image can go right to edge. Add 1px padding to sidebar for better visual separation. 2021-12-15 14:49:40 -05:00
Isaac Connor d41d2ff03d Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-15 12:43:03 -05:00
Isaac Connor f1db88510e remove debug, fix eslint 2021-12-15 09:23:21 -05:00
Isaac Connor 854d11ce9d List the connkey that isn't open, differentiate logs a bit to help debug. 2021-12-15 09:11:55 -05:00
Isaac Connor d86456b6f2 revamp, using ZoneMinder::Monitor methods to reduce code. Reduce last analysze time was zero to a debug. Fixes #3389 2021-12-15 09:11:55 -05:00
Isaac Connor 12ebdacf54 specify ZoneMinder::Database for zmSQLExecute 2021-12-15 09:11:55 -05:00
Isaac Connor fe0e4627ef Specify ZoneMinder::General for runCommand 2021-12-15 09:11:55 -05:00
Isaac Connor 28d5614da0 Fix missing ; 2021-12-15 09:11:55 -05:00
Isaac Connor f683557b0e Fix Monitor::Control to handle local cameras 2021-12-15 09:11:55 -05:00
Isaac Connor e8edeab641 parseInt prevEventId and nextEventID to be sure that our tests for != 0 work. Also don't go to previous event if prevEventId ==0.Maybe Fixes #3390 2021-12-15 09:11:55 -05:00
Isaac Connor 61fe35a32a Don't log errors when querying a monitor in NONE Function. Just report a 0 status.Fixes #3397 2021-12-15 09:11:55 -05:00
Isaac Connor f6d0274f74 Fix PrevCycle because monIdx was empty. 2021-12-14 17:05:56 -05:00
Isaac Connor 4fa804e9a2 Can only SKIP LOCKED if locking rows. Remove FOR SHARE as it isn't supported on < mysql 8 2021-12-14 13:33:00 -05:00
Isaac Connor cca7953856 include user and function error message about insufficient permissions. Will make it easier to figure out who tried what. 2021-12-14 12:26:26 -05:00
Isaac Connor fe72fd83f8 Fix auth not getting realm from auth headers due to them being an array now. Get auth and ip from Path if not set in ControlAddress. 2021-12-14 10:04:35 -05:00
Isaac Connor 4c351a6c54 When orig.tar.bz2 doesn't exist, just create it without asking 2021-12-14 09:39:29 -05:00
Isaac Connor cfcc39defb Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-14 09:29:03 -05:00
Isaac Connor 2f287a5050
Merge pull request #3400 from makers-mark/master
Fix boilerplate (un)typo
2021-12-13 22:29:52 -05:00
makers-mark 9733cdb576
Update zm_update-1.35.25.sql 2021-12-13 21:07:35 -05:00
Isaac Connor 3fad178528 Bump version for ExecuteInterval in filters 2021-12-13 15:02:54 -05:00
Isaac Connor ea671a57f8 Add skip_locked and ExecuteInterval 2021-12-13 15:01:23 -05:00
Isaac Connor 6b18b2889d Add skip_locked and ExecuteInterval 2021-12-13 15:01:17 -05:00
Isaac Connor 69faa42ca7 Add more of the resulting SQL to the filter debug modal 2021-12-13 15:00:55 -05:00
Isaac Connor 6511dc8a4f Allow empty sort field. 2021-12-13 15:00:35 -05:00
Isaac Connor e2df6e5074 Add ExecuteInterval to Filters 2021-12-13 15:00:03 -05:00
Isaac Connor a65f2b42ce Implement per-filter delays using the ExecuteInterval member of Filters. Remove uneded lockandload when doing row locks. We will have already locked when executing the filter sql. 2021-12-13 14:59:38 -05:00
Isaac Connor 0382a677df Add ExecuteInterval to Filter Object. Allow empty sort_field to have the effort of not sorting. Always add FOR SHARE which adds a read-only lock the returned records. Add SKIP LOCKED functionality so that filters can simply skip locked records. This should reduce contention. Also specify FOR UPDATE of the events table, otherwise we also lock Monitors and Storage. 2021-12-13 14:58:32 -05:00
Isaac Connor ef13c84d8b fix zmtrigger. Need {} 2021-12-12 17:01:12 -05:00
Isaac Connor b4511a8fc3 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-10 16:20:54 -05:00
Isaac Connor c42b75a252 must clear the monitors array before terminating log. 2021-12-10 16:20:44 -05:00
Isaac Connor 4cbc55d160 spacing 2021-12-10 16:19:41 -05:00
Isaac Connor 5a57122891 fix typpo 2021-12-10 16:17:54 -05:00
Isaac Connor 5312d11e78 Don't both running zmu if monitor Function is set to None 2021-12-10 16:08:43 -05:00
Isaac Connor ed360348ef spacing, remove dead code. If Monitor Function becomes None, skip it 2021-12-10 15:36:47 -05:00
Isaac Connor aa320cb28f Fix missing STATE_UNKNOWN 2021-12-10 15:35:53 -05:00
Isaac Connor 5d8db0a320 Merge cycle functionality into watch view. Add period dropdown, countdown timer, toggle the sidebar. Fix auth on statusAjax, and don't use status ajax unless we are in still mode. Apply some min-width to fps so they don't jump around. Only update their content if it has changed (fewer browser renders). 2021-12-10 15:34:35 -05:00
Isaac Connor 7bc46ba7a8 Create the .tar.gz by default if it doesn't exist. Only warn if it already exists. 2021-12-09 15:19:49 -05:00
Isaac Connor 6e01bca187 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-09 15:09:50 -05:00
Isaac Connor a9ef5bf731 Add STATE_UNKNOWN and correct values of other states 2021-12-09 12:36:03 -05:00
Isaac Connor 31a1ef6cb4 Move state definitions into skin.js.php because they are used in several different views. Add STATE_UNKNOWN to match of with c++ side actual values. 2021-12-09 12:35:42 -05:00
Isaac Connor 090c803b98 Wait for closeEvent thread to finish. Fixes unfinished event when zmc told to restart 2021-12-09 12:33:59 -05:00
Isaac Connor 35bca1d89b When launching concurrent zmfilter, use the id instead of Name because Name isn't necessarily unique 2021-12-06 10:32:17 -05:00
Isaac Connor 3b84d7d82a Add --daemon to command line documentation so it ends up in man page. Fixes #3393. Improve the description and move the pod documentation to the bottom after __END__. Improve executeCommand a bit 2021-12-06 10:28:02 -05:00
Isaac Connor 1f78776093 Don't change colour of dot to warning when not Enabled and not doing analysis. Add reason to the dot 2021-12-06 09:48:44 -05:00
Isaac Connor 7b66d751d8 cleanup, spacing, use zone object methods to clean up svg zone layers 2021-12-05 17:49:24 -05:00
Isaac Connor 089c6044f1 Add layers toggle button, cleanup code by using ->canView, rename Monitor to monitor, add svg zones layer 2021-12-05 17:48:49 -05:00
Isaac Connor 76c4560c25 put svg zone styles in one files that can be included where needed 2021-12-05 17:46:25 -05:00
Isaac Connor e6a12d20c6 Add svg syles and rename imageFeed to videoFeed 2021-12-05 17:45:54 -05:00
Isaac Connor 45559123af Add numCoords, Coords, Area, AlarmRGB to Zone object. Also add Points(), AreaCoords, svg_polygon utility functions to it. 2021-12-05 17:45:26 -05:00
Isaac Connor 1fc0e93673 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-12-03 15:13:13 -05:00
Isaac Connor 27e87fc21f Move all the opening of events code into one function called openEvent. 2021-12-03 13:25:50 -05:00
Isaac Connor eef172379c Move all the opening of events code into one function called openEvent. 2021-12-03 13:25:50 -05:00
Isaac Connor 1277e75278 Detect group hierarchy loops and break them. 2021-12-03 13:25:50 -05:00
Isaac Connor 5f9dcabee1
Merge pull request #3394 from petterreinholdtsen/conf-socket-comment
Make config file comment on unix socket option a bit clearer
2021-12-02 09:24:02 -05:00
Petter Reinholdtsen 5647c224d1 Make config file comment on unix socket option a bit clearer
Initially I took the comment for granted, and the 'unix_socket' string
as a magic string to tell zoneminder to use the mysql default socket.  Alas,
this do not work, as the setting really need to point to the path of the socket.
Rewrite the comment to make this more clear, and less confusing for the
future users.
2021-12-02 15:18:04 +01:00
Isaac Connor 37069cb6fc add cmake module to find libFmt 2021-11-29 18:59:44 -05:00
Isaac Connor 2b289abb95 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-29 18:50:52 -05:00
Isaac Connor ca42a46bb4
Merge pull request #3392 from maddios/patch-1
Fix Copy/Move to Default Storage
2021-11-29 18:39:18 -05:00
Isaac Connor 1cddac4efd remove remaining signal blocking cruft, add ignoring sigchld so that anything we spawn doesn't become a zombie. 2021-11-29 18:34:19 -05:00
Isaac Connor c927ef4b52 Aim to do db updates every 5 seconds instead of 1 second 2021-11-29 18:34:19 -05:00
Isaac Connor b5098a1ab9 Do not guess multiple distros. release building will have automated distro specification. 2021-11-29 16:26:23 -05:00
Isaac Connor 11a140d48e Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-29 16:24:46 -05:00
Isaac Connor 1783eff58a Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-29 16:21:40 -05:00
Isaac Connor 7b9c86111c Move Cleanup and framebuffer freeing into Close() so that we don't crash on Reload 2021-11-29 16:21:34 -05:00
Isaac Connor 65dacbc317 Merge branch 'master' of github.com:ZoneMinder/ZoneMinder 2021-11-29 14:15:10 -05:00
Isaac Connor 089563d1ce rework do_debian_package to properly support the CURRENT style of snapshots and make the code a little easier to read 2021-11-29 14:14:56 -05:00
Isaac Connor 82a4cbaec5 Fix task=>action so that deleting works. Pause streaming before delete to prevent errors being logged due to missing files 2021-11-29 13:49:07 -05:00
Isaac Connor 072d181f79 Fix AlarmStartCommand => EventStartCommand 2021-11-29 13:49:07 -05:00
Isaac Connor ea6a84ae66 Fix AlarmEndCommand => EventEndCommand 2021-11-29 13:49:07 -05:00
Isaac Connor 1f19ad7c9d fix by removing code block 2021-11-29 13:49:07 -05:00
Isaac Connor 01f4aee450 Fix underline 2021-11-29 13:49:07 -05:00
maddios b47e96d7cf
Fix Copy/Move to Default Storage
When moving from a 2nd storage to Default it fails with "New storage does not have an id.  Moving will not happen" because the default ID is 0.
2021-11-29 00:20:25 -05:00
Isaac Connor 6aaebafd17
Merge pull request #3391 from pkubaj/patch-1
Fix build on FreeBSD/armv7
2021-11-28 20:08:19 -05:00
pkubaj 74a2276671
Fix build on FreeBSD/armv7
1. FreeBSD uses elf_aux_info instead of getauxval.
2. FreeBSD uses HWCAP_NEON macro for Neon.
2021-11-29 00:03:45 +00:00
Isaac Connor ba73321628 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-26 19:23:12 -05:00
Isaac Connor 28d8b22377 bump version 1.37.5 2021-11-26 19:22:53 -05:00
Isaac Connor 21218491f7 Add EventStartCommand and EventEndCommand to monitors ui 2021-11-26 19:22:07 -05:00
Isaac Connor b626de50dc Add code to fork and exec EventStartCommand and EventEndCommand 2021-11-26 19:21:51 -05:00
Isaac Connor d51eb63947 Add EventStartCommand and EventEndCommand to monitors table 2021-11-26 19:21:24 -05:00
Isaac Connor f9f2615d48 Return if unable to lock the event record. Improve code around CopyTo call. 2021-11-26 15:26:38 -05:00
Isaac Connor 7468727b75 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-26 13:38:05 -05:00
Isaac Connor a1bf8f7f5b Fix NULL and add special 0 case for Storage area specification in filter 2021-11-26 10:35:15 -05:00
Isaac Connor af5436d009 Handle bug where a value of '' will prevent special case handling. Allow '' to mean NULL when specifying Storage Area 2021-11-26 10:31:54 -05:00
Isaac Connor e8bb095730 include monitor dimensions when logging about zone mismatch 2021-11-24 14:28:31 -05:00
Isaac Connor e061f3b34a typo 2021-11-24 14:28:15 -05:00
Isaac Connor 6037cdc2a3 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-24 13:44:59 -05:00
Isaac Connor 77d3109152 Increase to 20 before warning about db queue size. Put lock in it's own scope so that we unlock before notifying 2021-11-24 13:44:45 -05:00
Isaac Connor 67556430c6 Add option ZM_NO_PCRE to disable testing for libpcre3. debian wants to remove it so this allows us to test building without it. Remove libpcre3 from depends and set ZM_NO_PCRE=ON in debian build config 2021-11-24 12:44:07 -05:00
Isaac Connor 4be9c6cdd2 Code comments and make warning when the first packet in queue is locked. 2021-11-24 12:42:31 -05:00
Isaac Connor 81ffc6df4e Remove text-nowrap from cause/notes column 2021-11-24 12:06:13 -05:00
Isaac Connor ffdb0f9824 If we are starting a process that is waiting to term, mark it to get started by the reaper. Fixes case where zmdc thought the process was still running and so didn't start it. We never noticed because zmwatch would eventually notice. The result is instant restart. 2021-11-23 11:05:39 -05:00
Isaac Connor 46a835b28a fix error when no monitors defined and we are adding one.Fixes #3385 2021-11-22 14:26:48 -05:00
Isaac Connor 1f75b017cc kill the background timer when switching to history so that we don't cause a javascript error. comment out debugging and use native javascript instead of jquery. 2021-11-22 14:17:50 -05:00
Isaac Connor cc65c99791 Move init of ctx up before we setup the monitors. I think in some cases we can calls functions that assume ctx has a value. Uncaught%20TypeError%3A%20Cannot%20read%20properties%20of%20undefined%20(reading%20'getImageData') 2021-11-22 12:53:51 -05:00
Isaac Connor 40e7f607f5 If no protocol defined, fall back to the name of the Control 2021-11-22 11:38:40 -05:00
Isaac Connor 2529765df3 timestamp image before scaling. Fixes lack of scaling when TIMESTAMP_ON_CAPTURE
is off
2021-11-19 11:59:19 -05:00
Isaac Connor 2c798069d3 improve debug logging when loading Control in Monitor 2021-11-18 18:12:07 -05:00
Isaac Connor bd89e85ea0 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-18 11:09:59 -05:00
Isaac Connor 0a30c55042 install manufacturers.sql and models.sql 2021-11-18 11:09:49 -05:00
Isaac Connor 084a66af4b Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-18 09:56:27 -05:00
Isaac Connor 6ee3c238e7 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-11-18 09:55:51 -05:00
Isaac Connor f63c124988 include manufacturers and models 2021-11-18 09:55:39 -05:00
Isaac Connor 18610fd601 Add an update script that includes manufacturers and models 2021-11-18 09:55:19 -05:00
Isaac Connor ae6925fb89 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-17 18:59:46 -05:00
Isaac Connor 805ef16e73 bump version 2021-11-17 18:59:37 -05:00
Isaac Connor 7b18b22f82 Fix value of unknown Model 2021-11-17 18:58:02 -05:00
Isaac Connor 9160ee932f remove debug 2021-11-17 18:57:53 -05:00
Isaac Connor 836fe8c2b1 spacing 2021-11-17 18:57:44 -05:00
Isaac Connor b1d881b118 Report more saving errors to ui 2021-11-17 18:57:36 -05:00
Isaac Connor a0666e777a Merge branch 'master' into add_manufacturer_model_to_monitors 2021-11-17 17:45:47 -05:00
Isaac Connor c37d8eeded spacing and report save errors 2021-11-17 17:45:38 -05:00
Isaac Connor 1c9f43bcaf Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-17 14:43:22 -05:00
Isaac Connor 96b4af6255 Enable multi-threading on decode 2021-11-17 14:43:13 -05:00
Isaac Connor 7e1df53aa6 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-11-17 13:52:53 -05:00
Isaac Connor 4945a016cf Restore inclusion of video files in export when not including images. Fixes #3324 2021-11-17 11:04:28 -05:00
Isaac Connor 4027520b94
fix removed libfmt-dev package 2021-11-16 15:19:30 -05:00
Isaac Connor a2ae63cefe
Merge branch 'master' into fmt 2021-11-16 15:10:45 -05:00
Isaac Connor ab9c538c37 Allow NOW or CURRENT for PACKAGE_VERSION similar to snapshot 2021-11-16 14:59:18 -05:00
Isaac Connor 03897bf68e Add privacy to options tabs so we can get back to it. 2021-11-16 09:49:49 -05:00
Isaac Connor 78a803abf8 Add Model and Manufacturer to telemetry listing 2021-11-16 09:47:34 -05:00
Isaac Connor 20629fdf5a Include Manufacturer and Model in telemetry 2021-11-16 09:20:14 -05:00
Isaac Connor f48511acba Add NULL for ModelId column when adding MonitorPresets. 2021-11-16 09:19:42 -05:00
Isaac Connor 6cbc4c0a7a Update MonirorPresets to link to Amcrest cams 2021-11-15 16:30:39 -05:00
Isaac Connor 4e9a56624d Use UPSERTS and add some more models 2021-11-15 16:30:17 -05:00
Isaac Connor e63222d733 Add IGNORE so it does UPSERT 2021-11-15 16:30:03 -05:00
Isaac Connor 71c29afa7b Merge branch 'master' into add_manufacturer_model_to_monitors 2021-11-15 09:47:34 -05:00
Isaac Connor d00430f799 Add ModelId to MonitorPresets 2021-11-15 09:47:11 -05:00
Isaac Connor c84f42e280 Set to never timeout while generating video 2021-11-12 15:11:48 -05:00
Isaac Connor e35dc3902e Make state enum start at 0 as we are indexing into an array for StateStrings 2021-11-12 15:11:48 -05:00
Isaac Connor d94c100a72 Use event->StartTime instead of GetVideoWriterStartTime. Add some parenthesis to make logic clearer and add more info to debug statements 2021-11-12 15:11:48 -05:00
Isaac Connor 8872b8be63 spacing 2021-11-12 15:11:48 -05:00
Isaac Connor 795c5bb7d7 setScale to auto 2021-11-12 15:11:48 -05:00
Isaac Connor ac03a88550 Include url_to_zms in monitorData 2021-11-12 15:11:48 -05:00
Isaac Connor 529e889d99 remove extra , 2021-11-12 15:11:48 -05:00
Isaac Connor 14e578cdb2 Implement Exit Fullscreen using same button 2021-11-12 15:11:48 -05:00
Isaac Connor a7fd65d844 Put SCALE_BASE in skin.js.php as it is used in many places. 2021-11-12 15:11:48 -05:00
Isaac Connor 6f3e22f2a0 If no bottom element is specified, take the last child of content in scaleToFit 2021-11-12 15:11:48 -05:00
Isaac Connor 8d0463bbff Implement getElement, setScale in MonitorStream.js 2021-11-12 15:11:48 -05:00
Isaac Connor 98e29e7ef6 implement UrlToZMS in Monitor 2021-11-12 15:11:48 -05:00
Isaac Connor 9d37fbcd8e Fix some build warnings on arm 2021-11-12 15:11:48 -05:00
Isaac Connor dc9f7b4d1d Rough in fullscreen mode on montage 2021-11-12 15:11:48 -05:00
Isaac Connor acff4fb9c0 rough in fullscreen mode in watch view 2021-11-12 15:11:48 -05:00
Isaac Connor c76e688f05 Don't exit(0) on QUIT. Instead set zm_terminate=true so that all the cleanup routines run. 2021-11-12 15:11:48 -05:00
Isaac Connor 53c57478b8 Ignore versioned bootstrap 2021-11-12 15:11:48 -05:00
Isaac Connor 82a26a1f83 use != Monitor instead of all the other cases 2021-11-12 15:11:48 -05:00
Isaac Connor bdf55f105e Spacing 2021-11-12 15:11:48 -05:00
Isaac Connor 0573c09b50 Cleanup and spacing. Rework last_motion_score to be a bit more efficient and use fewer lines. Fix case where MOCORD was not ending/starting event on alarm. 2021-11-12 15:11:48 -05:00
Isaac Connor 71931f007a alert error message is an error is returned instead of rows 2021-11-12 15:11:48 -05:00
Isaac Connor 944c04e5b4 Whitespace 2021-11-12 15:11:48 -05:00
Isaac Connor 9036728bdc Report error if sql fails. Add check for access to specific event. 2021-11-12 15:11:48 -05:00
Isaac Connor 01eac4a277 Default to now instead of ... epoch? when endtime is null. Fixes video playing when event is incomplete 2021-11-12 15:11:48 -05:00
Isaac Connor 3ac5402699 Pretty up the v4l field names 2021-11-12 15:11:48 -05:00
Isaac Connor caeaf91cad Only list available ids if there are some 2021-11-12 15:11:48 -05:00
Isaac Connor 8868a0fc41 enforce default action 2021-11-12 15:11:48 -05:00
Isaac Connor 1561adbef9 Add title to Download button 2021-11-12 15:11:41 -05:00
Isaac Connor 193f349e38 implement Event::canEdit 2021-11-12 13:37:01 -05:00
Isaac Connor 036d47a832 proper fix to memleak 2021-11-11 14:42:08 -05:00
Isaac Connor 6d30f5431b Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-11 13:58:56 -05:00
Isaac Connor a0215067e4 In multi-server when viewing an event it may be coming from a different server than the serverhost. Use monitorUrl instead of thisUrl in ajax calls and include auth data. Fixes failed ajax when viewing h264 using zms on a multi-server environment 2021-11-11 13:58:52 -05:00
Isaac Connor 883772295d spacing and log the new log level string as well as number 2021-11-11 13:51:17 -05:00
Isaac Connor 6cd1f6b5f3 Fix memleak on event creation due to not freeing storage object 2021-11-11 13:50:18 -05:00
Isaac Connor dc756ad670 add back update for Manufacturers and Models 2021-11-10 19:20:39 -05:00
Isaac Connor 9d71f1192a merge manufacturer update into existing zm_update-1.37.2 and then move it to .in 2021-11-10 19:18:16 -05:00
Isaac Connor 721769993b Set to never timeout while generating video 2021-11-10 17:05:46 -05:00
Isaac Connor 8d85d0f640 Make state enum start at 0 as we are indexing into an array for StateStrings 2021-11-10 16:53:29 -05:00
Isaac Connor 5ac9f88d00 Use event->StartTime instead of GetVideoWriterStartTime. Add some parenthesis to make logic clearer and add more info to debug statements 2021-11-10 16:53:07 -05:00
Isaac Connor 2c0c257d76 spacing 2021-11-10 14:25:45 -05:00
Isaac Connor 0732d4c1b3 setScale to auto 2021-11-10 14:25:29 -05:00
Isaac Connor 377219befe Include url_to_zms in monitorData 2021-11-10 14:25:12 -05:00
Isaac Connor ed84b59671 remove extra , 2021-11-10 14:23:36 -05:00
Isaac Connor 5d0bd978e4 Implement Exit Fullscreen using same button 2021-11-10 14:22:05 -05:00
Isaac Connor 43c1886267 Put SCALE_BASE in skin.js.php as it is used in many places. 2021-11-10 14:21:38 -05:00
Isaac Connor b8f6172110 If no bottom element is specified, take the last child of content in scaleToFit 2021-11-10 14:21:12 -05:00
Isaac Connor 474f65cff3 Implement getElement, setScale in MonitorStream.js 2021-11-10 14:20:19 -05:00
Isaac Connor 4c2d50c1f4 implement UrlToZMS in Monitor 2021-11-10 14:18:58 -05:00
Isaac Connor 44d88edbbb Fix some build warnings on arm 2021-11-09 17:01:13 -05:00
Isaac Connor f263da8986 Rough in fullscreen mode on montage 2021-11-09 17:01:13 -05:00
Isaac Connor 30d4900b45 rough in fullscreen mode in watch view 2021-11-09 17:01:13 -05:00
Isaac Connor 508be72e08 Don't exit(0) on QUIT. Instead set zm_terminate=true so that all the cleanup routines run. 2021-11-09 15:49:44 -05:00
Isaac Connor 96a58f8c88 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-09 14:00:25 -05:00
Isaac Connor 66517218f1 Ignore versioned bootstrap 2021-11-09 14:00:04 -05:00
Isaac Connor 5d23362ae0 use != Monitor instead of all the other cases 2021-11-09 13:59:14 -05:00
Isaac Connor 38105c6796 Spacing 2021-11-09 13:59:14 -05:00
Isaac Connor 7aefd657c7 Cleanup and spacing. Rework last_motion_score to be a bit more efficient and use fewer lines. Fix case where MOCORD was not ending/starting event on alarm. 2021-11-09 13:59:14 -05:00
Isaac Connor 7abbfc2fb5 alert error message is an error is returned instead of rows 2021-11-09 13:59:14 -05:00
Isaac Connor e617eb8615 Whitespace 2021-11-09 13:59:14 -05:00
Isaac Connor ce81099489 Report error if sql fails. Add check for access to specific event. 2021-11-09 13:59:14 -05:00
Isaac Connor 8c2dec03b6 Default to now instead of ... epoch? when endtime is null. Fixes video playing when event is incomplete 2021-11-09 13:59:14 -05:00
Isaac Connor 6609c154f2 Pretty up the v4l field names 2021-11-07 11:28:34 -05:00
Isaac Connor f737e3e945 Only list available ids if there are some 2021-11-06 09:58:31 -04:00
Isaac Connor 1fd99424bb Merge branch 'master' into add_manufacturer_model_to_monitors 2021-11-05 10:13:41 -04:00
Isaac Connor b2d9e5608f Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-03 17:08:59 -04:00
Isaac Connor 364ae03195 Set zm_terminate on crash so that other threads exit instead of continuing 2021-11-03 17:04:13 -04:00
Isaac Connor 0119ff46aa Remove redundant debug 2021-11-03 17:03:54 -04:00
Isaac Connor 93055f44e8 Merge UpdateCaptureFPS and UpdateAnalysisFPS into UpdateFPS and call it from zmc after capture. 2021-11-03 17:03:29 -04:00
Isaac Connor 814eca2b4f Include the codec in the resulting mp4 filename. Remove event update setting the mp4 filename after insert, do it on event completing instead. Saves 1 db update. 2021-11-03 17:02:02 -04:00
Isaac Connor a799eb3ad9 add function get_codec to return the codec used in the output mp4 2021-11-03 17:01:11 -04:00
Isaac Connor b26ce4378d Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-02 18:00:24 -04:00
Isaac Connor 5f27c124c3 Ignore bootstrap-4.5.0.js 2021-11-02 18:00:18 -04:00
Isaac Connor ae4a33beb2 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-11-02 17:40:37 -04:00
Isaac Connor 3208059040 Fix event listing when not paginated. 2021-11-02 17:24:05 -04:00
Isaac Connor 8619971864 Better debug messages 2021-11-02 17:24:05 -04:00
Isaac Connor 61f7989bec Actually report the # of dbQueue entries 2021-11-02 17:24:05 -04:00
Isaac Connor dd949bb129 av_write_trailer can return a positive value which is not an error 2021-11-02 17:10:02 -04:00
Isaac Connor 0e3f694097 Rename bootstrap with version so we don't have to cache bust it, so that .map loading works. 2021-10-31 15:19:26 -04:00
Isaac Connor 97164fd4d7 Fix use of thisUrl instead of monitorUrl when getting stream status. Fix changing stream image due to use of jquery. 2021-10-31 14:44:36 -04:00
Isaac Connor 3f0bdf6332 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-29 18:54:47 -04:00
Isaac Connor 224b34d69d Send all stats rows instead of just 1. Handle receiving all rows, and don't list event id and frame id 2021-10-29 18:54:23 -04:00
Isaac Connor 1168fc52a5 spacing and check for permission to view the specific event instead of events in general 2021-10-29 18:53:23 -04:00
Isaac Connor df88c5bbef layout->layer 2021-10-28 15:28:03 -04:00
Isaac Connor 4122ae99a5 add a comment about rollbacks 2021-10-28 15:27:45 -04:00
Isaac Connor b4314e5d46 Remove debugging 2021-10-28 15:12:24 -04:00
Isaac Connor e063f0715f reset starttime when changing events. Fixes super fast playback after switch to next event. Also, skip some unneeded calculations and logging. 2021-10-28 13:00:41 -04:00
Isaac Connor dedd755e5c Handle auth to mysql problems more gracefully 2021-10-28 12:46:42 -04:00
Isaac Connor 644c6e6b41 Just return the error 2021-10-28 11:48:08 -04:00
Isaac Connor 76b75cc69b Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-28 10:47:02 -04:00
Isaac Connor fee69d3bc2 is no longer in existence 2021-10-28 10:46:50 -04:00
Isaac Connor 0c157904e6 add js to manage the generate video button 2021-10-28 10:46:50 -04:00
Isaac Connor 2a160f045d Put back generate video button 2021-10-28 10:46:50 -04:00
Isaac Connor c2bd2dc129 Add a warning if db queue is larger than 10 2021-10-28 10:46:50 -04:00
Isaac Connor 9fe2762bc8 Add mp4 as an option for generated video and make it the default instead of avi 2021-10-28 10:46:50 -04:00
Isaac Connor 5955e4b410 add licensing info for fontawesome. 2021-10-28 10:46:50 -04:00
Isaac Connor d8e4a77424
Merge pull request #3361 from criadoperez/debian-install
Added Debian 11 (bullseye) installation instructions
2021-10-28 09:55:07 -04:00
Isaac Connor a946c45614
Merge pull request #3381 from SzymekCRX/patch-1
Critical bug in events.php
2021-10-28 09:13:23 -04:00
SzymekCRX 2bcad7bf5e
Critical bug in events.php
Two extra brackets causes fatal error in Ajax request causing 500 HTTP error and problems with listing / deleting events
2021-10-28 07:43:44 +02:00
Isaac Connor 6478999ecf Fix Event count subsitutions in emails because they are no longer in Monitor_Status. They are in Event_Summaries. So create a new object for them and use it. 2021-10-27 12:21:03 -04:00
Isaac Connor a74b785d08 Move the protocol loading into the Monitor Object. 2021-10-26 18:15:43 -04:00
Isaac Connor a2ec18be5a Implement Control() function to implement the Protocol Specific Control object 2021-10-26 18:15:43 -04:00
Isaac Connor d62d88a0a3 add utility functions parseNameEqualsValueToHash and hash_diff 2021-10-26 18:15:43 -04:00
Isaac Connor c864d0765b Update, add url parsing to match other control scripts. Add getConfig and setConfig 2021-10-26 18:15:43 -04:00
Isaac Connor cebe86feb2 Make ZoneMinder::Control ingerit from Object. Make loadMonitor use MonitorId 2021-10-26 18:15:43 -04:00
Isaac Connor d56de57494 set vertical-align:top on monitor edit labels 2021-10-25 16:55:23 -04:00
Isaac Connor a55bd23bf6 Add some extra parenthesis to make sure the logic works right 2021-10-25 16:55:23 -04:00
Isaac Connor 7f573b147f Continue altering monitor view to do Capturing, Analysing, Recording 2021-10-25 16:54:53 -04:00
Isaac Connor fb67c6a3e7 Add defaults for Capturing, Analysing, Recording 2021-10-25 16:53:42 -04:00
Isaac Connor 3770306817 Add logic to skip capturing if Capturing()==Ondemand 2021-10-25 16:53:18 -04:00
Isaac Connor cc51642eff Add Capturing() Analysing() Recording() and fix hasViewers logic 2021-10-25 16:52:49 -04:00
Isaac Connor 509cecf9f5 Skip image checking capturing==Ondemand 2021-10-25 16:52:20 -04:00
Isaac Connor 72d2b99ca4 Add last_viewed_time 2021-10-25 16:51:57 -04:00
Isaac Connor 1e38cf8bb7 Fix monitor type labels by adding an Unknown for entry 0. Implement Function_Strings. Fix decoding_enabled not being recalculated correctly because we havn't loaded savejpegs or videowriter yet. 2021-10-25 16:40:21 -04:00
Isaac Connor 51e77438fa Add sort-name and sort-order to bootstrap table options. Also set data-remember-order=false. This allows orderings set by filters to work. Fixes #3348 2021-10-25 12:35:46 -04:00
Isaac Connor 0c222f66ee Add sort_asc, sort_field and limit to the filter QueryString 2021-10-25 12:34:51 -04:00
Isaac Connor 8afed25d18 Use filter->sort_asc and sort_field which will use either the value specified in query, or defaults set in system. url params order and sort will override. 2021-10-25 12:34:28 -04:00
Isaac Connor 5e21d4833a Remove dead code, remove locking from CopyTo, put locking into MoveTo. 2021-10-25 11:09:29 -04:00
Isaac Connor 9169da6963 Only start a transaction if we are not already in a transaction 2021-10-25 11:09:06 -04:00
Isaac Connor df1b42ab53 add setLastViewed for monitors that have clients 2021-10-24 17:45:22 -04:00
Isaac Connor 3d2615d66f Spacing 2021-10-24 17:43:34 -04:00
Isaac Connor 824322dff6 spacing and setLastViewed in monitor when streaming 2021-10-24 17:43:02 -04:00
Isaac Connor 6992644fc3 Add last_viewed_time and accessor functions 2021-10-24 17:42:39 -04:00
Isaac Connor c6eedd434c Make delete dialog disappear on success. Fixes #3377 2021-10-22 20:59:04 -04:00
Isaac Connor 4351f51929 Fix logic ordering in 1.35.14 updated that moves columns from Monitors table to Monitor_Status 2021-10-20 13:14:04 -04:00
Isaac Connor ccdf002c18 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-19 15:27:14 -04:00
Isaac Connor ac15ea42cd enforce default action 2021-10-19 14:34:17 -04:00
Isaac Connor 52f0240334 free and re-init opts as needed 2021-10-19 13:05:11 -04:00
Isaac Connor 6d7f752eb0 Only record when in modect or nodect. Linked monitors would cause a monitor in monitor mode to record 2021-10-19 13:04:49 -04:00
Isaac Connor 16d0e269df WHen saving v4l settings redirect back to watch instead of console. 2021-10-19 12:39:37 -04:00
Isaac Connor bfcc6ed13e
Merge pull request #3376 from pmuetschard/encoder_opts
Respect the encoder options for the header write.
2021-10-19 12:37:59 -04:00
Pascal Muetschard 14e6d660e7 Respect the encoder options for the header write.
Fixes an issue where the encoder options were ignored in the
passthrough case, because the options were free'ed and not
re-initialized.
2021-10-18 20:15:02 -07:00
Isaac Connor 9f023f7bdd
Merge pull request #3372 from SudoMike/writable_image_buffer_function
Added non-const versions of Image::Buffer
2021-10-17 19:11:39 -04:00
Isaac Connor 4af605e675
Merge pull request #3374 from makers-mark/master
Fix typo
2021-10-17 19:10:34 -04:00
Isaac Connor d1596dee02 Fix removing uneeded checked 2021-10-17 19:08:12 -04:00
makers-mark 276add8ee4
Fix typo 2021-10-17 16:03:52 -04:00
Isaac Connor e1d49ea172 fix index -> image_index 2021-10-17 15:13:34 -04:00
Isaac Connor 3f6d6fe7a0 Improve debug logging of packetqueue cleaning 2021-10-17 15:02:31 -04:00
Isaac Connor 8cbd401dee Add AnalysisSource, Recording, RecordingSource, Capturing to monitor load. 2021-10-17 13:36:37 -04:00
Isaac Connor d55ada339c Add AnalysisSource, Recording, RecordingSource, Capturing to monitor load. Also in loading Linked Monitors, don't care about set function, as it might change during runtime 2021-10-17 13:36:14 -04:00
Isaac Connor c05200d2a7
Merge pull request #3373 from havardAasen/minor_fixes
Update man-pages and typos.
2021-10-17 11:54:48 -04:00
Håvard Flaget Aasen f2281d1017
Typos in documentation
This is typos noticed by lintian.
2021-10-17 13:29:00 +02:00
Håvard Flaget Aasen 5970416f0b
Fix errors when converting man-pages with pod2man.
Change unrecognised characters to corresponding ASCII value.

pod2man generates errors when encountering non-ASCII characters.
It correctly guesses UTF-8, but it still displays an error message
in the produced man-page.
2021-10-17 13:23:41 +02:00
Isaac Connor c81f3d9c61 add Capturing, Analysing, AnalysisSource, Recording, RecordingSource to Monitors 2021-10-16 20:37:16 -04:00
Isaac Connor 45b7c7b105 add Capturing, Analysing, AnalysisSource, Recording, RecordingSource, SecondPath 2021-10-16 20:36:19 -04:00
Isaac Connor d8b51fcf38 add function for onchange for Capturing, Analysing, Recordin, SecondPath 2021-10-16 20:35:37 -04:00
Isaac Connor 8d1c45162d Add functions to return options for Capturing, Analysing, AnalysisSource, Recording, RecordingSource 2021-10-16 20:35:11 -04:00
Isaac Connor 7bda103b99 WHen saving v4l settings redirect back to watch instead of console. 2021-10-16 18:30:55 -04:00
Isaac Connor d960f9b6af Fix settings being blank due to missing v4l2-ctl 2021-10-16 13:19:19 -04:00
Isaac Connor 6c4156a483 Remove sleeping from Analysis thread. It is uneccessary and results in us starting off way behind the capture thread. It also limits us to 30fps. 2021-10-15 09:56:14 -04:00
Isaac Connor 1606f7918a Show ram/swap usage in bytes instead of kb. Correct title of ram vs swap. 2021-10-15 09:40:58 -04:00
Isaac Connor 809cb651c0 remove debug hello 2021-10-14 17:56:16 -04:00
Isaac Connor 5f381a244f Improvements to export. Fix tar -v, should be tar --version. make table width:100% and iframe height 100%. Always show thumbnail of video. Show Id of event if no other links. generate Images frame content event if no jpegs but there is an mp4. Set timeout to infinity for generating export. Provide more feedback if it breaks. Fix ticker. 2021-10-14 17:56:02 -04:00
Isaac Connor d71a5932f5 Turn off useless shm display in header. Add ram and swap usage 2021-10-14 13:33:29 -04:00
Isaac Connor 452d28a66b Turn off useless shm display in header. Add ram and swap usage 2021-10-14 13:31:35 -04:00
Isaac Connor 26ac52aaa9 Fix scaling the image after changeScale. Limit stream scale to 100, let browser do the scaling 2021-10-14 13:00:49 -04:00
Isaac Connor 086bf7a84f introduce new logic that keeps the initial keyframe and deletes 1 video frame after it to keep the count down. Also any audio frames it encounters. 2021-10-14 12:47:51 -04:00
Isaac Connor 411d15605a We can lockup if MaxImageBufferCount is less than keyframe interval. Give up after 10 tries and drop the packet 2021-10-14 10:08:51 -04:00
Isaac Connor 8a9c283c1c Fix loading importance. Needs to be -1 not -2. The first value is 1, but we want zero based. 2021-10-13 16:06:22 -04:00
Isaac Connor 64ab429519 Correct definition of Importance. Want less importance to have a hgiher value. Make not null. 2021-10-13 16:05:49 -04:00
Isaac Connor 74ac79479f notifying before waiting serves no purpose because we have the lock 2021-10-13 15:02:07 -04:00
Isaac Connor 4fee4d01e3 always correct decoding_enable, as zms needs to know it's correct value 2021-10-13 15:01:46 -04:00
Isaac Connor 00f9cb791c Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-13 13:43:10 -04:00
Isaac Connor f60282eaf5 Test for existence of AutoEmail and AutoMessage. Fixes #3369 issue 2. 2021-10-13 11:58:22 -04:00
Isaac Connor 6fd33b4627 Change commands used to set and goto presets. Fixes #3371 2021-10-13 10:42:23 -04:00
Mike Dussault d38a6adec4 No behavior change. Added non-const versions of Image::Buffer and fixed a few places that were casting away the constness. 2021-10-12 21:54:49 +00:00
Isaac Connor 2056172ea9 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-12 14:12:20 -04:00
Isaac Connor 126a102426 confirm before tar-gzipping orig. Fix default behaviour in dput prompt 2021-10-12 14:12:16 -04:00
Isaac Connor 0bac052a0a
Merge pull request #3370 from SudoMike/add_benchmarks
Add a zmbenchmark program
2021-10-12 13:43:00 -04:00
Isaac Connor 5cdc0efdb8 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-12 13:22:53 -04:00
Isaac Connor aafec8ead6 Put actions and options in a div, remove hr's and style the resulting div have the borders and clearing required. Make email options 100% 2021-10-12 13:22:41 -04:00
Peter Keresztes Schmidt cd45c61555 Use mt19937 as PRNG
Reasons: It's faster than rand() and can be made thread-safe
2021-10-12 19:18:21 +02:00
Peter Keresztes Schmidt c027b7a38d Fix some clang-tidy warnings 2021-10-12 19:05:22 +02:00
Peter Keresztes Schmidt 97b38bd4ab Align changes with our codestyle
See https://google.github.io/styleguide/cppguide.html for reference
2021-10-12 18:53:31 +02:00
Isaac Connor c6cac57fb1 remove bogus wanring 2021-10-12 12:45:06 -04:00
Isaac Connor 0ba3d863a6 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-10-12 12:25:01 -04:00
Mike Dussault 814124251e Fixed a CodeQL complaint 2021-10-11 23:57:20 +00:00
Mike Dussault 2cf16eb495 Removed some unused code and added more function comments 2021-10-11 15:58:30 -07:00
Mike Dussault 146ff1ac7a Print the benchmark results in a nicer table 2021-10-11 15:53:29 -07:00
Mike Dussault e4542de6f2 Fixed random image generation, and now it shows a proper (giant) perf difference between images that take longer for Zone's FILTERED_PIXELS detection to deal with. 2021-10-11 14:21:08 -07:00
Mike Dussault 9370cfe25c Added TimeSegmentAdder class and got benchmark output looking ok. 2021-10-11 21:12:46 +00:00
Mike Dussault 305af08112 Added Monitor scaffolding and a skeleton benchmark for DetectMotion. 2021-10-11 20:22:10 +00:00
Mike Dussault 3723e136b1 Initial benchmark exe 2021-10-11 19:44:58 +00:00
Isaac Connor 614750963b spacing 2021-10-07 12:37:03 -04:00
Isaac Connor 7079516e09 Fix indexing of camera type enum so that printing out from CameraType_Strings works 2021-10-07 12:36:28 -04:00
Isaac Connor 2dfbc013cb Fix curl cameras. PrimeCapture and PreCapture and PostCapture need to return 1. Also need to populate the packet and video stream. 2021-10-07 12:35:56 -04:00
Isaac Connor 505f3d1b32
Merge pull request #3366 from haade-administrator/patch-1
Update translation
2021-10-06 09:11:22 -04:00
Isaac Connor a465403c72 Handle when SERVER['HTTP_HOST'] is not set 2021-10-05 19:49:42 -04:00
Isaac Connor 7f09cddcd7 split actionBrightness etc into two different functions for get/set. This allows negative values to be set 2021-10-05 19:49:42 -04:00
Isaac Connor e394248baf Add ajax controls to realtime change the v4l2 ctrls 2021-10-05 19:49:42 -04:00
Isaac Connor 94cd3a6e69 Use v4l2-ctrl to list the available controls and display all of them. Use range sliders where appropriate. 2021-10-05 19:49:42 -04:00
Isaac Connor 52129c94ec spacing. Use a separate boolean to tell if we have specified a new value for controls. This allows negative settings. Fix zmy outputting brightness when contrast is specified. 2021-10-05 19:49:42 -04:00
Isaac Connor ba26235763 further deprecate v4l2 tests and spacing 2021-10-05 19:49:42 -04:00
Isaac Connor c72d34f176 fix validInt to take negative integers. Introduce validCardinal to handle positive integers 2021-10-05 19:49:42 -04:00
Isaac Connor 75a014321e Spacing, remove tests for v4l2, move control setting/getting code to a single function. 2021-10-05 19:49:42 -04:00
Isaac Connor 1f04723f3a dbError is supposed to take the sql that caused the error. So pass something to satisfy php 2021-10-05 19:49:42 -04:00
haade a0142d3896
Update translation 2021-10-05 08:15:39 +02:00
Isaac Connor 7ed76b5677
Merge pull request #3364 from TheRealJiffy/patch-1
Update mobile.rst
2021-10-03 11:08:56 -04:00
TheRealJiffy ca293eb288
Update mobile.rst
fix broken link
2021-10-02 23:42:08 -04:00
Alejandro Criado-Pérez 1e71300a3b
added Debian installation instructions 2021-09-30 01:15:45 +02:00
criadoperez e462c23115
updated dlandon repository name 2021-09-29 16:46:04 +02:00
criadoperez 9f683c0c91
Removed default-file parameter that is deprecated 2021-09-29 14:14:25 +02:00
criadoperez 8554ccd649
Added Debian 11 (bullseye) installation 2021-09-29 12:26:15 +02:00
Isaac Connor 9bbdd36252 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-09-28 19:44:31 -04:00
Isaac Connor 509a5549be Merge branch 'master' of https://github.com/ZoneMinder/zoneminder 2021-09-28 10:31:04 -04:00
Isaac Connor aca477e737 Add warning when MaxImageBufferCount is less than keyframe interval 2021-09-28 10:30:51 -04:00
Isaac Connor 95a7c6c32f fix crash on 32bit pi due to use of %ld instead of %PRId64 2021-09-28 10:29:41 -04:00
Isaac Connor ac375bc623 fix errant = 2021-09-27 11:03:29 -04:00
Isaac Connor 9cf4e89254 add update to 1.37.3 2021-09-27 11:03:16 -04:00
Isaac Connor f54e779b21
Merge pull request #3360 from ZoneMinder/strftime_en_gb_format
Define Date formats in lang file for en_gb resolves #2408
2021-09-27 10:58:43 -04:00
Isaac Connor 202d95fc5a handle AV_HWDEVICE_TYPE_MMAL not being defined 2021-09-27 10:58:16 -04:00
Isaac Connor ee65d3e3dc add cmaeramodels route 2021-09-27 10:57:06 -04:00
Isaac Connor fe734d4e1e Add Manufacturer and CameraModel hasOne relationships 2021-09-27 10:56:50 -04:00
Isaac Connor 1c01936f75 add oninput methods to text inputs for new Manufacturer/Model 2021-09-26 14:47:29 -04:00
Isaac Connor ee609ad28b Further develop behavour when typing in text input for new manufacturer or model. If it already exists, select it. 2021-09-26 14:46:56 -04:00
Steve Gilvarry dcd2c16774
Define Date formats
Set Locale for time to en_GB.utf8, changed STRF_FMT_DATETIME_SHORTER to %x which is locale aware short date, but does include year. Makes event table wider, not sure if that is a problem for others
2021-09-27 00:58:34 +10:00
Isaac Connor 7dbd950574 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-09-25 20:58:25 -04:00
Isaac Connor f40e2be28a Add an input for an Id to assign to the new monitor. List 10 available Ids. 2021-09-25 20:56:33 -04:00
Isaac Connor 43dfeb5b84 whitespace 2021-09-25 20:56:33 -04:00
Isaac Connor cbc376bb5a Add zm_rtsp_server to ignores 2021-09-25 20:56:33 -04:00
Isaac Connor 2e4bb73204 remove useless commit. 2021-09-25 20:56:33 -04:00
Isaac Connor 655daf4fbe Add mmal device/pix fmt type 2021-09-25 20:56:33 -04:00
Isaac Connor b8022cdda2 More new defaults. The navbar refreshes every 60 secs so make full page refresh be 240sec. Ajax timeout needs to be 10 seconds. Large event listings can take longer than 3 2021-09-25 20:56:33 -04:00
Isaac Connor e98728c529 Set new defaults for various settings 2021-09-25 20:56:33 -04:00
Isaac Connor 568be3fc54 initialize video_first_pts and when setting it need to specify microseconds otherwise we get nanoseconds. White space. 2021-09-25 20:56:33 -04:00
Isaac Connor 92f6d3cbae Restore the download button's behaviour. It is a simple link to the mp4, not an export. Also add a handler for the video.js rate control to sync up our non video.js rate dropdown and stored cookie. 2021-09-25 20:56:33 -04:00
Isaac Connor 6022dd59eb Always include the download button so that we can assume that it exists in the js. So avoid console errors when no mp4. 2021-09-25 20:56:33 -04:00
Isaac Connor 4bdf965dcb Set rows on email textarea 2021-09-25 20:56:33 -04:00
Isaac Connor 2a0ddc6337 Add open collective username 2021-09-25 20:56:33 -04:00
5472qaywsx d81be9701a Docs: Fix a typo (#3358) 2021-09-25 20:56:33 -04:00
Andrea Vezzali e75d5a89e9 Update italian (it_it) translation (#3357) 2021-09-25 20:56:33 -04:00
Isaac Connor 0bf417bae0 Reduce logging level to debug dealing with index == -1, which is used in zmu to mean the last captured image. Fixes #3354 2021-09-25 20:56:33 -04:00
ColorfullyZhang 9e4f203632 Set character set as utf8 when connect to mysql to avoid mistakes when there are Chinese characters in storage path. 2021-09-25 20:56:33 -04:00
ColorfullyZhang 874552c06b Set mysql character set to utf8 explicitly to support chinese characters (or other special characters). 2021-09-25 20:56:33 -04:00
Isaac Connor c233ec3b8c Remove redundant notify_all, spelling mistake 2021-09-25 20:56:33 -04:00
Mike Dussault e63be2b18e Fixed a bug in Image::Buffer that would return the wrong location in the image if the image had > 1 channels (and if the request were for x > 0). 2021-09-25 20:56:33 -04:00
Isaac Connor c5f4623104 Don't crash when unable to create source. erase will call the desctructor. Fixes #3344 2021-09-25 20:56:33 -04:00
Isaac Connor 38cda24b53 wait won't wake up other threads, so notify first. Since we have the lock, this should be ok 2021-09-25 20:56:33 -04:00
Isaac Connor cddb9d88bf Add support for package version 2021-09-25 20:56:33 -04:00
Isaac Connor de299ab882 More properly fix the threading lock. Instead of waiting on a packet, release it and wait on the packetqueue. 2021-09-25 20:56:33 -04:00
Isaac Connor 8272411bb2 Revert "use get_packet_and_increment_it instead of the two step to improve locking"
This reverts commit a44bbf8e34.
2021-09-25 20:56:33 -04:00
Isaac Connor 120d9764bc notify anyone waiting in packetqueue before waiting on a packet in motion detection. Should fix decode lockup 2021-09-25 20:56:33 -04:00
Isaac Connor c7aa41502a Fix js error in montage review when using scaled mode. Fixes #3351 2021-09-25 20:56:33 -04:00
Andrea Vezzali 787b7f1874 Update it_it.php 2021-09-25 20:56:33 -04:00
Andrea Vezzali c4a49721d2 Update it_it.php 2021-09-25 20:56:33 -04:00
Isaac Connor 6dbfd22190 Add missing update_function_pointers so that we use SSE blend functions. Significantly reduces cpu use in motion detection. 2021-09-25 20:56:33 -04:00
Andrea Vezzali 4b4152b837 Update it_it translation (#3350) 2021-09-25 20:56:33 -04:00
Peter Keresztes Schmidt a4ebf533a9 Image: Codestyle changes 2021-09-25 20:56:33 -04:00
Peter Keresztes Schmidt 93c5ad0939 Image: Fix Wclobbered warnings
From C99 spec:
[...]  objects of automatic storage duration that are local to the function containing the invocation of the corresponding setjmp macro that do not have volatile-qualified type and have been changed between the setjmp invocation and longjmp call are indeterminate

Remove the variables in question or pass them as const refs.
2021-09-25 20:56:33 -04:00
Isaac Connor 94c1b3445d Add an input for an Id to assign to the new monitor. List 10 available Ids. 2021-09-25 20:54:35 -04:00
Isaac Connor 292b3c1d37 add an ajax request for querying the available models 2021-09-25 20:49:53 -04:00
Isaac Connor c66489fb30 rough in api support for Models and Manufacturers 2021-09-25 20:49:30 -04:00
Isaac Connor d98d20958c fixup the Manufacturer and Model ddms and text inputs 2021-09-25 20:48:43 -04:00
Isaac Connor fe72056d73 fixup populating Models dropdown after Manufacturer select 2021-09-25 20:48:14 -04:00
Isaac Connor 34d9f87d6d remove cruft from ServersController.php 2021-09-25 20:44:16 -04:00
Isaac Connor 12783f6edf Add manufacturers, models and servers routes 2021-09-25 20:43:53 -04:00
Isaac Connor 03892796eb whitespace 2021-09-25 16:10:50 -04:00
Isaac Connor 888d79706a Add zm_rtsp_server to ignores 2021-09-25 16:08:58 -04:00
Isaac Connor a99f9091fc remove useless commit. 2021-09-25 14:27:10 -04:00
Isaac Connor 2f12615f08 assign REQUEST['newMonitor'] to a variable to simplify code. Fixup ModelId and ManufacturerId saving. 2021-09-25 10:33:16 -04:00
Isaac Connor 7ca7d40b6f Add defaults for ModelId and ManufacturerId. Fixes the methods for loading them 2021-09-25 10:32:04 -04:00
Isaac Connor c78e035057 Fix crash due to int64 cast to a %ld format. 2021-09-23 19:07:07 -04:00
Isaac Connor aae967e895 Add mmal device/pix fmt type 2021-09-23 16:39:35 -04:00
Isaac Connor 7748307c5a More new defaults. The navbar refreshes every 60 secs so make full page refresh be 240sec. Ajax timeout needs to be 10 seconds. Large event listings can take longer than 3 2021-09-23 16:39:35 -04:00
Isaac Connor d3cfd3c224 Set new defaults for various settings 2021-09-23 16:39:35 -04:00
Isaac Connor 30fa641186 initialize video_first_pts and when setting it need to specify microseconds otherwise we get nanoseconds. White space. 2021-09-21 14:29:05 -04:00
Isaac Connor 1cb9f98e9b Restore the download button's behaviour. It is a simple link to the mp4, not an export. Also add a handler for the video.js rate control to sync up our non video.js rate dropdown and stored cookie. 2021-09-21 13:01:05 -04:00
Isaac Connor 160f775f91 Always include the download button so that we can assume that it exists in the js. So avoid console errors when no mp4. 2021-09-21 13:01:05 -04:00
Isaac Connor dd6adc08a8 Set rows on email textarea 2021-09-21 13:01:05 -04:00
Isaac Connor 4b1da156a0 Add open collective username 2021-09-21 13:01:05 -04:00
5472qaywsx a7f13c82d5
Docs: Fix a typo (#3358) 2021-09-20 14:04:07 +02:00
Andrea Vezzali 2724a238e1
Update italian (it_it) translation (#3357) 2021-09-20 14:02:35 +02:00
Isaac Connor fba7dba3d0 Reduce logging level to debug dealing with index == -1, which is used in zmu to mean the last captured image. Fixes #3354 2021-09-16 10:03:30 -04:00
Isaac Connor 1700e2f919
Merge pull request #3355 from ColorfullyZhang/master
Set mysql character set to utf8 explicitly
2021-09-16 09:49:19 -04:00
ColorfullyZhang f5d8eaa2ad Set character set as utf8 when connect to mysql to avoid mistakes when there are Chinese characters in storage path. 2021-09-16 18:24:37 +08:00
ColorfullyZhang 6009bba339 Set mysql character set to utf8 explicitly to support chinese characters (or other special characters). 2021-09-16 14:41:24 +08:00
Isaac Connor e6f4cdb584 Remove redundant notify_all, spelling mistake 2021-09-15 13:38:06 -04:00
Isaac Connor 547fed2e22
Merge pull request #3353 from SudoMike/image_fix
Fixed a bug in Image::Buffer
2021-09-15 13:31:31 -04:00
Mike Dussault 3f97df72c8 Fixed a bug in Image::Buffer that would return the wrong location in the image if the image had > 1 channels (and if the request were for x > 0). 2021-09-15 10:13:02 -07:00
Isaac Connor 1ee85caaae Don't crash when unable to create source. erase will call the desctructor. Fixes #3344 2021-09-15 12:56:39 -04:00
Isaac Connor d2cf89565e wait won't wake up other threads, so notify first. Since we have the lock, this should be ok 2021-09-15 12:53:41 -04:00
Isaac Connor 03f0762709 Add support for package version 2021-09-14 18:08:50 -04:00
Isaac Connor bf5c0a8617 More properly fix the threading lock. Instead of waiting on a packet, release it and wait on the packetqueue. 2021-09-14 16:21:32 -04:00
Isaac Connor 167dece604 Revert "use get_packet_and_increment_it instead of the two step to improve locking"
This reverts commit a44bbf8e34.
2021-09-14 15:47:35 -04:00
Isaac Connor e140620900 notify anyone waiting in packetqueue before waiting on a packet in motion detection. Should fix decode lockup 2021-09-14 13:38:55 -04:00
Isaac Connor 7aa955abd2 Fix js error in montage review when using scaled mode. Fixes #3351 2021-09-14 10:26:17 -04:00
Isaac Connor 503f0da9da
Merge pull request #3352 from vezza/patch-3
Update it_it.php
2021-09-14 09:51:21 -04:00
Andrea Vezzali 3e5d377f7a
Update it_it.php 2021-09-14 15:39:53 +02:00
Andrea Vezzali 966749ff86
Update it_it.php 2021-09-14 15:16:25 +02:00
Isaac Connor 58f933ba1e Add missing update_function_pointers so that we use SSE blend functions. Significantly reduces cpu use in motion detection. 2021-09-13 15:03:42 -04:00
Isaac Connor a05560e797 fix merge of version 2021-09-13 09:30:29 -04:00
Isaac Connor dd2a12675f Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-09-13 09:30:04 -04:00
Andrea Vezzali 97c10fc135
Update it_it translation (#3350) 2021-09-13 13:28:48 +02:00
Peter Keresztes Schmidt 5fda85bf2e Image: Codestyle changes 2021-09-12 11:38:44 +02:00
Peter Keresztes Schmidt ecf6cc80aa Image: Fix Wclobbered warnings
From C99 spec:
[...]  objects of automatic storage duration that are local to the function containing the invocation of the corresponding setjmp macro that do not have volatile-qualified type and have been changed between the setjmp invocation and longjmp call are indeterminate

Remove the variables in question or pass them as const refs.
2021-09-12 11:36:51 +02:00
Isaac Connor 15adc47c61 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-09-10 18:24:44 -04:00
Isaac Connor 385d1602e0 Add an example fail2ban rule as provided by Pedulla 2021-09-10 13:54:24 -04:00
Isaac Connor c2472894be Fix html emails when using ZM_NEW_MAIL_MODULES. Improve debugging and reduce Info logging 2021-09-10 13:47:40 -04:00
Isaac Connor a9379e5813 Need to increase frame_count or else frame_count%frame_mod will never == 0 2021-09-10 10:58:06 -04:00
Isaac Connor 009b3ceffc Fix version of Crud 2021-09-09 13:28:25 -04:00
Isaac Connor e18f8019b0 canView takes a user object, not a string 2021-09-08 19:07:51 -04:00
Isaac Connor a44bbf8e34 use get_packet_and_increment_it instead of the two step to improve locking 2021-09-08 18:35:01 -04:00
Isaac Connor 227e5794fa Merge branch 'master' into add_manufacturer_model_to_monitors 2021-09-08 18:32:46 -04:00
Isaac Connor c5b097af0a Only suspend/resume motion detection if the monitor is doing motion detection 2021-09-08 13:57:46 -04:00
Isaac Connor b2415643f6 Add missing Importance member 2021-09-08 13:57:46 -04:00
Isaac Connor 68fc57ef7b
Merge pull request #3346 from criadoperez/fix-issue-3338
Fixed issue #3338
2021-09-08 09:30:59 -04:00
Isaac Connor 4b8ac48590
Merge pull request #3347 from criadoperez/fix-wikiurl
Fixed broken wiki links
2021-09-08 09:30:28 -04:00
criadoperez 4a717820b1
Fixed broken wiki links 2021-09-08 15:18:52 +02:00
criadoperez 876fca188b
Fixed issue #3338 2021-09-08 15:00:11 +02:00
Isaac Connor f576613c7d
Merge pull request #3345 from Carbenium/ci-freebsd-13
Fix FreeBSD build and improve CI
2021-09-07 18:57:25 -04:00
Peter Keresztes Schmidt 6e96cbe14a Misc: Merge ZM_HAS_V4L with ZM_HAS_V4L2 2021-09-08 00:19:08 +02:00
Peter Keresztes Schmidt 0ac060fb78 LocalCamera: Fix Wformat warnings on FreeBSD 2021-09-08 00:19:08 +02:00
Peter Keresztes Schmidt 443b84270a LocalCamera: Add a missing include to fix FreeBSD build
Fixes #3330
2021-09-08 00:19:08 +02:00
Peter Keresztes Schmidt c9f162f70e CI/Cirrus: Disable Wdeprecated-declarations temporarily
Keep these warnings disabled until av_init_packet usage is removed.
2021-09-08 00:18:24 +02:00
Peter Keresztes Schmidt c83882a4c7 Build: Move V4L2 detection into its own module
Improves detection across different platforms (esp. FreeBSD) since system paths are automatically taken into account (this is in contrast to check_include_file).
2021-09-08 00:18:24 +02:00
Peter Keresztes Schmidt 615e3dd76b CI/Cirrus: Install V4L compat layer 2021-09-07 23:23:57 +02:00
Peter Keresztes Schmidt 5dc328e68b CI/Cirrus: Add FreeBSD 13 to the build matrix 2021-09-07 19:15:24 +02:00
Isaac Connor 263a846251 Add missing fields. defaults need to be quoted because they are evalled 2021-09-04 10:43:38 -04:00
Isaac Connor 440bb12a9a defaults need to be quoted because they are evalled 2021-09-04 10:43:25 -04:00
Isaac Connor 9d461203bd Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-09-04 10:17:52 -04:00
Isaac Connor 8c45739875 Add impish to possible distros to build 2021-09-04 10:17:41 -04:00
Isaac Connor fe6f71e1dc Leave the zoneminder source dir during build-deps step so that we don't pollute it. Seems to be an issue with newer ubuntu builds. 2021-09-03 21:57:54 -04:00
Isaac Connor 328bd15360 Fix frame_count fps when paused 2021-08-30 18:06:05 -04:00
Isaac Connor 381fa0d08d Fix viewing fps display by keeping track of last update time, last frame count and actually calculate it based on frames sent over a period of time. 2021-08-30 17:55:32 -04:00
Isaac Connor 8199554217 Spacing and fix the bogus setting shared_data->valid to false on disconnect. Other processes call disconnect. Only the capturing thread should set it to false. 2021-08-30 13:33:26 -04:00
Isaac Connor 1a0d488457 Spacing 2021-08-30 13:32:43 -04:00
Isaac Connor 6b481fa2b5 Put back debhelper >= 11. We are deprecating stretch 2021-08-30 09:42:35 -04:00
Isaac Connor d102732a7e add autoplay tag. Fixes #3343 2021-08-29 09:44:04 -04:00
Isaac Connor 048b8b13a3 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2021-08-29 09:17:36 -04:00
Isaac Connor 6de8c71d2a Set shm->valid to false on disconnect. 2021-08-29 09:17:31 -04:00
Isaac Connor 4af979c842 spacing 2021-08-29 09:15:40 -04:00
Isaac Connor a52b9057ba stretch has debhelper 10 2021-08-27 11:40:46 -04:00
Isaac Connor 11137f9b7a
Merge pull request #3342 from gmanproxtreme/patch-1
Updated WEB_TITLE section from ToDo.
2021-08-27 10:14:46 -04:00
gmanproxtreme 84ccf10e65
Updated WEB_TITLE section from ToDo.
The Web_Title's use was unknown. I have seen the changed title appear on the login screen. Documentation updated to reflect this.
2021-08-27 20:21:02 +10:00
Isaac Connor a4c079d1b3 Add code to set colour ranges so that we can safely convert to YUV420p instead of YUVJ420P 2021-08-26 14:15:09 -04:00
Isaac Connor dbe16a9cb4 Don't use AUTH_HASH_IPS when talking to zmu as it doesn't support that at this time. 2021-08-26 10:45:36 -04:00
Isaac Connor 7c1c8482c6 Make failure to resolve non fatal 2021-08-24 10:23:24 -04:00
Isaac Connor 2640791b89 spacing 2021-08-23 18:13:19 -04:00
Isaac Connor 848a537a0f Fix zms giving 500 code instead of displaying error image due to not having sent the headers yet. 2021-08-23 18:10:31 -04:00
Isaac Connor 4596f61250
Merge pull request #3335 from r01k/master
Fixed "Call to undefined function" Exception in control_functions.php
2021-08-21 10:38:43 -04:00
r01k 79e041d0f0 Fixed bug that caused 'Call to undefined function Error()' in control_functions.php. Exception was being raised due to logger.php not being included in control_functions.php. 2021-08-20 22:42:57 -04:00
Isaac Connor 4a5bc88882 Always set image width to 100%. it should fill it's div and we will set the width of the div. 2021-08-19 18:57:00 -04:00
Isaac Connor 68a7635d9b Only show thumbnail if Function is != None 2021-08-19 18:40:50 -04:00
Isaac Connor 7a6c244aa7 spacing. When the selected layout is not freeform, calculate the ratio of computed size to stream source size to calculate a value for scale. 2021-08-19 16:05:43 -04:00
Isaac Connor 89d7685b14 Change Montage Layouts to reset width when choosing Freeform. Use full width instead of slightly less. I think at some point I fixed our layout so that we can use 25% instead of 24.5% etc. 2021-08-19 15:42:39 -04:00
Isaac Connor 44823e0c94 spacing remove dead code 2021-08-18 18:40:25 -04:00
Isaac Connor 8ddec91870 Allow snapshot downloading 2021-08-18 10:53:59 -04:00
Isaac Connor 7127a944a1 Use event->canView so that events in snapshots can be exported 2021-08-18 10:53:59 -04:00
Isaac Connor ba9a871daf Move CSP stuff down to view parsing. ajax requests only output json, so CSP shouldn't be relevant. Only end output buffer if there is one. archive view for example clears all output buffers. 2021-08-18 10:53:59 -04:00
Isaac Connor eb1124c406 Spacing and quotes 2021-08-18 10:53:59 -04:00
Isaac Connor b9efe627f3 implement Event->canView 2021-08-18 10:53:59 -04:00
Isaac Connor e7e8996060 Can export events if canView Snapshots. Event->canView will filter events that are not in a snapshot 2021-08-18 10:53:59 -04:00
Isaac Connor c12d88d874 Use canView.Snapshots for snapshot permissions instead of canView.Events 2021-08-18 10:53:59 -04:00
Isaac Connor 301d8fa5fa Change monitor->canView semantics so that a specified monitorId trumps the Monitors:None setting. This is so that the console can be hidden, but the group dropdown still gets populated. 2021-08-18 10:53:59 -04:00
Andrew Bauer aa48133096
Update zoneminder.spec
rpm specfile changelog not in chronological order (causes build failure on el8).
2021-08-15 12:46:19 -05:00
Isaac Connor 92a924044a turn Save, SaveAs and Execute into submit buttons. Put Id into the form action so that it shows up in the url bar. Disable putting the form contents into the url bar in parse_rows. 2021-08-12 13:44:49 -04:00
Isaac Connor a311455526 clean up code logic so that if we are executing an unchanged filter we don't do the unecessary save. 2021-08-12 13:42:36 -04:00
Isaac Connor 248ca9a5f9 Fix building SQL for ExistsInFileSystem PostCondition. Fix how we turn the rows into Event objects. Fix value handling in ExistsInFileSystem post condition. 2021-08-12 13:41:17 -04:00
Isaac Connor cd3359c3eb spacing. Add defaults for AutoMoveTo and AutoCopyTo so that we don't get false changes. redirect is a global, so make it so. Re-null the Id of the filter object after temp execute so that we don't reference a no longer existing filter. 2021-08-12 12:53:46 -04:00
Isaac Connor ccb4bb27dd Add more versions to support bionic 2021-08-10 17:01:26 -04:00
Isaac Connor bae8d38301 Drop back to debhelper 11 as that is what is in bionic 2021-08-09 11:33:11 -04:00
Isaac Connor cb4e17e49a Merge branch 'release-1.36' 2021-08-09 10:27:24 -04:00
Isaac Connor 066bb891af Fix url to ajax endpoint for deleting snapshots. 2021-08-06 19:18:27 -04:00
Isaac Connor f0b2f75d91 Cleanup, split export and download functions in snapshot. 2021-08-06 19:18:02 -04:00
Isaac Connor 672de6e84f event may have changed (have endtime set) between load and saving Archived bit. Lock the event which now also reloads it. 2021-08-06 19:15:22 -04:00
Isaac Connor 500ced2dc5 When locking, use the results to reload the object fields fresh as they may have changed since the object was loaded 2021-08-06 19:14:43 -04:00
Isaac Connor f2a1d06f64 Snapshot exports are now flat, without frame images 2021-08-06 13:18:31 -04:00
Isaac Connor eecf568041 Pass exportStructure around so that it can be used to put the right filename to the jpg in the html. Fix flat zips. Fix video files being included if exportMisc is true. 2021-08-06 13:18:06 -04:00
Isaac Connor 105851b70c Actually delete the snapshot record, not just the event connection 2021-08-06 13:17:02 -04:00
Isaac Connor f236e25e22 Fix deleting snapshots 2021-08-06 13:11:04 -04:00
Isaac Connor 1f1678064e Allow specifying export Structure to get a flat zip 2021-08-06 13:10:44 -04:00
Isaac Connor 222909feb3 zmu may still output results even if it encounters errors, so continue even if we have an error return status from zmu. 2021-08-05 14:48:14 -04:00
Isaac Connor 7db25a5e1b Continue to work even if opener isn't defined, which it isn't anymore because we got rid of popups. Fixes save button on monitorprobe. 2021-08-05 14:48:14 -04:00
Isaac Connor acdd8bb08b Merge script sections just to remove bytes per view. 2021-08-05 14:48:14 -04:00
Isaac Connor a3a592d5e1 Fix errors due to not stopping the dbQueue. Fix crash when querying v4l devices 2021-08-05 14:48:14 -04:00
Isaac Connor 45bf28a104
Merge pull request #3321 from anon8675309/gitlab-ci
Gitlab ci
2021-08-05 13:34:05 -04:00
Isaac Connor 7dc36f67db output an error message image when we can't load a jpeg 2021-08-05 13:30:52 -04:00
Isaac Connor 0bcbff5dd5 Turn on export functionality for snapshots 2021-08-05 13:30:52 -04:00
Isaac Connor bed41ca44b Support specifying the export filename by passing the export_root 2021-08-05 13:30:52 -04:00
Isaac Connor 91903d2822 Fix user summary, as there must be a space between -u and dbuser, etc 2021-08-05 13:30:52 -04:00
Isaac Connor 5bc9cfaa6a Fix styling of the shutdown button 2021-08-05 13:30:52 -04:00
Isaac Connor 85d5dd806e Read 4k at a time instead of 32 bytes. OS will read whatever is available. This basically reduces logging and a little cpu overhead 2021-08-05 13:30:52 -04:00
Isaac Connor dffc7aa2fd
Merge pull request #3326 from Carbenium/bullseye-readiness
misc: Final bits for Debian Bullseye support
2021-08-03 19:59:53 -04:00
Peter Keresztes Schmidt fb1849ff47 CI: Test package build with Debian Bullseye as well 2021-08-03 23:33:35 +02:00
Peter Keresztes Schmidt cce4b0aac4 docs: Reference current 1.36 version in installation instructions 2021-08-03 23:33:35 +02:00
Peter Keresztes Schmidt 2c0cf7a5a7 utils/startpackpack: Add support for Debian Bullseye 2021-08-03 23:33:35 +02:00
Peter Keresztes Schmidt b5765b4535 utils/startpackpack: Fix build for Ubuntu Bionic 2021-08-03 23:33:35 +02:00
Peter Keresztes Schmidt 7d84568b65 utils: Remove support for Ubuntu Groovy
Groovy went EOL as on July 22, 2021. See
https://fridge.ubuntu.com/2021/07/25/ubuntu-20-10-groovy-gorilla-end-of-life-reached-on-july-22-2021/
2021-08-03 23:33:35 +02:00
Peter Keresztes Schmidt 50b73cf3d2 utils/packpack: Fix failure when building for Ubuntu Hirsute 2021-08-03 19:02:39 +02:00
Peter Keresztes Schmidt 4392198d14 Fix closing event in MOCORD mode
Bug introduced in 707975e567
2021-08-03 09:56:07 +02:00
Isaac Connor 9cb19005e5
Merge pull request #3323 from SteveGilvarry/Fix_Dark_modal
Update Dark Skin to fix modal being light and some other issues
2021-08-02 09:59:22 -04:00
Steven Gilvarry cb32630dc0 Update Dark Skin to fix modal being light and some other issues
Fixed Modal style as per post to forums, then also fixed text area and select being white. Adjusted some other colours to work better. Console hover could be better still
2021-08-01 13:33:22 +10:00
anon8675309 47f171c75c Simplified branch detection in build scripts for GitLab CI, increased maximum build time 2021-07-24 13:15:30 -05:00
anon8675309 649b5585c4 Simplified branch detection in build scripts for GitLab CI 2021-07-24 10:37:07 -05:00
Isaac Connor 75180f78e2
Merge pull request #3319 from anon8675309/gitlab-ci
Gitlab ci
2021-07-21 08:05:33 -04:00
Isaac Connor 14047bc820 Test for existence of file before adding it to zip. Apparently our glob can return the snapshot.jpg string even if it doesn't exist. This is a workaround to Archive::Zip not testing for failure and crashing. Fixes #3313 2021-07-08 11:03:56 -04:00
Isaac Connor 1766bbdfcd Handle the case when the monitor doesn't exist more gracefully and not crash. Fixes #3316 2021-07-08 10:07:01 -04:00
Isaac Connor b0cf3a4732
Merge pull request #3314 from Carbenium/path-max
Fix Wformat for stringtf and convert path buffers depending on PATH_MAX to std::string
2021-07-07 11:34:03 -04:00
Isaac Connor 413ac984eb add models.sql 2021-07-07 09:48:24 -04:00
Isaac Connor 4ff4e1f780 add Manufacturer and Model dropdown/text inputs to monitor edit view 2021-07-07 09:47:55 -04:00
Isaac Connor 54f676a501 Add ManufacturerId_onchange and ModelId_onchange to hide/show the text input for custom entry 2021-07-07 09:47:32 -04:00
Isaac Connor c6209ce460 Store new Model and Manufacturer when saving Monitor 2021-07-07 09:47:00 -04:00
Isaac Connor 3bb2b804b3 Include Model and Manufacturer to includes in Monitor.php 2021-07-07 09:46:36 -04:00
Isaac Connor 24a77d7fb3 Add ManufacturerId to Model 2021-07-07 09:46:12 -04:00
Isaac Connor 8df915e7a4 Fix merge. 2021-07-07 09:45:53 -04:00
Isaac Connor cc486beed5 Add some Acti models 2021-07-07 09:45:23 -04:00
Isaac Connor 411a5181e6
Merge pull request #3315 from Carbenium/db-misc
Misc. cleanup of DB related code
2021-07-06 14:00:40 -04:00
Peter Keresztes Schmidt eaf2e51b0c utils: Make sure the compiler can emit format warnings for stringtf
Unfortunately the compilers can't emit Wformat warnings for variadic templates
and those can't be annotated with the format attribute.
Use a variadic function which can be annotated and thus warns on format string-args mismatches.

Ref 0796a2262e
2021-07-06 10:33:17 +02:00
Peter Keresztes Schmidt 80b08a2075 Convert path buffers depending on PATH_MAX to std::string 2021-07-06 10:33:17 +02:00
Peter Keresztes Schmidt 65656de6ce db: Adjust the query methods to accept std::strings 2021-07-06 10:20:46 +02:00
Peter Keresztes Schmidt c60b577aec Convert more char array buffers to std::string
Remove now unused ZM_SQL_*SIZE defines
2021-07-06 10:20:46 +02:00
Peter Keresztes Schmidt fc15afefcf Event: Remove unused and broken prepared statement code 2021-07-06 10:20:45 +02:00
Peter Keresztes Schmidt cf9c47149f db: Add helper for escaping strings and use it 2021-07-06 10:20:45 +02:00
Isaac Connor 2b6d54fd81 move db update script so it gets used. Bump version to 1.37.1 for db update 2021-07-05 09:33:03 -04:00
Isaac Connor 6373ef9be7 move db update script so it gets used. Bump version to 1.37.1 for db update 2021-07-05 09:32:39 -04:00
Kendric Evans 7e8a064725 Updating the size of the Longitude field
To address https://github.com/ZoneMinder/zoneminder/issues/3311
2021-07-02 16:11:34 -06:00
Isaac Connor 415dce6548
Merge pull request #3307 from pliablepixels/optimize-event-api
API: allow option to not load the frames DB table
2021-06-27 23:08:09 -04:00
Pliable Pixels 6c3f18a347 allow option to not load the frames DB table 2021-06-27 15:55:10 -04:00
Isaac Connor e9845d96f4 Fix Archive FTP .zip filename not including monitor name. Fixes #3304 2021-06-23 10:30:42 -04:00
anon8675309 c0875838af Attempting to build the lastest tag instead of a hard-coded one 2021-06-20 21:11:06 -05:00
anon8675309 d927db1c0d Attempting to build the lastest tag instead of a hard-coded one 2021-06-20 20:42:43 -05:00
anon8675309 f852f1716e Attempting to build the lastest tag instead of a hard-coded one 2021-06-19 18:11:57 -05:00
anon8675309 479385bac7 Attempting to build the lastest tag instead of a hard-coded one 2021-06-19 17:49:23 -05:00
anon8675309 1e834f6088 Attempting to build the lastest tag instead of a hard-coded one 2021-06-19 16:03:13 -05:00
anon8675309 1096fa3f87 Attempting to build the lastest tag instead of a hard-coded one 2021-06-19 15:01:17 -05:00
Andrew Bauer 0edc91ffca comment to rpm changelog regarding cmake 2021-06-18 15:27:24 -05:00
Andrew Bauer ec861c5e2b only refer to cmake3 when building on el7 2021-06-18 15:25:17 -05:00
Andrew Bauer db7c5df8c1
Update zoneminder.spec 2021-06-18 13:08:17 -05:00
Andrew Bauer b59e911c43 Allow cakephp cache engine to be set during build 2021-06-18 12:12:01 -05:00
Isaac Connor 9438445d74 Fix PTZ Diagonal cmds. Fixes #3300 2021-06-16 15:56:08 -04:00
Isaac Connor e6b67dcdc2 We cannot delete from the queue when capturing. Just do the waiting. Reduce severity of logs. Make more use of auto. Realise that no other iterators can be pointing into the queue. 2021-06-15 13:42:55 -04:00
Isaac Connor c3fb84bf88 Add an age component of 7d to /var/tmp/zm so that exports and other files go away 2021-06-15 10:44:02 -04:00
Isaac Connor 29fb2d3885 Add special handling of sorting by EndTime because it can be NULL. Fixes #3298 2021-06-15 10:34:33 -04:00
Peter Keresztes Schmidt ea10939970 zmu: Fix missing include 2021-06-15 00:16:08 +02:00
Peter Keresztes Schmidt 531694bf8d RtspThread: Add missing static_cast when fprinting duration .count() 2021-06-14 20:09:30 +02:00
Isaac Connor cc2403924a Use ubuntu2004 for anything other than beowulf 2021-06-14 13:31:46 -04:00
Isaac Connor 94634f1ca7 Spacing 2021-06-14 13:31:05 -04:00
Isaac Connor d221d6ab3b If we fail to suspend/resume, assume we need to disconnect/reconnect to the mmap 2021-06-14 13:30:37 -04:00
Isaac Connor da208457b8 Fix EndTime case handling. 2021-06-14 11:58:23 -04:00
Isaac Connor 0cbb132f08 merge fixes from #3295. Fixes #3295. 2021-06-14 09:52:10 -04:00
Isaac Connor 9001327883 Fix incorrect use of == instead eq 2021-06-14 09:45:08 -04:00
Isaac Connor 821031f10e Remove some debug logging 2021-06-13 18:20:57 -04:00
Isaac Connor fa11c20bf8
Merge pull request #3297 from Carbenium/time-misc
Convert the rest of the codebase to std::chrono
2021-06-13 17:47:40 -04:00
Peter Keresztes Schmidt d69afc9672 misc: Convert time(nullptr) calls to std::chrono 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt 6114d40593 misc: Replace usleep with std::this_thread::sleep_for 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt f675afc3f2 zmc: Convert internals to std::chrono 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt 3e8b10d813 zm::Select: Convert API to std::chrono 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt c823b9c00e Buffer: Convert API to std::chrono 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt 707975e567 Monitor: Convert API to std::chrono 2021-06-13 23:22:49 +02:00
Peter Keresztes Schmidt dff5452f11 Event: Convert API to std::chrono 2021-06-13 23:20:24 +02:00
Peter Keresztes Schmidt 335e950654 Frame: Convert API to std::chrono 2021-06-13 23:20:24 +02:00
Peter Keresztes Schmidt 7c6a6ac309 VideoStream: Convert internals to std::chrono 2021-06-13 23:20:24 +02:00
Peter Keresztes Schmidt ce55ba5fb7 VideoStore: Convert internals to std::chrono 2021-06-13 23:20:22 +02:00
Isaac Connor c2f4d65860 Turn down debugging 2021-06-13 14:08:51 -04:00
Isaac Connor c56025beab Use std::unordered_map instead of std::map for performance. Be slightly more efficicent by storing an interator and using it instead of continually indexing into the std::map. Fix crash when a monitor's mmap file size changes 2021-06-13 14:08:51 -04:00
Isaac Connor 9f8c8a2664 Return early if packetqueue is empty instead of getting the lock. Return early in clear() if we are not initialised 2021-06-13 14:08:51 -04:00
Peter Keresztes Schmidt f374b319e0 RtpSource: Convert internals partially to std::chrono
This allows us to remove the tvNow() helper method.
2021-06-13 16:35:27 +02:00
Peter Keresztes Schmidt 28d813b95a
Merge pull request #3296 from Carbenium/time-image
Image: Convert API to std::chrono
2021-06-13 15:40:18 +02:00
Peter Keresztes Schmidt ff8c9f67c1 Image: Convert API to std::chrono
Utils: Remove TimespecDiff. It is not used anymore
2021-06-13 14:50:16 +02:00
Peter Keresztes Schmidt 1fe30c848d
Merge pull request #3292 from Carbenium/time-eventstream
BaseStream+EventStream: Convert internals to std::chrono
2021-06-13 11:42:14 +02:00
Peter Keresztes Schmidt b2ee71c96e EventStream: Finalize conversion of internals to std::chrono 2021-06-13 11:30:22 +02:00
Peter Keresztes Schmidt e1fe53338c BaseStream: Convert internals to std::chrono 2021-06-13 11:29:59 +02:00
Peter Keresztes Schmidt 8dae46bc75
Merge pull request #3294 from Carbenium/time-monitor
Monitor: Convert internals to std::chrono
2021-06-13 10:40:21 +02:00
Peter Keresztes Schmidt 95dd0c1491 Monitor: Convert internals to std::chrono 2021-06-13 09:58:33 +02:00
Isaac Connor af46f8cad5 Merge an old stash allowing passing an alternate buttonconfig parameter to show/get Modal 2021-06-12 12:22:15 -04:00
Isaac Connor 7878fbc878 Add a limit of 1000 when pulling sessions. Sessions table can contain hundreds of thousands of lines all relatively useless. Modals need to pop up fast. 2021-06-12 12:22:15 -04:00
Isaac Connor 786d0c553e We require sudo 2021-06-12 12:22:15 -04:00
Isaac Connor fd9bef228d It is okay to call daemonControl with function==None for command == stop. All others give a warning. Fixes monitors on other servers not stopping when set to None. 2021-06-12 12:21:44 -04:00
Peter Keresztes Schmidt 07dbb75c56
Merge pull request #3285 from Carbenium/time-event
Convert Event and Logger internals to std::chrono
2021-06-08 23:29:57 +02:00
Isaac Connor 46c730e27b Bump version for 1.36.4 2021-06-08 16:59:03 -04:00
Isaac Connor 268da411d9 Use getStat instead of other jquery code to update the event data. Don't refresh before rename ajax finishes. Deprecate the n/a handling in getStat. Not sure why it's needed. Sync update eventData with what is returned by ajax status call. Fixes #3265 2021-06-08 16:58:51 -04:00
Isaac Connor 4a40214f73 StartTimeShort should be StartDateTimeShort. Leave StartTimeShort for backwards compatibility. Add Storage, DiskSpace in status=>event 2021-06-08 16:58:50 -04:00
Isaac Connor 55f2a7f55e spacing 2021-06-08 16:58:50 -04:00
Isaac Connor 0301011f7e Adjust debug logging 2021-06-08 16:58:50 -04:00
Isaac Connor afecd33879 Use new get_packet_and_increment_it in decoder. Adjust some debugging levels 2021-06-08 16:58:50 -04:00
Isaac Connor 91892c79b1 Remove 25x and options. Browsers do not support them. Add 16x which is the max. Fixes #3284 2021-06-08 16:58:50 -04:00
Isaac Connor 97d077d623 Bump version to 1.36.3 for release 2021-06-08 16:57:20 -04:00
Isaac Connor dbb8019852 Bump version for 1.36.2 2021-06-08 16:55:13 -04:00
Isaac Connor 84035ef4f7 Adjust debug logging 2021-06-08 16:54:41 -04:00
Isaac Connor 3d70e621b2 zmstats.pl: add use warnings. Fix log deletion only ever deleting 100 when it should delete more in a loop. Add deleting more than 100 sessions. Fix loop not terminating on Ctrl-C 2021-06-08 16:54:41 -04:00
Peter Keresztes Schmidt b0b2f5fc16 Logger: Convert internals to std::chrono 2021-06-08 19:45:23 +02:00
Peter Keresztes Schmidt 44ace34593 Event: Convert internals to std::chrono 2021-06-08 19:41:11 +02:00
Peter Keresztes Schmidt 48b1e8a055
Merge pull request #3283 from Carbenium/time-2
Time: Remove defunct timeval methods and DeltaTimeval
2021-06-07 23:59:26 +02:00
Peter Keresztes Schmidt d8d27bcc92 Time: Replace remaining DeltaTimeval usage with std::chrono 2021-06-07 23:53:53 +02:00
Peter Keresztes Schmidt 6c68397249 Time: Convert some timeval operations to std::chrono
Also remove now defunct timeval helper methods.
2021-06-07 23:53:53 +02:00
Peter Keresztes Schmidt 46155942c1 Misc: Rename namespace ZM to zm
We had a mixture of both spellings. Unify it according to our code-style.
2021-06-06 19:11:11 +02:00
Peter Keresztes Schmidt d64b57e63c
Merge pull request #3282 from Carbenium/time
Time: std::chrono compatibility casts and DELTA_TIMEVAL removal
2021-06-06 17:49:55 +02:00
Peter Keresztes Schmidt 7474294ac3 Time: Remove DELTA_TIMEVAL macro and replace usage with proper std::chrono::duration operations 2021-06-06 16:41:36 +02:00
Peter Keresztes Schmidt 129bd3f907
Merge pull request #3281 from SteveGilvarry/Update_Symlink
Update symlink to new file location
2021-06-06 16:11:06 +02:00
Peter Keresztes Schmidt 154b17d5f3 Time: Implement duration_cast from DeltaTimeval to std::chrono::duration
This will allow us to migrate step-by-step from DeltaTimeval to std::chrono.
2021-06-06 15:15:36 +02:00
Peter Keresztes Schmidt 2a32f75a24 Time: Implement duration_cast between timeval and std::chrono::duration
This will allow us to migrate step-by-step from timeval and related types to std::chrono.
2021-06-06 15:15:05 +02:00
Steve Gilvarry b29a785a7c Update symlink to new file location 2021-06-06 17:22:13 +10:00
Peter Keresztes Schmidt 07b81f446f CI: Add CI workflow for Ubuntu Bionic 2021-06-06 00:00:41 +02:00
Peter Keresztes Schmidt f1279a3ebf CI/Cirrus: Install pkgconf on FreeBSD
We need this to detect the FFmpeg version correctly.
2021-06-05 21:50:53 +02:00
Isaac Connor dc6c00ba88
Merge pull request #3280 from Carbenium/drop-xenial
Drop Ubuntu Xenial support
2021-06-05 15:33:13 -04:00
Peter Keresztes Schmidt 0d81199fc9 Build: Require at least FFmpeg 3.2 (libavutil 55.34.100) 2021-06-05 20:40:12 +02:00
Peter Keresztes Schmidt 2d71743372 FFmpeg: Remove code paths required only by 2.8 and older
With Xenial support dropped we require FFmpeg 3.2 and newer.
2021-06-05 20:40:12 +02:00
Isaac Connor f0e5eece18
Merge pull request #3279 from Carbenium/drop-jessie
Docs: Remove references to Debian Jessie
2021-06-05 11:20:28 -04:00
Isaac Connor bbdf01880a
Merge pull request #3278 from Carbenium/ffmpeg-required
Promote FFmpeg libs to a required dependencies
2021-06-05 11:19:50 -04:00
Peter Keresztes Schmidt 73351f4387 Drop Ubuntu Xenial support 2021-06-05 17:16:22 +02:00
Peter Keresztes Schmidt f9d859cad8 Docs: Remove references to Debian Jessie
Jessie is no longer supported by ZM.
2021-06-05 16:03:26 +02:00
Peter Keresztes Schmidt 0625f6ca1c Misc: Cleanup some includes 2021-06-05 15:08:38 +02:00
Peter Keresztes Schmidt 5c96eedac8 Build: Remove dependency on libavdevice
We currently don't use the library so don't depend on it.
2021-06-05 15:08:38 +02:00
Peter Keresztes Schmidt 3d34e6f177 Build: Promote libswresample to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:27:42 +02:00
Peter Keresztes Schmidt 762476ec76 Build: Promote libswscale to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:27:31 +02:00
Peter Keresztes Schmidt a9ad5c5eee Build: Promote libavcodec to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:25:54 +02:00
Peter Keresztes Schmidt 7d15396833 Build: Promote libavformat to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:25:27 +02:00
Peter Keresztes Schmidt 1a6904a297 Build: Promote libavutil to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:21:41 +02:00
Peter Keresztes Schmidt 70c626a30e
Merge pull request #3277 from Carbenium/remove-libavresample
Remove libavresample support
2021-06-05 11:44:50 +02:00
Peter Keresztes Schmidt 0b7f9396b4 FFmpeg: Remove no longer valid includes 2021-06-05 00:24:14 +02:00
Peter Keresztes Schmidt 7d501a6585 Remove libavresample support
libavresample hasn't been maintained for a long time by FFmpeg since libswresample superseded it.
In 2018 it was officially deprecated [1].

Let's remove the support for it since there is no need to maintain this option further.

[1] https://patchwork.ffmpeg.org/project/ffmpeg/patch/20171225175335.18183-1-atomnuker@gmail.com/
2021-06-04 23:46:58 +02:00
Isaac Connor cca30661d7 remove invalid debug 2021-06-04 17:42:00 -04:00
Isaac Connor 9cce9744d2
Merge pull request #3276 from Carbenium/cmake-ffmpeg
Build: Add CMake package module for FFmpeg
2021-06-04 17:35:45 -04:00
Isaac Connor 9f685d6c2b Fixup style and warnings in zm_dump_codecpar 2021-06-04 17:32:45 -04:00
Peter Keresztes Schmidt 32f139ef7f Build: Use FFmpeg package CMake module 2021-06-04 23:18:30 +02:00
Peter Keresztes Schmidt db9b739562 Build: Add CMake package module for FFmpeg 2021-06-04 23:18:30 +02:00
Isaac Connor a78feb739e enable an encoder option to actually open the codec when doing passthrough. This fixes saving the h265. 2021-06-04 16:51:21 -04:00
Isaac Connor b16eb510d0 More debugging around clearQueue. return early if deleting 2021-06-04 15:03:08 -04:00
Isaac Connor 205c488741 spacing 2021-06-04 15:01:57 -04:00
Isaac Connor d713770dea Include more fields in zm_dump_codecpar and zm_dump_codec 2021-06-04 15:01:48 -04:00
Isaac Connor 72d07d1428 Add a bunch of debugging about snapshot writing 2021-06-04 15:00:16 -04:00
Isaac Connor ad0e7a5c1a Use new get_packet_and_increment_it in decoder. Adjust some debugging levels 2021-06-03 18:22:18 -04:00
Isaac Connor fc6202d349 Introduce get_packet_and_increase_it just so we can lose an extra grab lock and function calls, etc. In queuePacket, if the queue is full, WAIT instead of failing to queue. 2021-06-03 18:22:18 -04:00
Isaac Connor 1b67074d35
Merge pull request #3275 from XuluniX/onvifprobe_interface
Fixed bug in onvifprobe interface selection
2021-06-03 10:06:24 -04:00
Xulunix 2cbb24d7b9 Fixed bug in onvifprobe
The arguments for "/usr/bin/zmonvif-probe.pl" was always `probe 1.1,1.2 1` with the last argument always being `1` instead of the network interface name selected in the menu.
This change fixes this issue by using the selected interface name instead of the boolean return value of the `isset()` function.
2021-06-03 02:26:24 +02:00
Isaac Connor e4d3394888 fix missing namespace on warning 2021-06-02 18:35:13 -04:00
Isaac Connor 9a03c2c16a Default to UTC when no timezone set so that montagereview continues working. Fixes #3274 2021-06-02 18:35:13 -04:00
Isaac Connor ed5262432f Fix samsite support for php <= 7.2 2021-06-02 14:59:13 -04:00
Isaac Connor 5529075fb3
Merge pull request #3273 from Carbenium/cmake-cleanup
Build: Remove some unused CMake code
2021-06-01 18:37:37 -04:00
Peter Keresztes Schmidt 0ea14317a4 Build: Remove unused cmakedefines 2021-06-01 23:54:49 +02:00
Peter Keresztes Schmidt 7ec37405a6 Build: Don't include unused CheckStructHasMember module 2021-06-01 08:43:49 +02:00
Peter Keresztes Schmidt e724a93395 Build: Remove in-tree version of CheckPrototypeDefinition
We currently don't use the module and all supported CMake versions ship this module if needed.
2021-06-01 08:41:44 +02:00
Isaac Connor bc3d1d161a
Merge pull request #3270 from Carbenium/remove-v4l1
Remove support for V4L1
2021-05-31 18:52:07 -04:00
Peter Keresztes Schmidt 81a1546a2b LocalCamera: Remove unnecessary ZM_HAS_V4L2 conditionals
V4L2 is the only V4L version we support. No need to conditionally compile those parts.
2021-06-01 00:05:05 +02:00
Peter Keresztes Schmidt f2bee0704a LocalCamera: Remove support for V4L1
Kernel support for Video4Linux 1 was removed in 2.6.38 (March 2011). It's time to drop support on our side.
2021-05-31 23:29:29 +02:00
Peter Keresztes Schmidt ed7759897b misc: Move ZM_HAS_* defines to zoneminder-config.cmake 2021-05-31 23:29:29 +02:00
Isaac Connor f8b779dc25 fix crash when in alert state with no event 2021-05-31 16:02:42 -04:00
Isaac Connor cc3bce48b7 hevc requires an open codec to set stream parameters right. Fixes garbage video when h265 passthrough 2021-05-31 16:00:17 -04:00
Isaac Connor c686fa5949 SHould reset state as well as shared_data->state 2021-05-31 16:00:17 -04:00
Isaac Connor d2941d6b87 Always print SAR and tel about unknown codec type 2021-05-31 16:00:17 -04:00
Isaac Connor 50fe7100fa Remove the code to do adaptive skipping. We should never sleep when doing Analysis unless an error occurred. 2021-05-31 12:52:24 -04:00
Isaac Connor 4825370a7f Apply height css to limit height of logout modal and apply overflow:auto to add a scrollbar if needed so that we don't have to scroll to logout. 2021-05-31 10:19:58 -04:00
Isaac Connor 0bcb30b8a9 Don't print out buffer since it isn't zero terminated 2021-05-31 10:19:58 -04:00
Isaac Connor fd21edb7a9
Merge pull request #3268 from Carbenium/remove-travis
CI: Remove Travis CI
2021-05-30 18:36:25 -04:00
Peter Keresztes Schmidt f3cb14cc17 CI: Remove Travis CI
All our CI needs are handled by GitHub Actions
2021-05-31 00:15:00 +02:00
Peter Keresztes Schmidt 764f10bf82 CI: Run packpack for Buster on GitHub Actions 2021-05-31 00:14:10 +02:00
Isaac Connor 4f2945bd57
Merge pull request #3267 from Carbenium/crypto-hashing
Crypto: Implement a generic hashing API
2021-05-30 18:07:58 -04:00
Peter Keresztes Schmidt fead79185b CI: Run ESLint job with GitHub Actions 2021-05-30 23:36:19 +02:00
Isaac Connor dab2792077
Merge pull request #3262 from Carbenium/selectable-crypto-backend
Build: Make crypto and JWT backends selectable
2021-05-30 17:06:22 -04:00
Peter Keresztes Schmidt 8129600a37 Build: Cleanup gnutls/openssl defines
We only need HAVE_LIBGNUTLS and HAVE_LIBOPENSSL to compile the right crypto backend.
2021-05-30 22:56:21 +02:00
Peter Keresztes Schmidt 5d93555d9f Crypto: Use new hashing API 2021-05-30 22:56:21 +02:00
Peter Keresztes Schmidt 9a983bb321 Crypto: Implement SHA1 hashing 2021-05-30 22:56:21 +02:00
Peter Keresztes Schmidt 8b87830e3e Use the new ByteArrayToHexString helper 2021-05-30 22:53:05 +02:00
Peter Keresztes Schmidt d2932b5d68 Utils: Add a ByteArrayToHexString helper 2021-05-30 22:53:05 +02:00
Peter Keresztes Schmidt 62f60b76d6 rtsp_auth/Authenticator: Convert to new hashing API 2021-05-30 22:53:05 +02:00
Peter Keresztes Schmidt 837b32ccff User: Convert to new hashing API 2021-05-30 22:53:05 +02:00
Peter Keresztes Schmidt 2bda413698 Crypto: Implement a generic hashing API
Currently MD5 is implemented
2021-05-30 22:53:05 +02:00
Peter Keresztes Schmidt a8b9d15d1b Utils: Add our own ASSERT macro
Using `assert` from `<cassert>` leads to unused variable warnings in release builds.
Define the `ASSERT` macro which compiles to a no-op in release builds but still avoids
the warnings.
2021-05-30 21:41:58 +02:00
Isaac Connor 28a6a3e41e the filename is incorrect so the tmpfiles.d configuration is not being included 2021-05-30 10:54:23 -04:00
Peter Keresztes Schmidt e34b6500d9 Utils: Add implementations for std::data and std::size
These can be removed once C++17 is supported.
2021-05-29 21:37:38 +02:00
Peter Keresztes Schmidt b8178dbb79 CI: Build possible crypto/jwt backend combinations 2021-05-29 21:37:30 +02:00
Peter Keresztes Schmidt 45654cb514 Build: Make the JWT backend selectable
Introduce the -DZM_JWT_BACKEND CMake option through which the JWT backend can be selected.
Supported values: jwt_cpp (default; in-tree) and libjwt

When libjwt is chosen ZM_CRYPTO_BACKEND is taken into account to select the corresponding flavour of libjwt.
2021-05-29 21:37:30 +02:00
Peter Keresztes Schmidt caadc41bfd Build: Make the crypto backend selectable
Introduce the -DZM_CRYPTO_BACKEND CMake option through which the crypto backend can be selected.
Supported values: openssl (default) and gnutls

This commit makes OpenSSL or GnuTLS a requirement to compile/run ZoneMinder.

Following restriction applies:
  * If libjwt is not found we fall back to jwt-cpp which only supports OpenSSL
2021-05-29 21:37:30 +02:00
Peter Keresztes Schmidt b81689aa3f Remove libgcrypt as dependency
GnuTLS used gcrypt as backend but switched in ~2011 to nettle.
Thus we don't need to/shouldn't depend on it.
2021-05-29 21:37:30 +02:00
Isaac Connor 2e61ee4c95
Merge pull request #3266 from Carbenium/fill-out-of-bounds
Image: Remove std::vector out-of-bounds access when filling polygons
2021-05-29 15:05:19 -04:00
Peter Keresztes Schmidt 339cfd49bc Image: Remove std::vector out-of-bounds access when filling polygons
While iterating through `active_edges` we call `std::next`. If the current
iterator is `.end()` we are accessing out-of-bound memory.
Make sure we always have a valid iterator past `it` in the loop.

Follow-up on 6642ca4515
2021-05-29 19:58:19 +02:00
Peter Keresztes Schmidt e8adf5d331 Build: Enable std::vector ASAN annotation in libstdc++
By defining _GLIBCXX_SANITIZE_VECTOR when ASAN is enabled `std::vector` operations
will be annotated so ASAN can detect invalid accesses.

See https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_macros.html
2021-05-29 19:55:17 +02:00
Isaac Connor 09b0353592 Actually close the camera in localcamera::Close 2021-05-28 13:54:20 -04:00
Isaac Connor 855a81b975 Merge branch 'release-1.36' 2021-05-28 12:29:35 -04:00
Isaac Connor 096581b7f1 add getMonitorStatuses function to return string values for status numbers 2021-05-28 12:29:30 -04:00
Isaac Connor 8511d814df Restore api behaviour. Add zmu output to response 2021-05-28 12:28:35 -04:00
Isaac Connor 195f9fc403 simplify test for being decoded. timestamping needs to be done as well 2021-05-28 11:38:48 -04:00
Isaac Connor 7417d32fbc Add a 5 second timeout when setting suspending/resuming motion detection.Log errors appropriately 2021-05-28 10:29:44 -04:00
Isaac Connor 16cc69ca2b Change SQL to add Controls for ONVIF camera, Foscam 9831W and 8918W to specify columns so that if other columns are present the sql still executes. Fixes #3260 2021-05-28 10:23:42 -04:00
Isaac Connor c590157431 Fix version reverted 1.36.1 due to merge from release-136 2021-05-27 20:01:11 -04:00
Peter Keresztes Schmidt 8379ab70be Build: Disable Wstringop-truncation in GCC ASAN builds
These two options don't work well together and lead to false positives.

Follow-up on e5cac38521
2021-05-28 00:08:46 +02:00
Isaac Connor 824a6dc15b Merge branch 'release-1.36' 2021-05-25 13:17:26 -04:00
Isaac Connor 799a0ed7ba
Merge pull request #3254 from bestlong/add-lang
web ui add lang (Chinese Traditional)
2021-05-25 13:12:34 -04:00
Isaac Connor 82c7474786
Merge pull request #3257 from Carbenium/ffmpeg-stretch
FfmpegCamera/Videostore: Disable hwaccel for ffmpeg found in Debian Stretch
2021-05-25 13:12:17 -04:00
Isaac Connor a266388898
Merge pull request #3255 from anon8675309/gitlab-ci
Enable gitlab CI to build debian packages
2021-05-25 13:08:58 -04:00
Isaac Connor 6e70eb5963
Merge pull request #3259 from gerazo/master
Updated Hungarian translation
2021-05-25 13:08:00 -04:00
Zoltan Gera 714dd0aa9f Updated Hungarian translation 2021-05-25 18:15:40 +02:00
Isaac Connor cf03bb9548 Merge branch 'release-1.36' 2021-05-25 11:34:11 -04:00
Isaac Connor 9e64b912a8 Add samesite when setting cookie for skin and css 2021-05-25 11:33:28 -04:00
Peter Keresztes Schmidt 6b478484bd CI: Add workflow for Debian Bullseye 2021-05-25 07:41:39 +02:00
Peter Keresztes Schmidt d413f3c78f FfmpegCamera/Videostore: Disable hwaccel for ffmpeg found in Debian Stretch
The av_hwdevice_* API is not complete in 3.2. Enable hwaccel from 3.4 onwards.
2021-05-24 23:20:30 +02:00
Peter Keresztes Schmidt 8a8dc48206 CI: Add CI workflow for Debian Stretch 2021-05-24 22:03:43 +02:00
Peter Keresztes Schmidt 9f4e7178d4 CI: Add CI workflow for Debian Buster 2021-05-24 21:53:42 +02:00
Peter Keresztes Schmidt 0392828ef8
Merge pull request #3256 from Carbenium/ci-centos
CI: Run on CentOS 7 and 8
2021-05-24 09:17:47 +02:00
Peter Keresztes Schmidt e232b5d1a7 Build: Disable Wmissing-field-initializers on older GCC versions
GCC 5.1 corrected the behaviour in regard that the C++11 initialisation behaviour is respected.
2021-05-24 01:15:00 +02:00
Peter Keresztes Schmidt 9900fc1273 tests/Font: Avoid lambda capture initialization
Remove the use of this language feature until we raise the requirements to C++14.
2021-05-24 00:55:46 +02:00
Peter Keresztes Schmidt e5cac38521 Comms: Make sure sun_path is NUL-terminated
When using strncpy the NUL-termination can go missing if the string to be copied is longer than the buffer.
Make sure the last character in the buffer is NUL.
If this really happens, the error (non-existing path due to truncation) will be caught during bind-ing.

Fixes the following warning:
/home/peterke/DEV/zoneminder/src/zm_comms.cpp: In member function ‘bool ZM::SockAddrUnix::resolve(const char*, const char*)’:
/home/peterke/DEV/zoneminder/src/zm_comms.cpp:207:10: warning: ‘char* strncpy(char*, const char*, size_t)’ specified bound 108 equals destination size [-Wstringop-truncation]
  207 |   strncpy(mAddrUn.sun_path, path, sizeof(mAddrUn.sun_path));
      |   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2021-05-24 00:44:15 +02:00
Peter Keresztes Schmidt 93abbdf964 CI: Run on CentOS 7 and 8 2021-05-24 00:20:42 +02:00
Shao Yu-Lung (Allen) 4a1d983ff1 web ui add lang (Chinese Traditional) 2021-05-24 00:05:59 +08:00
anon8675309 b2391e952f Enable gitlab CI to build debian packages 2021-05-23 01:45:07 -05:00
Isaac Connor 317ce7692e fix behaviour of reverse and fast forward buttons. Fixes #3251 2021-05-22 13:38:52 -04:00
Isaac Connor bc384d6fbe spacing, code style, code comments 2021-05-22 11:34:09 -04:00
Andrew Bauer 2e12bc08cd add 1.37 changelog entry to rpm specfile 2021-05-22 06:58:44 -05:00
Andrew Bauer 8d8b87743e sync rpm specfile changelog with rpmfusion 2021-05-22 06:55:52 -05:00
Peter Keresztes Schmidt e881e97c06 Logger: Fix DB log messages not being populated
We need to `resize` the buffer string since `reserve` does not guarantee that the buffer is
actually available.

Follow-up on 298415fff3
2021-05-22 10:52:57 +02:00
Andrew Bauer eb387b5453 use latest rtspserver commit 2021-05-21 15:08:40 -05:00
Isaac Connor da8128aba1 Merge branch 'master' into add_manufacturer_model_to_monitors 2021-05-07 19:16:35 -04:00
Peter Keresztes Schmidt e18750bb79 logger: Pass std::string as ID during logInit 2021-03-01 22:43:02 +01:00
Peter Keresztes Schmidt 6dc132df27 zmc: Use fmt to construct the log ID 2021-03-01 22:43:02 +01:00
Peter Keresztes Schmidt 589e5fec26 zms: Use fmt to construct the log ID 2021-03-01 22:43:02 +01:00
Peter Keresztes Schmidt 1a6b26f2ab build: Add fmt as a required dependency 2021-03-01 22:43:02 +01:00
Isaac Connor f4ce2c1ea4 Merge branch 'release-1.34' 2021-02-03 12:22:17 -05:00
Isaac Connor fa34d00392 Add object classes for Manufacturer and Model 2020-10-11 09:57:51 -04:00
Isaac Connor a6de3e15f4 AddManufacturerId and ModelId to Monitor view 2020-10-11 09:57:08 -04:00
Isaac Connor aa157bfd78 AddManufacturerId and ModelId to Monitors 2020-10-11 09:56:35 -04:00
Isaac Connor b788c432d4 Split the data by monitor and display a monitor image/info for each monitor. 2020-01-05 17:33:36 -05:00
Isaac Connor 2854f8e002 simplify some code, pass around zm_event json objects instead of event_id. Each monitor has it's own image so when loading event data put it into a div/img referenced by monitor Id 2020-01-05 17:32:27 -05:00
Isaac Connor 377805dce0 convert some tags to classes instead of ids. Add margin: 0 auto so that monitor images are centered 2020-01-05 17:30:51 -05:00
418 changed files with 15369 additions and 12897 deletions

View File

@ -1,17 +1,19 @@
task:
name: freebsd-build
freebsd_instance:
image_family: freebsd-12-2
matrix:
- image_family: freebsd-12-2
- image_family: freebsd-13-0
prepare_script:
- pkg install -yq git cmake jpeg-turbo mysql80-client ffmpeg libvncserver libjwt catch p5-DBI p5-DBD-mysql p5-Date-Manip p5-Test-LWP-UserAgent p5-Sys-Mmap
- pkg install -yq git cmake pkgconf jpeg-turbo mysql80-client ffmpeg libvncserver libjwt catch p5-DBI p5-DBD-mysql p5-Date-Manip p5-Test-LWP-UserAgent p5-Sys-Mmap v4l_compat
configure_script:
- git submodule update --init --recursive
- mkdir build
- cd build
- cmake --version
- cmake ../ -DBUILD_MAN=0 -DBUILD_TEST_SUITE=1 -DENABLE_WERROR=1
- cmake ../ -DBUILD_MAN=0 -DBUILD_TEST_SUITE=1 -DENABLE_WERROR=1 -DCMAKE_C_FLAGS="-Wno-deprecated-declarations" -DCMAKE_CXX_FLAGS="-Wno-deprecated-declarations"
build_script:
- cd build

View File

@ -4,7 +4,8 @@
web/api/lib
web/includes/csrf/
web/js/videojs.zoomrotate.js
web/skins/classic/js/bootstrap.js
web/skins/classic/js/bootstrap-4.5.0.js
web/skins/classic/js/bootstrap.bundle.min.js
web/skins/classic/js/chosen
web/skins/classic/js/dateTimePicker
web/skins/classic/js/jquery-*.js
@ -13,6 +14,8 @@ web/skins/classic/js/jquery.js
web/skins/classic/js/moment.js
web/skins/classic/js/video.js
web/tools/mootools
web/js/janus.js
web/js/ajaxQueue.js
# Cannot be parsed as JS
web/skins/classic/includes/export_functions.php

View File

@ -3,7 +3,7 @@
module.exports = {
"env": {
"browser": true,
"es6": true,
"es2017": true,
},
"extends": ["google"],
"overrides": [{

2
.github/FUNDING.yml vendored
View File

@ -2,7 +2,7 @@
github: [connortechnology,pliablepixels] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: zoneminder # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
open_collective: zoneminder # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry

51
.github/workflows/ci-bionic.yml vendored Normal file
View File

@ -0,0 +1,51 @@
name: CI Ubuntu Bionic (18.04)
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
defaults:
run:
shell: bash
strategy:
matrix:
crypto_backend: [ openssl ]
jwt_backend: [ libjwt, jwt_cpp ]
include:
- crypto_backend: openssl
crypto_package: libssl-dev
jwt_package: libjwt-dev
runs-on: ubuntu-latest
container: ubuntu:bionic
steps:
- name: Update packages
run: apt-get -qq update && apt-get -qq upgrade && apt-get -qq install software-properties-common
- name: Install git
run: |
add-apt-repository ppa:git-core/ppa
apt-get -qq update
apt-get -qq install git
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: >
apt-get -qq install make cmake g++
default-libmysqlclient-dev
libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev
libcurl4-gnutls-dev libvlc-dev libvncserver-dev
libdate-manip-perl libdbd-mysql-perl libsys-mmap-perl libwww-perl
libpolkit-gobject-1-dev
${{ matrix.crypto_package }} ${{ matrix.jwt_package }}
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DENABLE_WERROR=1 -DZM_CRYPTO_BACKEND=${{ matrix.crypto_backend }} -DZM_JWT_BACKEND=${{ matrix.jwt_backend }}
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})

57
.github/workflows/ci-bullseye.yml vendored Normal file
View File

@ -0,0 +1,57 @@
name: CI Debian Bullseye
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
defaults:
run:
shell: bash
strategy:
matrix:
crypto_backend: [ gnutls, openssl ]
jwt_backend: [ libjwt, jwt_cpp ]
include:
- crypto_backend: gnutls
crypto_package: libgnutls28-dev
jwt_package: libjwt-gnutls-dev
- crypto_backend: openssl
crypto_package: libssl-dev
jwt_package: libjwt-dev
exclude:
- crypto_backend: gnutls
jwt_backend: jwt_cpp
runs-on: ubuntu-latest
container: debian:bullseye
steps:
- name: Update packages
run: apt-get -qq update && apt-get -qq upgrade
- name: Install git
run: apt-get -qq install git
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: >
apt-get -qq install make cmake g++
default-libmysqlclient-dev
libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev
libcurl4-gnutls-dev libvlc-dev libvncserver-dev
libdate-manip-perl libdbd-mysql-perl libsys-mmap-perl libwww-perl
libpolkit-gobject-1-dev
catch2
${{ matrix.crypto_package }} ${{ matrix.jwt_package }}
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DBUILD_TEST_SUITE=1 -DENABLE_WERROR=1 -DZM_CRYPTO_BACKEND=${{ matrix.crypto_backend }} -DZM_JWT_BACKEND=${{ matrix.jwt_backend }}
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})
- name: Run tests
run: cd build/tests && ./tests "~[notCI]"

54
.github/workflows/ci-buster.yml vendored Normal file
View File

@ -0,0 +1,54 @@
name: CI Debian Buster
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
defaults:
run:
shell: bash
strategy:
matrix:
crypto_backend: [ gnutls, openssl ]
jwt_backend: [ libjwt, jwt_cpp ]
include:
- crypto_backend: gnutls
crypto_package: libgnutls28-dev
jwt_package: libjwt-gnutls-dev
- crypto_backend: openssl
crypto_package: libssl-dev
jwt_package: libjwt-dev
exclude:
- crypto_backend: gnutls
jwt_backend: jwt_cpp
runs-on: ubuntu-latest
container: debian:buster
steps:
- name: Update packages
run: apt-get -qq update && apt-get -qq upgrade
- name: Install git
run: apt-get -qq install git
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: >
apt-get -qq install make cmake g++
default-libmysqlclient-dev
libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev
libcurl4-gnutls-dev libvlc-dev libvncserver-dev
libdate-manip-perl libdbd-mysql-perl libsys-mmap-perl libwww-perl
libpolkit-gobject-1-dev
${{ matrix.crypto_package }} ${{ matrix.jwt_package }}
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DENABLE_WERROR=1 -DZM_CRYPTO_BACKEND=${{ matrix.crypto_backend }} -DZM_JWT_BACKEND=${{ matrix.jwt_backend }}
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})

39
.github/workflows/ci-centos-7.yml vendored Normal file
View File

@ -0,0 +1,39 @@
name: CI CentOS 7
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
strategy:
matrix:
crypto_backend: [ gnutls, openssl ]
jwt_backend: [ libjwt, jwt_cpp ]
exclude:
- crypto_backend: gnutls
jwt_backend: jwt_cpp
- crypto_backend: gnutls
jwt_backend: libjwt
runs-on: ubuntu-latest
container: centos:7
steps:
- name: Enable RPMFusion and EPEL
run: yum -y install https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-7.noarch.rpm https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
- name: Install git
run: yum -y install https://repo.ius.io/ius-release-el7.rpm && yum -y install git224
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: yum -y update && yum -y install make cmake3 gcc-c++ mariadb-devel ffmpeg-devel libcurl-devel vlc-devel libvncserver-devel libjpeg-turbo-devel "perl(Date::Manip)" "perl(DBD::mysql)" "perl(ExtUtils::MakeMaker)" "perl(Sys::Mmap)" "perl(Sys::Syslog)" "perl(LWP::UserAgent)" polkit-devel libjwt-devel
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake3 --version && cmake3 .. -DBUILD_MAN=0 -DENABLE_WERROR=1 -DZM_CRYPTO_BACKEND=${{ matrix.crypto_backend }} -DZM_JWT_BACKEND=${{ matrix.jwt_backend }}
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})

41
.github/workflows/ci-centos-8.yml vendored Normal file
View File

@ -0,0 +1,41 @@
name: CI CentOS 8
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
strategy:
matrix:
crypto_backend: [ gnutls, openssl ]
jwt_backend: [ libjwt, jwt_cpp ]
exclude:
- crypto_backend: gnutls
jwt_backend: jwt_cpp
- crypto_backend: gnutls
jwt_backend: libjwt
runs-on: ubuntu-latest
container: rockylinux:8
steps:
- name: Enable RPMFusion, EPEL and PowerTools
run: yum -y install "dnf-command(config-manager)" https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && yum config-manager --set-enabled powertools
- name: Install git
run: yum -y install git
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: yum -y update && yum -y install make cmake gcc-c++ catch-devel mariadb-devel ffmpeg-devel libcurl-devel vlc-devel libvncserver-devel libjpeg-turbo-devel "perl(Date::Manip)" "perl(DBD::mysql)" "perl(ExtUtils::MakeMaker)" "perl(Sys::Mmap)" "perl(Sys::Syslog)" "perl(LWP::UserAgent)" polkit-devel libjwt-devel
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DBUILD_TEST_SUITE=1 -DENABLE_WERROR=1 -DZM_CRYPTO_BACKEND=${{ matrix.crypto_backend }} -DZM_JWT_BACKEND=${{ matrix.jwt_backend }}
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})
- name: Run tests
run: cd build/tests && ./tests "~[notCI]"

21
.github/workflows/ci-eslint.yml vendored Normal file
View File

@ -0,0 +1,21 @@
name: CI ESLint
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
eslint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install ESLint
run: npm install eslint@8.7.0 eslint-config-google@0.14.0 eslint-plugin-html@6.2.0 eslint-plugin-php-markup@6.0.0
- name: Run ESLint
run: npx eslint --ext .php,.js .

41
.github/workflows/ci-stretch.yml vendored Normal file
View File

@ -0,0 +1,41 @@
name: CI Debian Stretch
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
defaults:
run:
shell: bash
runs-on: ubuntu-latest
container: debian:stretch-backports
steps:
- name: Update packages
run: apt-get -qq update && apt-get -qq upgrade
- name: Install git
run: apt-get -qq install git/stretch-backports git-man/stretch-backports
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: >
apt-get -qq install make cmake g++
default-libmysqlclient-dev
libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev libavdevice-dev
libcurl4-gnutls-dev libvlc-dev libvncserver-dev
libdate-manip-perl libdbd-mysql-perl libsys-mmap-perl libwww-perl
libpolkit-gobject-1-dev
libssl-dev
libgsoap-dev
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DENABLE_WERROR=1
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})

View File

@ -1,25 +0,0 @@
name: CI Xenial
on:
push:
branches:
- '*'
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-16.04
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install libavdevice-dev libcurl4-gnutls-dev libvlc-dev libvncserver-dev libdate-manip-perl libdbd-mysql-perl libsys-mmap-perl libpolkit-gobject-1-dev
- name: Prepare
run: mkdir build
- name: Configure
run: cd build && cmake --version && cmake .. -DBUILD_MAN=0 -DENABLE_WERROR=1
- name: Build
run: cd build && make -j3 | grep --line-buffered -Ev '^(cp lib\/|Installing.+\.pm)' && (exit ${PIPESTATUS[0]})

View File

@ -52,8 +52,8 @@ jobs:
git submodule init
git submodule update --init --recursive
sudo apt-get update
sudo apt-get install libavdevice-dev libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev libjwt-gnutls-dev
sudo apt-get install libbz2-dev libgcrypt20-dev libcurl4-gnutls-dev libjpeg-turbo8-dev libturbojpeg0-dev
sudo apt-get install libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev libjwt-gnutls-dev
sudo apt-get install libbz2-dev libcurl4-gnutls-dev libjpeg-turbo8-dev libturbojpeg0-dev
sudo apt-get install default-libmysqlclient-dev libpcre3-dev libpolkit-gobject-1-dev libv4l-dev libvlc-dev
sudo apt-get install libdate-manip-perl libdbd-mysql-perl libphp-serialization-perl libsys-mmap-perl
sudo apt-get install libwww-perl libdata-uuid-perl libssl-dev libcrypt-eksblowfish-perl libdata-entropy-perl

41
.github/workflows/create-packages.yml vendored Normal file
View File

@ -0,0 +1,41 @@
name: Create packages
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
package:
strategy:
matrix:
os_dist:
- os: debian
dist: buster
- os: debian
dist: bullseye
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: '0'
submodules: recursive
- name: Run packpack
env:
SMPFLAGS: -j4
OS: ${{ matrix.os_dist.os }}
DIST: ${{ matrix.os_dist.dist }}
DOCKER_REPO: iconzm/packpack
run: utils/packpack/startpackpack.sh
- name: Publish
uses: easingthemes/ssh-deploy@main
env:
SSH_PRIVATE_KEY: ${{ secrets.ZMREPO_SSH_KEY }}
ARGS: "-rltgoDzvO"
SOURCE: build/
REMOTE_HOST: ${{ secrets.ZMREPO_HOST }}
REMOTE_USER: ${{ secrets.ZMREPO_SSH_USER }}
TARGET: debian/master/mini-dinstall/incoming/

1
.gitignore vendored
View File

@ -124,6 +124,7 @@ src/zmc
src/zmf
src/zms
src/zmu
src/zm_rtsp_server
src/zoneminder-zmc.8
src/zoneminder-zmc.8.gz
src/zoneminder-zmf.8

18
.gitlab-ci.yml Normal file
View File

@ -0,0 +1,18 @@
default:
image:
name: ubuntu:latest
before_script:
- apt-get update -yq
- DEBIAN_FRONTEND=noninteractive apt-get install -yq devscripts sudo
deb:
stage: build
tags:
- docker
script:
- yes "" | ./utils/do_debian_package.sh --snapshot=stable --type=binary --interactive=no --dput=no --debbuild-extra=--no-sign || true
timeout: 2h
artifacts:
paths:
- '*.deb'
expire_in: 1 week

9
.readthedocs.yaml Normal file
View File

@ -0,0 +1,9 @@
version: 2
build:
os: "ubuntu-20.04"
tools:
python: "3.8"
sphinx:
fail_on_warning: true

View File

@ -1,58 +0,0 @@
language: cpp
sudo: required
dist: bionic
git:
depth: 9999999
notifications:
irc: chat.freenode.net#zoneminder-dev
branches:
except:
- modern
cache: ccache
addons:
ssh_known_hosts: zmrepo.zoneminder.com
apt:
sources:
- sourceline: ppa:iconnor/zoneminder-master
- key_url: http://keyserver.ubuntu.com:11371/pks/lookup?op=get&search=0x4D0BF748776FFB04
packages:
- gdebi
- yum-utils
- patch
- git
- curl
- sshfs
- sed
- binfmt-support
- qemu
- qemu-user-static
- dnsutils
- traceroute
install:
- update-binfmts --enable qemu-arm
env:
- SMPFLAGS=-j4 OS=eslint DIST=eslint
- SMPFLAGS=-j4 OS=ubuntu DIST=bionic DOCKER_REPO=iconzm/packpack
compiler:
- gcc
services:
- mysql
- docker
script:
- utils/packpack/startpackpack.sh
before_deploy:
- openssl aes-256-cbc -K $encrypted_62a62750aa73_key -iv $encrypted_62a62750aa73_iv -in ./utils/packpack/deploy_rsa.enc -out /tmp/deploy_rsa -d
- eval "$(ssh-agent -s)"
- chmod 600 /tmp/deploy_rsa
- ssh-add /tmp/deploy_rsa
deploy:
provider: script
skip_cleanup: true
script: utils/packpack/rsync_xfer.sh
on:
branch: master

View File

@ -69,9 +69,7 @@ include(GNUInstallDirs)
include(CheckIncludeFile)
include(CheckIncludeFiles)
include(CheckFunctionExists)
include(CheckPrototypeDefinition_fixed)
include(CheckTypeSize)
include(CheckStructHasMember)
include(CheckSendfile)
# Configuration options
@ -85,6 +83,7 @@ mark_as_advanced(
ZM_TARGET_DISTRO
ZM_PATH_MAP
ZM_PATH_ARP
ZM_PATH_ARP_SCAN
ZM_CONFIG_DIR
ZM_CONFIG_SUBDIR
ZM_SYSTEMD
@ -147,6 +146,8 @@ set(ZM_PATH_MAP "/dev/shm" CACHE PATH
"Location to save mapped memory files, default: /dev/shm")
set(ZM_PATH_ARP "" CACHE PATH
"Full path to compatible arp binary. Leave empty for automatic detection.")
set(ZM_PATH_ARP_SCAN "" CACHE PATH
"Full path to compatible scan_arp binary. Leave empty for automatic detection.")
set(ZM_CONFIG_DIR "/${CMAKE_INSTALL_SYSCONFDIR}" CACHE PATH
"Location of ZoneMinder configuration, default system config directory")
set(ZM_CONFIG_SUBDIR "${ZM_CONFIG_DIR}/conf.d" CACHE PATH
@ -169,6 +170,8 @@ set(ZM_NO_X10 "OFF" CACHE BOOL
set(ZM_ONVIF "ON" CACHE BOOL
"Set to ON to enable basic ONVIF support. This is EXPERIMENTAL and may not
work with all cameras claiming to be ONVIF compliant. default: ON")
set(ZM_NO_PCRE "OFF" CACHE BOOL
"Set to ON to skip libpcre3 checks and force building ZM without libpcre3. default: OFF")
set(ZM_NO_RTSPSERVER "OFF" CACHE BOOL
"Set to ON to skip building ZM with rtsp server support. default: OFF")
set(ZM_PERL_MM_PARMS INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 CACHE STRING
@ -192,6 +195,24 @@ set(ZM_MANPAGE_DEST_PREFIX "share/man" CACHE PATH
set(ZM_CAKEPHP_CACHE "Apc" CACHE STRING
"Set the CakePHP cache engine, default: Apc")
# Supported crypto backends. Using OpenSSL by default to be compatible with jwt-cpp.
set(ZM_CRYPTO_BACKEND_OPTIONS gnutls openssl)
set(ZM_CRYPTO_BACKEND openssl CACHE STRING "Determines which crypto backend should be used.")
set_property(CACHE ZM_CRYPTO_BACKEND PROPERTY STRINGS ${ZM_CRYPTO_BACKEND_OPTIONS})
if(NOT ZM_CRYPTO_BACKEND IN_LIST ZM_CRYPTO_BACKEND_OPTIONS)
message(FATAL_ERROR "Invalid value for ZM_CRYPTO_BACKEND. Possible options: ${ZM_CRYPTO_BACKEND_OPTIONS}")
endif()
# Supported JWT backends. Using jwt-cpp as default.
set(ZM_JWT_BACKEND_OPTIONS libjwt jwt_cpp)
set(ZM_JWT_BACKEND jwt_cpp CACHE STRING "Determines which JWT backend should be used.")
set_property(CACHE ZM_JWT_BACKEND PROPERTY STRINGS ${ZM_JWT_BACKEND_OPTIONS})
if(NOT ZM_JWT_BACKEND IN_LIST ZM_JWT_BACKEND_OPTIONS)
message(FATAL_ERROR "Invalid value for ZM_JWT_BACKEND. Possible options: ${ZM_JWT_BACKEND_OPTIONS}")
endif()
# Reassign some variables if a target distro has been specified
if(ZM_TARGET_DISTRO MATCHES "^fc")
set(ZM_CAKEPHP_CACHE "Memcached")
@ -252,11 +273,6 @@ if(ZM_SYSTEMD OR (IS_DIRECTORY /usr/lib/systemd/system) OR (IS_DIRECTORY /lib/sy
endif()
# System checks
check_include_file("libv4l1-videodev.h" HAVE_LIBV4L1_VIDEODEV_H)
if(NOT HAVE_LIBV4L1_VIDEODEV_H)
check_include_file("linux/videodev.h" HAVE_LINUX_VIDEODEV_H)
endif()
check_include_file("linux/videodev2.h" HAVE_LINUX_VIDEODEV2_H)
check_include_file("execinfo.h" HAVE_EXECINFO_H)
if(HAVE_EXECINFO_H)
check_function_exists("backtrace" HAVE_DECL_BACKTRACE)
@ -305,10 +321,10 @@ endif()
# Do not check for cURL if ZM_NO_CURL is on
if(NOT ZM_NO_CURL)
# cURL
find_package(CURL)
find_package(CURL REQUIRED)
if(CURL_FOUND)
set(HAVE_LIBCURL 1)
#list(APPEND ZM_BIN_LIBS ${CURL_LIBRARIES})
list(APPEND ZM_BIN_LIBS ${CURL_LIBRARIES})
include_directories(${CURL_INCLUDE_DIRS})
set(CMAKE_REQUIRED_INCLUDES ${CURL_INCLUDE_DIRS})
check_include_file("curl/curl.h" HAVE_CURL_CURL_H)
@ -336,19 +352,20 @@ else()
"ZoneMinder requires jpeg but it was not found on your system")
endif()
# LIBJWT
find_package(LibJWT)
if(LIBJWT_FOUND)
set(HAVE_LIBJWT 1)
set(optlibsfound "${optlibsfound} LIBJWT")
list(APPEND ZM_BIN_LIBS "${LIBJWT_LIBRARY}")
else()
set(optlibsnotfound "${optlibsnotfound} LIBJWT")
# libjwt
if (${ZM_JWT_BACKEND} STREQUAL "libjwt")
find_package(LibJWT REQUIRED COMPONENTS ${ZM_CRYPTO_BACKEND})
if(LIBJWT_FOUND)
set(HAVE_LIBJWT 1)
set(optlibsfound "${optlibsfound} LIBJWT")
else()
set(optlibsnotfound "${optlibsnotfound} LIBJWT")
endif()
endif()
# gnutls (using find_library and find_path)
if(HAVE_LIBJWT)
find_library(GNUTLS_LIBRARIES gnutls)
# GnuTLS
if (${ZM_CRYPTO_BACKEND} STREQUAL "gnutls")
find_library(GNUTLS_LIBRARIES gnutls REQUIRED)
if(GNUTLS_LIBRARIES)
set(HAVE_LIBGNUTLS 1)
list(APPEND ZM_BIN_LIBS "${GNUTLS_LIBRARIES}")
@ -358,23 +375,18 @@ if(HAVE_LIBJWT)
set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE GNUTLS_LIBRARIES GNUTLS_INCLUDE_DIR)
check_include_file("gnutls/gnutls.h" HAVE_GNUTLS_GNUTLS_H)
set(optlibsfound "${optlibsfound} GnuTLS")
else()
set(optlibsnotfound "${optlibsnotfound} GnuTLS")
endif()
endif()
# OpenSSL
if(NOT HAVE_LIBGNUTLS OR NOT HAVE_LIBJWT)
find_package(OpenSSL)
elseif (${ZM_CRYPTO_BACKEND} STREQUAL "openssl")
find_package(OpenSSL REQUIRED)
if(OPENSSL_FOUND)
set(HAVE_LIBOPENSSL 1)
set(HAVE_LIBCRYPTO 1)
list(APPEND ZM_BIN_LIBS "${OPENSSL_LIBRARIES}")
include_directories("${OPENSSL_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}")
check_include_file("openssl/md5.h" HAVE_OPENSSL_MD5_H)
set(optlibsfound "${optlibsfound} OpenSSL")
else()
set(optlibsnotfound "${optlibsnotfound} OpenSSL")
@ -400,38 +412,24 @@ else()
message(FATAL_ERROR "ZoneMinder requires pthread but it was not found on your system")
endif()
# pcre (using find_library and find_path)
find_library(PCRE_LIBRARIES pcre)
if(PCRE_LIBRARIES)
set(HAVE_LIBPCRE 1)
list(APPEND ZM_BIN_LIBS "${PCRE_LIBRARIES}")
find_path(PCRE_INCLUDE_DIR pcre.h)
if(PCRE_INCLUDE_DIR)
include_directories("${PCRE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${PCRE_INCLUDE_DIR}")
# Do not check for cURL if ZM_NO_CURL is on
if(NOT ZM_NO_PRCE)
# pcre (using find_library and find_path)
find_library(PCRE_LIBRARIES pcre)
if(PCRE_LIBRARIES)
set(HAVE_LIBPCRE 1)
list(APPEND ZM_BIN_LIBS "${PCRE_LIBRARIES}")
find_path(PCRE_INCLUDE_DIR pcre.h)
if(PCRE_INCLUDE_DIR)
include_directories("${PCRE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${PCRE_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE PCRE_LIBRARIES PCRE_INCLUDE_DIR)
check_include_file("pcre.h" HAVE_PCRE_H)
set(optlibsfound "${optlibsfound} PCRE")
else()
set(optlibsnotfound "${optlibsnotfound} PCRE")
endif()
mark_as_advanced(FORCE PCRE_LIBRARIES PCRE_INCLUDE_DIR)
check_include_file("pcre.h" HAVE_PCRE_H)
set(optlibsfound "${optlibsfound} PCRE")
else()
set(optlibsnotfound "${optlibsnotfound} PCRE")
endif()
# gcrypt (using find_library and find_path)
find_library(GCRYPT_LIBRARIES gcrypt)
if(GCRYPT_LIBRARIES)
set(HAVE_LIBGCRYPT 1)
list(APPEND ZM_BIN_LIBS "${GCRYPT_LIBRARIES}")
find_path(GCRYPT_INCLUDE_DIR gcrypt.h)
if(GCRYPT_INCLUDE_DIR)
include_directories("${GCRYPT_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${GCRYPT_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE GCRYPT_LIBRARIES GCRYPT_INCLUDE_DIR)
check_include_file("gcrypt.h" HAVE_GCRYPT_H)
set(optlibsfound "${optlibsfound} GCrypt")
else()
set(optlibsnotfound "${optlibsnotfound} GCrypt")
endif()
# mysqlclient (using find_library and find_path)
@ -453,129 +451,19 @@ else()
message(FATAL_ERROR "ZoneMinder requires mysqlclient but it was not found on your system")
endif()
find_package(FFMPEG 55.34.100 REQUIRED
COMPONENTS
avcodec
avformat
avutil
swresample
swscale)
set(CMAKE_REQUIRED_INCLUDES ${FFMPEG_avutil_INCLUDE_DIRS})
check_include_file("libavutil/hwcontext.h" HAVE_LIBAVUTIL_HWCONTEXT_H)
set(PATH_FFMPEG "")
set(OPT_FFMPEG "no")
# avformat (using find_library and find_path)
find_library(AVFORMAT_LIBRARIES avformat)
if(AVFORMAT_LIBRARIES)
set(HAVE_LIBAVFORMAT 1)
list(APPEND ZM_BIN_LIBS "${AVFORMAT_LIBRARIES}")
find_path(AVFORMAT_INCLUDE_DIR "libavformat/avformat.h" /usr/include/ffmpeg)
if(AVFORMAT_INCLUDE_DIR)
include_directories("${AVFORMAT_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVFORMAT_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE AVFORMAT_LIBRARIES AVFORMAT_INCLUDE_DIR)
check_include_file("libavformat/avformat.h" HAVE_LIBAVFORMAT_AVFORMAT_H)
set(optlibsfound "${optlibsfound} AVFormat")
else()
set(optlibsnotfound "${optlibsnotfound} AVFormat")
endif()
# avcodec (using find_library and find_path)
find_library(AVCODEC_LIBRARIES avcodec)
if(AVCODEC_LIBRARIES)
set(HAVE_LIBAVCODEC 1)
list(APPEND ZM_BIN_LIBS "${AVCODEC_LIBRARIES}")
find_path(AVCODEC_INCLUDE_DIR "libavcodec/avcodec.h" /usr/include/ffmpeg)
if(AVCODEC_INCLUDE_DIR)
include_directories("${AVCODEC_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVCODEC_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE AVCODEC_LIBRARIES AVCODEC_INCLUDE_DIR)
check_include_file("libavcodec/avcodec.h" HAVE_LIBAVCODEC_AVCODEC_H)
set(optlibsfound "${optlibsfound} AVCodec")
else()
message(WARNING "\nWhile it should be possible to build ZM without AVCODEC the result will pretty useless.")
set(optlibsnotfound "${optlibsnotfound} AVCodec")
endif()
# avdevice (using find_library and find_path)
find_library(AVDEVICE_LIBRARIES avdevice)
if(AVDEVICE_LIBRARIES)
set(HAVE_LIBAVDEVICE 1)
list(APPEND ZM_BIN_LIBS "${AVDEVICE_LIBRARIES}")
find_path(AVDEVICE_INCLUDE_DIR "libavdevice/avdevice.h" /usr/include/ffmpeg)
if(AVDEVICE_INCLUDE_DIR)
include_directories("${AVDEVICE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVDEVICE_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE AVDEVICE_LIBRARIES AVDEVICE_INCLUDE_DIR)
check_include_file("libavdevice/avdevice.h" HAVE_LIBAVDEVICE_AVDEVICE_H)
set(optlibsfound "${optlibsfound} AVDevice")
else()
set(optlibsnotfound "${optlibsnotfound} AVDevice")
endif()
# avutil (using find_library and find_path)
find_library(AVUTIL_LIBRARIES avutil)
if(AVUTIL_LIBRARIES)
set(HAVE_LIBAVUTIL 1)
list(APPEND ZM_BIN_LIBS "${AVUTIL_LIBRARIES}")
find_path(AVUTIL_INCLUDE_DIR "libavutil/avutil.h" /usr/include/ffmpeg)
if(AVUTIL_INCLUDE_DIR)
include_directories("${AVUTIL_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVUTIL_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE AVUTIL_LIBRARIES AVUTIL_INCLUDE_DIR)
check_include_file("libavutil/avutil.h" HAVE_LIBAVUTIL_AVUTIL_H)
check_include_file("libavutil/mathematics.h" HAVE_LIBAVUTIL_MATHEMATICS_H)
check_include_file("libavutil/hwcontext.h" HAVE_LIBAVUTIL_HWCONTEXT_H)
set(optlibsfound "${optlibsfound} AVUtil")
else()
set(optlibsnotfound "${optlibsnotfound} AVUtil")
endif()
# swscale (using find_library and find_path)
find_library(SWSCALE_LIBRARIES swscale)
if(SWSCALE_LIBRARIES)
set(HAVE_LIBSWSCALE 1)
list(APPEND ZM_BIN_LIBS "${SWSCALE_LIBRARIES}")
find_path(SWSCALE_INCLUDE_DIR "libswscale/swscale.h" /usr/include/ffmpeg)
if(SWSCALE_INCLUDE_DIR)
include_directories("${SWSCALE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${SWSCALE_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE SWSCALE_LIBRARIES SWSCALE_INCLUDE_DIR)
check_include_file("libswscale/swscale.h" HAVE_LIBSWSCALE_SWSCALE_H)
set(optlibsfound "${optlibsfound} SWScale")
else()
set(optlibsnotfound "${optlibsnotfound} SWScale")
endif()
# SWresample (using find_library and find_path)
find_library(SWRESAMPLE_LIBRARIES swresample)
if(SWRESAMPLE_LIBRARIES)
set(HAVE_LIBSWRESAMPLE 1)
list(APPEND ZM_BIN_LIBS "${SWRESAMPLE_LIBRARIES}")
find_path(SWRESAMPLE_INCLUDE_DIR "libswresample/swresample.h" /usr/include/ffmpeg)
if(SWRESAMPLE_INCLUDE_DIR)
include_directories("${SWRESAMPLE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${SWRESAMPLE_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE SWRESAMPLE_LIBRARIES SWRESAMPLE_INCLUDE_DIR)
check_include_file("libswresample/swresample.h" HAVE_LIBSWRESAMPLE_SWRESAMPLE_H)
set(optlibsfound "${optlibsfound} SWResample")
else()
set(optlibsnotfound "${optlibsnotfound} SWResample")
# AVresample (using find_library and find_path)
find_library(AVRESAMPLE_LIBRARIES avresample)
if(AVRESAMPLE_LIBRARIES)
set(HAVE_LIBAVRESAMPLE 1)
list(APPEND ZM_BIN_LIBS "${AVRESAMPLE_LIBRARIES}")
find_path(AVRESAMPLE_INCLUDE_DIR "libavresample/avresample.h" /usr/include/ffmpeg)
if(AVRESAMPLE_INCLUDE_DIR)
include_directories("${AVRESAMPLE_INCLUDE_DIR}")
set(CMAKE_REQUIRED_INCLUDES "${AVRESAMPLE_INCLUDE_DIR}")
endif()
mark_as_advanced(FORCE AVRESAMPLE_LIBRARIES AVRESAMPLE_INCLUDE_DIR)
check_include_file("libavresample/avresample.h" HAVE_LIBAVRESAMPLE_AVRESAMPLE_H)
set(optlibsfound "${optlibsfound} AVResample")
else()
set(optlibsnotfound "${optlibsnotfound} AVResample")
endif()
endif()
# Find the path to the ffmpeg executable
find_program(FFMPEG_EXECUTABLE
@ -633,6 +521,15 @@ endif()
#list(APPEND ZM_BIN_LIBS "${Boost_LIBRARIES}")
#endif()
find_package(GSOAP 2.0.0)
if (GSOAP_FOUND)
set(optlibsfound "${optlibsfound} gsoap")
add_compile_definitions(WITH_GSOAP)
else()
set(optlibsnotfound "${optlibsnotfound} gsoap")
endif()
if(NOT ZM_NO_RTSPSERVER)
set(HAVE_RTSP_SERVER 1)
else()
@ -642,34 +539,25 @@ endif()
#
# *** END OF LIBRARY CHECKS ***
# Check for gnutls or crypto
if((NOT HAVE_LIBCRYPTO) AND (NOT HAVE_LIBGNUTLS))
message(FATAL_ERROR "ZoneMinder requires crypto or gnutls but none were found on your system")
# If libjwt is not present we fall back to jwt-cpp which requires OpenSSL
if((NOT HAVE_LIBJWT) AND (NOT HAVE_LIBOPENSSL))
message(FATAL_ERROR "Using the jwt-cpp backend requires OpenSSL as crypto backend.")
endif()
# Check for V4L header files and enable ZM_HAS_V4L, ZM_HAS_V4L1, ZM_HAS_V4L2 accordingly
# Setting to zeros first is required because ZM uses #define for these
set(ZM_HAS_V4L 0)
set(ZM_HAS_V4L1 0)
set(ZM_HAS_V4L2 0)
if(HAVE_LINUX_VIDEODEV_H OR HAVE_LIBV4L1_VIDEODEV_H)
set(ZM_HAS_V4L 1)
set(ZM_HAS_V4L1 1)
endif()
if(HAVE_LINUX_VIDEODEV2_H)
set(ZM_HAS_V4L 1)
find_package(V4L2)
if(TARGET V4L2::videodev2)
set(ZM_HAS_V4L2 1)
endif()
if((NOT HAVE_LINUX_VIDEODEV_H)
AND (NOT HAVE_LIBV4L1_VIDEODEV_H)
AND (NOT HAVE_LINUX_VIDEODEV2_H))
else()
set(ZM_HAS_V4L2 0)
message(AUTHOR_WARNING "Video 4 Linux headers weren't found - Analog and USB camera support will not be available")
endif()
# Check for PCRE and enable ZM_PCRE accordingly
set(ZM_PCRE 0)
if(HAVE_LIBPCRE AND HAVE_PCRE_H)
set(ZM_PCRE 1)
endif()
# Check for mmap and enable in all components
set(ZM_MEM_MAPPED 0)
set(ENABLE_MMAP no)
@ -685,42 +573,6 @@ if(ZM_ONVIF)
set(ZM_HAS_ONVIF 1)
endif()
# Check for authentication functions
if(HAVE_OPENSSL_MD5_H)
set(CMAKE_REQUIRED_LIBRARIES "${OPENSSL_LIBRARIES}")
set(CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}")
check_prototype_definition(
MD5
"unsigned char *MD5(const unsigned char *d, size_t n, unsigned char *md)" "NULL" "openssl/md5.h"
HAVE_MD5_OPENSSL)
endif()
if(HAVE_GNUTLS_GNUTLS_H)
set(CMAKE_REQUIRED_LIBRARIES "${GNUTLS_LIBRARIES}")
set(CMAKE_REQUIRED_INCLUDES "${GNUTLS_INCLUDE_DIR}")
check_prototype_definition(
gnutls_fingerprint
"int gnutls_fingerprint (gnutls_digest_algorithm_t algo, const gnutls_datum_t * data, void *result, size_t * result_size)" "0" "stdlib.h;gnutls/gnutls.h"
HAVE_DECL_GNUTLS_FINGERPRINT)
endif()
if(NOT HAVE_DECL_GNUTLS_FINGERPRINT AND HAVE_MD5_OPENSSL)
set(HAVE_DECL_MD5 1)
endif()
if((NOT HAVE_MD5_OPENSSL) AND (NOT HAVE_DECL_GNUTLS_FINGERPRINT))
message(AUTHOR_WARNING
"ZoneMinder requires a working MD5 function for hashed authentication but
none were found - hashed authentication will not be available")
endif()
# Dirty fix for zm_user only using openssl's md5 if gnutls and gcrypt are not available.
# This needs to be fixed in zm_user.[h,cpp] but such fix will also require changes to configure.ac
if(HAVE_LIBCRYPTO AND HAVE_OPENSSL_MD5_H AND HAVE_MD5_OPENSSL)
set(HAVE_GCRYPT_H 0)
set(HAVE_GNUTLS_OPENSSL_H 0)
endif()
# Check for Perl
find_package(Perl)
if(NOT PERL_FOUND)
@ -792,6 +644,18 @@ if(ZM_PATH_ARP STREQUAL "")
endif()
endif()
# Find the path to an arp-scan compatible executable
if(ZM_PATH_ARP_SCAN STREQUAL "")
find_program(ARP_SCAN_EXECUTABLE arp-scan)
if(ARP_SCAN_EXECUTABLE)
set(ZM_PATH_ARP_SCAN "${ARP_SCAN_EXECUTABLE}")
mark_as_advanced(ARP_SCAN_EXECUTABLE)
endif()
if(ARP_SCAN_EXECUTABLE-NOTFOUND)
message(WARNING "Unable to find a compatible arp-scan binary. Monitor probe will be less powerful.")
endif()
endif()
# Some variables that zm expects
set(ZM_PID "${ZM_RUNDIR}/zm.pid")
set(ZM_CONFIG "${ZM_CONFIG_DIR}/zm.conf")
@ -858,6 +722,9 @@ endif()
message(STATUS "Optional libraries found:${optlibsfound}")
message(STATUS "Optional libraries not found:${optlibsnotfound}")
message(STATUS "Enabled crypto backend: ${ZM_CRYPTO_BACKEND}")
message(STATUS "Enabled JWT backend: ${ZM_JWT_BACKEND}")
# Run ZM configuration generator
message(STATUS "Running ZoneMinder configuration generator")
execute_process(COMMAND perl ${CMAKE_CURRENT_BINARY_DIR}/zmconfgen.pl RESULT_VARIABLE ZMCONFGEN_RESULT)

View File

@ -1,10 +1,8 @@
ZoneMinder
==========
[![Build Status](https://travis-ci.org/ZoneMinder/zoneminder.png)](https://travis-ci.org/ZoneMinder/zoneminder)
[![Bounty Source](https://api.bountysource.com/badge/team?team_id=204&style=bounties_received)](https://www.bountysource.com/teams/zoneminder/issues?utm_source=ZoneMinder&utm_medium=shield&utm_campaign=bounties_received)
[![Join Slack](https://github.com/ozonesecurity/ozonebase/blob/master/img/slacksm.png?raw=true)](https://join.slack.com/t/zoneminder-chat/shared_invite/enQtNTU0NDkxMDM5NDQwLTdhZmQ5Y2M2NWQyN2JkYTBiN2ZkMzIzZGQ0MDliMTRmM2FjZWRlYzUwYTQ2MjMwMTVjMzQ1NjYxOTdmMjE2MTE)
[![IRC Network](https://img.shields.io/badge/irc-%23zoneminder-blue.svg "IRC Freenode")](https://webchat.freenode.net/?channels=zoneminder)
All documentation for ZoneMinder is now online at https://zoneminder.readthedocs.org
@ -26,11 +24,11 @@ https://github.com/ZoneMinder/zmdockerfiles
This is the recommended method to install ZoneMinder onto your system. ZoneMinder packages are maintained for the following distros:
- Ubuntu via [Iconnor's PPA](https://launchpad.net/~iconnor)
- Ubuntu via [Isaac Connor's PPA](https://launchpad.net/~iconnor)
- Debian from their [default repository](https://packages.debian.org/search?searchon=names&keywords=zoneminder)
- RHEL/CentOS and clones via [RPM Fusion](http://rpmfusion.org)
- Fedora via [RPM Fusion](http://rpmfusion.org)
- OpenSuse via [third party repository](http://www.zoneminder.com/wiki/index.php/Installing_using_ZoneMinder_RPMs_for_SuSE)
- OpenSuse via [third party repository](https://wiki.zoneminder.com/Installing_using_ZoneMinder_RPMs_for_SuSE)
- Mageia from their default repository
- Arch via the [AUR](https://aur.archlinux.org/packages/zoneminder/)
- Gentoo via [Portage Overlays](http://gpo.zugaina.org/www-misc/zoneminder)

View File

@ -1,29 +0,0 @@
@CHECK_PROTOTYPE_DEFINITION_HEADER@
static void cmakeRequireSymbol(int dummy, ...) {
(void) dummy;
}
static void checkSymbol(void) {
#ifndef @CHECK_PROTOTYPE_DEFINITION_SYMBOL@
cmakeRequireSymbol(0, &@CHECK_PROTOTYPE_DEFINITION_SYMBOL@);
#endif
}
@CHECK_PROTOTYPE_DEFINITION_PROTO@ {
return @CHECK_PROTOTYPE_DEFINITION_RETURN@;
}
#ifdef __CLASSIC_C__
int main() {
int ac;
char*av[];
#else
int main(int ac, char *av[]) {
#endif
checkSymbol();
if (ac > 1000) {
return *av[0];
}
return 0;
}

View File

@ -1,98 +0,0 @@
# - Check if the protoype we expect is correct.
# check_prototype_definition(FUNCTION PROTOTYPE RETURN HEADER VARIABLE)
# FUNCTION - The name of the function (used to check if prototype exists)
# PROTOTYPE- The prototype to check.
# RETURN - The return value of the function.
# HEADER - The header files required.
# VARIABLE - The variable to store the result.
# Example:
# check_prototype_definition(getpwent_r
# "struct passwd *getpwent_r(struct passwd *src, char *buf, int buflen)"
# "NULL"
# "unistd.h;pwd.h"
# SOLARIS_GETPWENT_R)
# The following variables may be set before calling this macro to
# modify the way the check is run:
#
# CMAKE_REQUIRED_FLAGS = string of compile command line flags
# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
# CMAKE_REQUIRED_INCLUDES = list of include directories
# CMAKE_REQUIRED_LIBRARIES = list of libraries to link
#=============================================================================
# Copyright 2005-2009 Kitware, Inc.
# Copyright 2010-2011 Andreas Schneider <asn@cryptomilk.org>
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# (To distribute this file outside of CMake, substitute the full
# License text for the above reference.)
#
get_filename_component(__check_proto_def_dir "${CMAKE_CURRENT_LIST_FILE}" PATH)
function(CHECK_PROTOTYPE_DEFINITION _FUNCTION _PROTOTYPE _RETURN _HEADER _VARIABLE)
if ("${_VARIABLE}" MATCHES "^${_VARIABLE}$")
set(CHECK_PROTOTYPE_DEFINITION_CONTENT "/* */\n")
set(CHECK_PROTOTYPE_DEFINITION_FLAGS ${CMAKE_REQUIRED_FLAGS})
if (CMAKE_REQUIRED_LIBRARIES)
set(CHECK_PROTOTYPE_DEFINITION_LIBS
LINK_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES})
else()
set(CHECK_PROTOTYPE_DEFINITION_LIBS)
endif()
if (CMAKE_REQUIRED_INCLUDES)
set(CMAKE_SYMBOL_EXISTS_INCLUDES
"-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}")
else()
set(CMAKE_SYMBOL_EXISTS_INCLUDES)
endif()
foreach(_FILE ${_HEADER})
set(CHECK_PROTOTYPE_DEFINITION_HEADER
"${CHECK_PROTOTYPE_DEFINITION_HEADER}#include <${_FILE}>\n")
endforeach()
set(CHECK_PROTOTYPE_DEFINITION_SYMBOL ${_FUNCTION})
set(CHECK_PROTOTYPE_DEFINITION_PROTO ${_PROTOTYPE})
set(CHECK_PROTOTYPE_DEFINITION_RETURN ${_RETURN})
configure_file("${__check_proto_def_dir}/CheckPrototypeDefinition.c.in"
"${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c" @ONLY)
file(READ ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c _SOURCE)
try_compile(${_VARIABLE}
${CMAKE_BINARY_DIR}
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}
${CHECK_PROTOTYPE_DEFINITION_LIBS}
CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${CHECK_PROTOTYPE_DEFINITION_FLAGS}
"${CMAKE_SYMBOL_EXISTS_INCLUDES}"
OUTPUT_VARIABLE OUTPUT)
if (${_VARIABLE})
set(${_VARIABLE} 1 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - True")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the prototype ${_FUNCTION} exists for ${_VARIABLE} passed with the following output:\n"
"${OUTPUT}\n\n")
else ()
message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - False")
set(${_VARIABLE} 0 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the prototype ${_FUNCTION} exists for ${_VARIABLE} failed with the following output:\n"
"${OUTPUT}\n\n${_SOURCE}\n\n")
endif ()
endif()
endfunction()

View File

@ -1,98 +0,0 @@
# - Check if the protoype we expect is correct.
# check_prototype_definition(FUNCTION PROTOTYPE RETURN HEADER VARIABLE)
# FUNCTION - The name of the function (used to check if prototype exists)
# PROTOTYPE- The prototype to check.
# RETURN - The return value of the function.
# HEADER - The header files required.
# VARIABLE - The variable to store the result.
# Example:
# check_prototype_definition(getpwent_r
# "struct passwd *getpwent_r(struct passwd *src, char *buf, int buflen)"
# "NULL"
# "unistd.h;pwd.h"
# SOLARIS_GETPWENT_R)
# The following variables may be set before calling this macro to
# modify the way the check is run:
#
# CMAKE_REQUIRED_FLAGS = string of compile command line flags
# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
# CMAKE_REQUIRED_INCLUDES = list of include directories
# CMAKE_REQUIRED_LIBRARIES = list of libraries to link
#=============================================================================
# Copyright 2005-2009 Kitware, Inc.
# Copyright 2010-2011 Andreas Schneider <asn@cryptomilk.org>
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# (To distribute this file outside of CMake, substitute the full
# License text for the above reference.)
#
get_filename_component(__check_proto_def_dir "${CMAKE_CURRENT_LIST_FILE}" PATH)
function(CHECK_PROTOTYPE_DEFINITION _FUNCTION _PROTOTYPE _RETURN _HEADER _VARIABLE)
if ("${_VARIABLE}" MATCHES "^${_VARIABLE}$")
set(CHECK_PROTOTYPE_DEFINITION_CONTENT "/* */\n")
set(CHECK_PROTOTYPE_DEFINITION_FLAGS ${CMAKE_REQUIRED_FLAGS})
if (CMAKE_REQUIRED_LIBRARIES)
set(CHECK_PROTOTYPE_DEFINITION_LIBS
${LINK_LIBRARIES} ${CMAKE_REQUIRED_LIBRARIES})
else()
set(CHECK_PROTOTYPE_DEFINITION_LIBS)
endif()
if (CMAKE_REQUIRED_INCLUDES)
set(CMAKE_SYMBOL_EXISTS_INCLUDES
"-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}")
else()
set(CMAKE_SYMBOL_EXISTS_INCLUDES)
endif()
foreach(_FILE ${_HEADER})
set(CHECK_PROTOTYPE_DEFINITION_HEADER
"${CHECK_PROTOTYPE_DEFINITION_HEADER}#include <${_FILE}>\n")
endforeach()
set(CHECK_PROTOTYPE_DEFINITION_SYMBOL ${_FUNCTION})
set(CHECK_PROTOTYPE_DEFINITION_PROTO ${_PROTOTYPE})
set(CHECK_PROTOTYPE_DEFINITION_RETURN ${_RETURN})
configure_file("${__check_proto_def_dir}/CheckPrototypeDefinition.c.in"
"${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c" @ONLY)
file(READ ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c _SOURCE)
try_compile(${_VARIABLE}
${CMAKE_BINARY_DIR}
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckPrototypeDefinition.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}
${CHECK_PROTOTYPE_DEFINITION_LIBS}
CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${CHECK_PROTOTYPE_DEFINITION_FLAGS}
"${CMAKE_SYMBOL_EXISTS_INCLUDES}"
OUTPUT_VARIABLE OUTPUT)
if (${_VARIABLE})
set(${_VARIABLE} 1 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - True")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the prototype ${_FUNCTION} exists for ${_VARIABLE} passed with the following output:\n"
"${OUTPUT}\n\n")
else ()
message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - False")
set(${_VARIABLE} 0 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the prototype ${_FUNCTION} exists for ${_VARIABLE} failed with the following output:\n"
"${OUTPUT}\n\n${_SOURCE}\n\n")
endif ()
endif()
endfunction()

View File

@ -0,0 +1,163 @@
#[=======================================================================[.rst:
FindFFMPEG
----------
Find the FFmpeg and associated libraries.
This module accepts following COMPONENTS::
avcodec
avdevice
avfilter
avformat
avutil
swresample
swscale
IMPORTED Targets
^^^^^^^^^^^^^^^^
This module defines the following :prop_tgt:`IMPORTED` targets:
``FFMPEG::<component>``
The FFmpeg component.
Result Variables
^^^^^^^^^^^^^^^^
``FFMPEG_INCLUDE_DIRS``
Include directories necessary to use FFmpeg.
``FFMPEG_LIBRARIES``
Libraries necessary to use FFmpeg. Note that this only includes libraries for the components requested.
``FFMPEG_VERSION``
The version of FFMPEG found (avutil).
For each component, the following are provided:
``FFMPEG_<component>_FOUND``
FFmpeg component was found.
``FFMPEG_<component>_INCLUDE_DIRS``
Include directories for the component.
``FFMPEG_<component>_LIBRARIES``
Libraries for the component.
#]=======================================================================]
function(_ffmpeg_find component pkgconfig_name header)
find_package(PkgConfig)
pkg_check_modules(PC_FFMPEG_${component} ${pkgconfig_name})
find_path(FFMPEG_${component}_INCLUDE_DIR
NAMES "lib${component}/${header}"
HINTS
${PC_FFMPEG_${component}_INCLUDEDIR}
${PC_FFMPEG_${component}_INCLUDE_DIRS}
PATH_SUFFIXES
ffmpeg)
mark_as_advanced("FFMPEG_${component}_INCLUDE_DIR")
find_library(FFMPEG_${component}_LIBRARY
NAMES
${component}
${PC_FFMPEG_${component}_LIBRARIES}
HINTS
${PC_FFMPEG_${component}_LIBDIR}
${PC_FFMPEG_${component}_LIBRARY_DIRS})
mark_as_advanced("${component}_LIBRARY")
if(FFMPEG_${component}_LIBRARY AND FFMPEG_${component}_INCLUDE_DIR)
set(_deps_found TRUE)
set(_deps_link)
foreach(_ffmpeg_dep IN LISTS ARGN)
if(TARGET "FFMPEG::${_ffmpeg_dep}")
list(APPEND _deps_link "FFMPEG::${_ffmpeg_dep}")
else()
set(_deps_found FALSE)
endif()
endforeach()
if(_deps_found)
if(NOT TARGET "FFMPEG::${component}")
add_library("FFMPEG::${component}" UNKNOWN IMPORTED)
set_target_properties("FFMPEG::${component}" PROPERTIES
IMPORTED_LOCATION "${FFMPEG_${component}_LIBRARY}"
INTERFACE_INCLUDE_DIRECTORIES "${FFMPEG_${component}_INCLUDE_DIR}"
IMPORTED_LINK_INTERFACE_LIBRARIES "${_deps_link}")
endif()
set(FFMPEG_${component}_FOUND 1 PARENT_SCOPE)
set(FFMPEG_${component}_VERSION "${PC_FFMPEG_${component}_VERSION}" PARENT_SCOPE)
else()
set("FFMPEG_${component}_FOUND" 0 PARENT_SCOPE)
set(what)
if(NOT FFMPEG_${component}_LIBRARY)
set(what "library")
endif()
if(NOT FFMPEG_${component}_INCLUDE_DIR)
if(what)
string(APPEND what " or headers")
else()
set(what "headers")
endif()
endif()
set("FFMPEG_${component}_NOT_FOUND_MESSAGE"
"Could not find the ${what} for ${component}."
PARENT_SCOPE)
endif()
endif()
endfunction()
_ffmpeg_find(avutil libavutil avutil.h)
_ffmpeg_find(swresample libswresample swresample.h
avutil)
_ffmpeg_find(swscale libswscale swscale.h
avutil)
_ffmpeg_find(avcodec libavcodec avcodec.h
avutil)
_ffmpeg_find(avformat libavformat avformat.h
avcodec avutil)
_ffmpeg_find(avfilter libavfilter avfilter.h
avutil)
_ffmpeg_find(avdevice libavdevice avdevice.h
avformat avutil)
if(TARGET FFMPEG::avutil)
set(FFMPEG_VERSION "${FFMPEG_avutil_VERSION}")
endif()
set(FFMPEG_INCLUDE_DIRS)
set(FFMPEG_LIBRARIES)
set(_ffmpeg_required_vars)
foreach(_ffmpeg_component IN LISTS FFMPEG_FIND_COMPONENTS)
if(TARGET "FFMPEG::${_ffmpeg_component}")
set(FFMPEG_${_ffmpeg_component}_INCLUDE_DIRS
"${FFMPEG_${_ffmpeg_component}_INCLUDE_DIR}")
set(FFMPEG_${_ffmpeg_component}_LIBRARIES
"${FFMPEG_${_ffmpeg_component}_LIBRARY}")
list(APPEND FFMPEG_INCLUDE_DIRS
"${FFMPEG_${_ffmpeg_component}_INCLUDE_DIRS}")
list(APPEND FFMPEG_LIBRARIES
"${FFMPEG_${_ffmpeg_component}_LIBRARIES}")
if(FFMEG_FIND_REQUIRED_${_ffmpeg_component})
list(APPEND _ffmpeg_required_vars
"FFMPEG_${_ffmpeg_required_vars}_INCLUDE_DIRS"
"FFMPEG_${_ffmpeg_required_vars}_LIBRARIES")
endif()
endif()
endforeach()
unset(_ffmpeg_component)
if(FFMPEG_INCLUDE_DIRS)
list(REMOVE_DUPLICATES FFMPEG_INCLUDE_DIRS)
endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(FFMPEG
REQUIRED_VARS
FFMPEG_INCLUDE_DIRS
FFMPEG_LIBRARIES
${_ffmpeg_required_vars}
VERSION_VAR
FFMPEG_VERSION
HANDLE_COMPONENTS)
unset(_ffmpeg_required_vars)

100
cmake/Modules/FindFmt.cmake Normal file
View File

@ -0,0 +1,100 @@
# FindFmt
# -------
# Finds the Fmt library
#
# This will define the following variables::
#
# FMT_FOUND - system has Fmt
# FMT_INCLUDE_DIRS - the Fmt include directory
# FMT_LIBRARIES - the Fmt libraries
#
# and the following imported targets::
#
# Fmt::Fmt - The Fmt library
if(ENABLE_INTERNAL_FMT)
include(ExternalProject)
file(STRINGS ${CMAKE_SOURCE_DIR}/tools/depends/target/libfmt/Makefile VER REGEX "^[ ]*VERSION[ ]*=.+$")
string(REGEX REPLACE "^[ ]*VERSION[ ]*=[ ]*" "" FMT_VERSION "${VER}")
# allow user to override the download URL with a local tarball
# needed for offline build envs
if(FMT_URL)
get_filename_component(FMT_URL "${FMT_URL}" ABSOLUTE)
else()
set(FMT_URL http://mirrors.kodi.tv/build-deps/sources/fmt-${FMT_VERSION}.tar.gz)
endif()
if(VERBOSE)
message(STATUS "FMT_URL: ${FMT_URL}")
endif()
if(APPLE)
set(EXTRA_ARGS "-DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES}")
endif()
set(FMT_LIBRARY ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/lib/libfmt.a)
set(FMT_INCLUDE_DIR ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/include)
externalproject_add(fmt
URL ${FMT_URL}
DOWNLOAD_DIR ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/download
PREFIX ${CORE_BUILD_DIR}/fmt
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}
-DCMAKE_CXX_EXTENSIONS=${CMAKE_CXX_EXTENSIONS}
-DCMAKE_CXX_STANDARD=${CMAKE_CXX_STANDARD}
-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}
-DCMAKE_INSTALL_LIBDIR=lib
-DFMT_DOC=OFF
-DFMT_TEST=OFF
"${EXTRA_ARGS}"
BUILD_BYPRODUCTS ${FMT_LIBRARY})
set_target_properties(fmt PROPERTIES FOLDER "External Projects")
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Fmt
REQUIRED_VARS FMT_LIBRARY FMT_INCLUDE_DIR
VERSION_VAR FMT_VERSION)
set(FMT_LIBRARIES ${FMT_LIBRARY})
set(FMT_INCLUDE_DIRS ${FMT_INCLUDE_DIR})
else()
find_package(FMT 6.1.2 CONFIG REQUIRED QUIET)
if(PKG_CONFIG_FOUND)
pkg_check_modules(PC_FMT libfmt QUIET)
if(PC_FMT_VERSION AND NOT FMT_VERSION)
set(FMT_VERSION ${PC_FMT_VERSION})
endif()
endif()
find_path(FMT_INCLUDE_DIR NAMES fmt/format.h
PATHS ${PC_FMT_INCLUDEDIR})
find_library(FMT_LIBRARY_RELEASE NAMES fmt
PATHS ${PC_FMT_LIBDIR})
find_library(FMT_LIBRARY_DEBUG NAMES fmtd
PATHS ${PC_FMT_LIBDIR})
include(SelectLibraryConfigurations)
select_library_configurations(FMT)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Fmt
REQUIRED_VARS FMT_LIBRARY FMT_INCLUDE_DIR FMT_VERSION
VERSION_VAR FMT_VERSION)
if(FMT_FOUND)
set(FMT_LIBRARIES ${FMT_LIBRARY})
set(FMT_INCLUDE_DIRS ${FMT_INCLUDE_DIR})
if(NOT TARGET fmt)
add_library(fmt UNKNOWN IMPORTED)
set_target_properties(fmt PROPERTIES
IMPORTED_LOCATION "${FMT_LIBRARY}"
INTERFACE_INCLUDE_DIRECTORIES "${FMT_INCLUDE_DIR}")
endif()
endif()
endif()
mark_as_advanced(FMT_INCLUDE_DIR FMT_LIBRARY)

View File

@ -0,0 +1,113 @@
#
# This module detects if gsoap is installed and determines where the
# include files and libraries are.
#
# This code sets the following variables:
#
# GSOAP_IMPORT_DIR = full path to the gsoap import directory
# GSOAP_LIBRARIES = full path to the gsoap libraries
# GSOAP_SSL_LIBRARIES = full path to the gsoap ssl libraries
# GSOAP_INCLUDE_DIR = include dir to be used when using the gsoap library
# GSOAP_PLUGIN_DIR = gsoap plugins directory
# GSOAP_WSDL2H = wsdl2h binary
# GSOAP_SOAPCPP2 = soapcpp2 binary
# GSOAP_FOUND = set to true if gsoap was found successfully
#
# GSOAP_ROOT
# setting this enables search for gsoap libraries / headers in this location
# -----------------------------------------------------
# GSOAP Import Directories
# -----------------------------------------------------
find_path(GSOAP_IMPORT_DIR
NAMES wsa.h
PATHS ${GSOAP_ROOT}/import ${GSOAP_ROOT}/share/gsoap/import
)
# -----------------------------------------------------
# GSOAP Libraries
# -----------------------------------------------------
find_library(GSOAP_CXX_LIBRARIES
NAMES gsoap++
HINTS ${GSOAP_ROOT}/lib ${GSOAP_ROOT}/lib64
${GSOAP_ROOT}/lib32
DOC "The main gsoap library"
)
find_library(GSOAP_SSL_CXX_LIBRARIES
NAMES gsoapssl++
HINTS ${GSOAP_ROOT}/lib ${GSOAP_ROOT}/lib64
${GSOAP_ROOT}/lib32
DOC "The ssl gsoap library"
)
# -----------------------------------------------------
# GSOAP Include Directories
# -----------------------------------------------------
find_path(GSOAP_INCLUDE_DIR
NAMES stdsoap2.h
HINTS ${GSOAP_ROOT} ${GSOAP_ROOT}/include ${GSOAP_ROOT}/include/*
DOC "The gsoap include directory"
)
# -----------------------------------------------------
# GSOAP plugin Directories
# -----------------------------------------------------
find_path(GSOAP_PLUGIN_DIR
NAMES wsseapi.c
HINTS ${GSOAP_ROOT} /usr/share/gsoap/plugin
DOC "The gsoap plugin directory"
)
# -----------------------------------------------------
# GSOAP Binaries
# ----------------------------------------------------
if(NOT GSOAP_TOOL_DIR)
set(GSOAP_TOOL_DIR GSOAP_ROOT)
endif()
find_program(GSOAP_WSDL2H
NAMES wsdl2h
HINTS ${GSOAP_TOOL_DIR}/bin
DOC "The gsoap bin directory"
)
find_program(GSOAP_SOAPCPP2
NAMES soapcpp2
HINTS ${GSOAP_TOOL_DIR}/bin
DOC "The gsoap bin directory"
)
# -----------------------------------------------------
# GSOAP version
# try to determine the flagfor the 2.7.6 compatiblity, break with 2.7.13 and re-break with 2.7.16
# ----------------------------------------------------
if(GSOAP_SOAPCPP2)
execute_process(COMMAND ${GSOAP_SOAPCPP2} "-V" OUTPUT_VARIABLE GSOAP_STRING_VERSION ERROR_VARIABLE GSOAP_STRING_VERSION )
string(REGEX MATCH "[0-9]*\\.[0-9]*\\.[0-9]*" GSOAP_VERSION ${GSOAP_STRING_VERSION})
endif()
# -----------------------------------------------------
# GSOAP_276_COMPAT_FLAGS and GSOAPVERSION
# try to determine the flagfor the 2.7.6 compatiblity, break with 2.7.13 and re-break with 2.7.16
# ----------------------------------------------------
if( "${GSOAP_VERSION}" VERSION_LESS "2.7.6")
set(GSOAP_276_COMPAT_FLAGS "")
elseif ( "${GSOAP_VERSION}" VERSION_LESS "2.7.14")
set(GSOAP_276_COMPAT_FLAGS "-z")
else ( "${GSOAP_VERSION}" VERSION_LESS "2.7.14")
set(GSOAP_276_COMPAT_FLAGS "-z1 -z2")
endif ( "${GSOAP_VERSION}" VERSION_LESS "2.7.6")
# -----------------------------------------------------
# handle the QUIETLY and REQUIRED arguments and set GSOAP_FOUND to TRUE if
# all listed variables are TRUE
# -----------------------------------------------------
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(GSOAP DEFAULT_MSG GSOAP_CXX_LIBRARIES
GSOAP_INCLUDE_DIR GSOAP_WSDL2H GSOAP_SOAPCPP2)
mark_as_advanced(GSOAP_INCLUDE_DIR GSOAP_LIBRARIES GSOAP_WSDL2H GSOAP_SOAPCPP2)
if(GSOAP_FOUND)
if(GSOAP_FIND_REQUIRED AND GSOAP_FIND_VERSION AND ${GSOAP_VERSION} VERSION_LESS ${GSOAP_FIND_VERSION})
message(SEND_ERROR "Found GSOAP version ${GSOAP_VERSION} less then required ${GSOAP_FIND_VERSION}.")
endif()
endif()

View File

@ -1,28 +1,89 @@
include(FindPackageHandleStandardArgs)
#[=======================================================================[.rst:
FindLibJWT
----------
Find the JWT C Library (libjwt)
This module accepts optional COMPONENTS to select the crypto backend (these are mutually exclusive)::
openssl (default)
gnutls
IMPORTED Targets
^^^^^^^^^^^^^^^^
This module defines the following :prop_tgt:`IMPORTED` targets:
``JWT::libjwt``
The JWT library, if found with the specified crypto backend.
Result Variables
^^^^^^^^^^^^^^^^
``LIBJWT_FOUND``
System has libjwt
``LIBJWT_INCLUDE_DIRS``
The libjwt include directory
``LIBJWT_LIBRARIES``
The libraries needed to use libjwt
#]=======================================================================]
include(FindPackageHandleStandardArgs)
find_package(PkgConfig QUIET)
if(LibJWT_FIND_COMPONENTS)
set(LIBJWT_CRYPTO_BACKEND "")
foreach(component IN LISTS LibJWT_FIND_COMPONENTS)
if(component MATCHES "^(openssl|gnutls)")
if(LIBJWT_CRYPTO_BACKEND)
message(FATAL_ERROR "LibJWT: Only one crypto library can be selected.")
endif()
set(LIBJWT_CRYPTO_BACKEND ${component})
else()
message(FATAL_ERROR "LibJWT: Wrong crypto backend specified.")
endif()
endforeach()
else()
set(LIBJWT_CRYPTO_BACKEND "openssl")
endif()
set(LIBJWT_LIB_NAMES "")
if(LIBJWT_CRYPTO_BACKEND STREQUAL "openssl")
set(LIBJWT_LIB_NAMES "jwt" "libjwt")
elseif(LIBJWT_CRYPTO_BACKEND STREQUAL "gnutls")
set(LIBJWT_LIB_NAMES "jwt-gnutls" "libjwt-gnutls")
endif()
pkg_check_modules(PC_LIBJWT QUIET libjwt)
find_path(LIBJWT_INCLUDE_DIR
NAMES jwt.h
HINTS ${PC_LIBJWT_INCLUDEDIR} ${PC_LIBJWT_INCLUDE_DIRS}
)
HINTS
${PC_LIBJWT_INCLUDEDIR}
${PC_LIBJWT_INCLUDE_DIRS})
mark_as_advanced(LIBJWT_INCLUDE_DIR)
find_library(LIBJWT_LIBRARY
NAMES jwt-gnutls libjwt-gnutls liblibjwt-gnutls
HINTS ${PC_LIBJWT_LIBDIR} ${PC_LIBJWT_LIBRARY_DIR}
)
NAMES ${LIBJWT_LIB_NAMES}
HINTS
${PC_LIBJWT_LIBDIR}
${PC_LIBJWT_LIBRARY_DIR})
mark_as_advanced(LIBJWT_LIBRARY)
find_package_handle_standard_args(LibJWT
REQUIRED_VARS LIBJWT_INCLUDE_DIR LIBJWT_LIBRARY
)
REQUIRED_VARS
LIBJWT_INCLUDE_DIR
LIBJWT_LIBRARY
FAIL_MESSAGE
"Could NOT find LibJWT with the crypto backend ${LIBJWT_CRYPTO_BACKEND}.")
if(LIBJWT_FOUND)
add_library(libjwt STATIC IMPORTED GLOBAL)
set_target_properties(libjwt PROPERTIES
IMPORTED_LOCATION "${LIBJWT_LIBRARY}"
INTERFACE_INCLUDE_DIRECTORIES "${LIBJWT_INCLUDE_DIR}"
)
endif()
set(LIBJWT_LIBRARIES ${LIBJWT_LIBRARY})
set(LIBJWT_INCLUDE_DIRS ${LIBJWT_INCLUDE_DIR})
mark_as_advanced(LIBJWT_INCLUDE_DIR LIBJWT_LIBRARY)
add_library(JWT::libjwt UNKNOWN IMPORTED)
set_target_properties(JWT::libjwt PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${LIBJWT_INCLUDE_DIRS}"
IMPORTED_LOCATION "${LIBJWT_LIBRARY}")
endif()

View File

@ -0,0 +1,99 @@
#[=======================================================================[.rst:
FindV4L2
----------
Find V4L2 headers and libv4l2
This module accepts optional COMPONENTS:
videodev2 (default)
libv4l2
IMPORTED Targets
^^^^^^^^^^^^^^^^
This module defines the following :prop_tgt:`IMPORTED` targets::
``V4L2::videodev2``
The Video for Linux Two header file, if found.
``V4L2::libv4l2``
A thin abstraction layer on top of video4linux2 devices, if found.
Result Variables
^^^^^^^^^^^^^^^^
``V4L2_FOUND``
System has v4l2 support. If no components are specified only the videodev2.h header has to be found.
``V4L2_INCLUDE_DIRS``
The v4l2 include directories.
``V4L2_LIBRARIES``
The libraries needed to have v4l2 support according to the specified components.
#]=======================================================================]
find_path(V4L2_VIDEODEV2_INCLUDE_DIR
NAMES linux/videodev2.h)
mark_as_advanced(V4L2_VIDEODEV2_INCLUDE_DIR)
if(EXISTS "${V4L2_VIDEODEV2_INCLUDE_DIR}")
set(V4L2_videodev2_FOUND TRUE)
else()
set(V4L2_videodev2_FOUND FALSE)
endif()
pkg_check_modules(PC_V4L2_LIBV4L2 QUIET libv4l2)
find_path(V4L2_LIBV4L2_INCLUDE_DIR
NAMES libv4l2.h
HINTS
${PC_V4L2_LIBV4L2_INCLUDEDIR}
${PC_V4L2_LIBV4L2_INCLUDE_DIRS})
mark_as_advanced(V4L2_LIBV4L2_INCLUDE_DIR)
find_library(V4L2_LIBV4L2_LIBRARY
NAMES ${PC_V4L2_LIBV4L2_LIBRARIES}
HINTS
${PC_V4L2_LIBV4L2_LIBDIR}
${PC_V4L2_LIBV4L2_LIBRARY_DIR})
mark_as_advanced(V4L2_LIBV4L2_LIBRARY)
if(EXISTS "${V4L2_LIBV4L2_INCLUDE_DIR}" AND
EXISTS "${V4L2_LIBV4L2_LIBRARY}")
set(V4L2_libv4l2_FOUND TRUE)
else()
set(V4L2_libv4l2_FOUND FALSE)
endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(V4L2
REQUIRED_VARS
V4L2_VIDEODEV2_INCLUDE_DIR
HANDLE_COMPONENTS)
set(V4L2_INCLUDE_DIRS)
set(V4L2_LIBRARIES)
if(V4L2_videodev2_FOUND)
set(V4L2_VIDEODEV2_INCLUDE_DIRS ${V4L2_VIDEODEV2_INCLUDE_DIR})
list(APPEND V4L2_INCLUDE2_DIRS
"${V4L2_VIDEODEV2_INCLUDE_DIRS}")
add_library(V4L2::videodev2 INTERFACE IMPORTED)
set_target_properties(V4L2::videodev2 PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${V4L2_VIDEODEV2_INCLUDE_DIRS}")
endif()
if(V4L2_libv4l2_FOUND)
set(V4L2_LIBV4L2_INCLUDE_DIRS ${V4L2_LIBV4L2_INCLUDE_DIR})
set(V4L2_LIBV4L2_LIBRARIES ${V4L2_LIBV4L2_LIBRARY})
list(APPEND V4L2_INCLUDE_DIRS
"${V4L2_LIBV4L2_INCLUDE_DIRS}")
list(APPEND V4L2_LIBRARIES
"${V4L2_LIBV4L2_LIBRARIES}")
add_library(V4L2::libv4l2 UNKNOWN IMPORTED)
set_target_properties(V4L2::libv4l2 PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${V4L2_LIBV4L2_INCLUDE_DIRS}"
IMPORTED_LOCATION "${V4L2_LIBV4L2_LIBRARY}")
endif()

View File

@ -6,6 +6,7 @@ target_compile_options(zm-warning-interface
-Wformat-security
-Wno-cast-function-type
$<$<VERSION_LESS:$<CXX_COMPILER_VERSION>,11>:-Wno-clobbered>
$<$<VERSION_LESS:$<CXX_COMPILER_VERSION>,5.1>:-Wno-missing-field-initializers>
-Wno-unused-parameter
-Woverloaded-virtual
-Wvla)
@ -23,7 +24,8 @@ if(ASAN)
-fno-omit-frame-pointer
-fsanitize=address
-fsanitize-recover=address
-fsanitize-address-use-after-scope)
-fsanitize-address-use-after-scope
-Wno-stringop-truncation)
target_link_options(zm-compile-option-interface
INTERFACE

View File

@ -47,5 +47,9 @@ ZM_PATH_SWAP=@ZM_TMPDIR@
# ZoneMinder will find the arp binary automatically on most systems
ZM_PATH_ARP="@ZM_PATH_ARP@"
# Full path to optional arp-scan binary
# ZoneMinder will find the arp-scan binary automatically on most systems
ZM_PATH_ARP_SCAN="@ZM_PATH_ARP_SCAN@"
#Full path to shutdown binary
ZM_PATH_SHUTDOWN="@ZM_PATH_SHUTDOWN@"

View File

@ -4,6 +4,7 @@
configure_file(zm_create.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_create.sql" @ONLY)
configure_file(zm_update-1.31.30.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.31.30.sql" @ONLY)
configure_file(zm_update-1.35.24.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.35.24.sql" @ONLY)
configure_file(zm_update-1.37.4.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.4.sql" @ONLY)
# Glob all database upgrade scripts
file(GLOB dbfileslist RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "zm_update-*.sql")
@ -15,6 +16,8 @@ install(FILES ${dbfileslist} DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.31.30.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
# install zm_update-1.35.24.sql
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.35.24.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
# install zm_update-1.37.4.sql
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.4.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
# install zm_create.sql
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_create.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
@ -22,3 +25,8 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_create.sql" DESTINATION "${CMAKE_I
# install triggers.sql
install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/triggers.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
# install manufacturers.sql
install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/manufacturers.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")
# install models.sql
install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/models.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db")

24
db/manufacturers.sql Normal file
View File

@ -0,0 +1,24 @@
INSERT IGNORE INTO Manufacturers VALUES (1, 'Acti');
INSERT IGNORE INTO Manufacturers VALUES (2, 'Amcrest');
INSERT IGNORE INTO Manufacturers VALUES (3, 'Airlink101');
INSERT IGNORE INTO Manufacturers VALUES (4, 'Arecont Vision');
INSERT IGNORE INTO Manufacturers VALUES (5, 'Axis');
INSERT IGNORE INTO Manufacturers VALUES (6, 'Dahua');
INSERT IGNORE INTO Manufacturers VALUES (7, 'D-Link');
INSERT IGNORE INTO Manufacturers VALUES (8, 'Edimax');
INSERT IGNORE INTO Manufacturers VALUES (9, 'Foscam');
INSERT IGNORE INTO Manufacturers VALUES (10, 'Gadspot');
INSERT IGNORE INTO Manufacturers VALUES (11, 'GrandStream');
INSERT IGNORE INTO Manufacturers VALUES (12, 'HikVision');
INSERT IGNORE INTO Manufacturers VALUES (13, 'JVC');
INSERT IGNORE INTO Manufacturers VALUES (14, 'Maginon');
INSERT IGNORE INTO Manufacturers VALUES (15, 'Mobotix');
INSERT IGNORE INTO Manufacturers VALUES (16, 'Oncam Grandeye');
INSERT IGNORE INTO Manufacturers VALUES (17, 'Panasonic');
INSERT IGNORE INTO Manufacturers VALUES (18, 'Pelco');
INSERT IGNORE INTO Manufacturers VALUES (19, 'Sony');
INSERT IGNORE INTO Manufacturers VALUES (20, 'TP-Link');
INSERT IGNORE INTO Manufacturers VALUES (21, 'Trendnet');
INSERT IGNORE INTO Manufacturers VALUES (22, 'VisionTek');
INSERT IGNORE INTO Manufacturers VALUES (23, 'Vivotek');
INSERT IGNORE INTO Manufacturers VALUES (24, 'Wansview');

56
db/models.sql Normal file
View File

@ -0,0 +1,56 @@
/* INSERT INTO Manufacturers VALUES (1, 'Acti'); */
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A21');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A23');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A24');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A28');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A31');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A310');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A311');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A32');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A41');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A415');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A416');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A418');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A42');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A421');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A43');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A45');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A46');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A48');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (1, 'A74');
/*
INSERT INTO Manufacturers VALUES (2, 'Amcrest');
*/
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (2, 'IP8M-T2499EW');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (2, 'ASH42-B');
/*
INSERT INTO Manufacturers VALUES (3, 'Airlink101');
INSERT INTO Manufacturers VALUES (4, 'Arecont Vision');
INSERT INTO Manufacturers VALUES (5, 'Axis');
INSERT INTO Manufacturers VALUES (6, 'Dahua');
INSERT INTO Manufacturers VALUES (7, 'D-Link');
*/
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (7, 'DCS-930L');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (7, 'DCS-932L');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (7, 'DCS-933L');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (7, 'DCS-942L');
INSERT IGNORE INTO Models (ManufacturerId,Name) VALUES (7, 'DCS-5020L');
/*
INSERT INTO Manufacturers VALUES (8, 'Edimax');
INSERT INTO Manufacturers VALUES (9, 'Foscam');
INSERT INTO Manufacturers VALUES (10, 'Gadspot');
INSERT INTO Manufacturers VALUES (11, 'GrandStream');
INSERT INTO Manufacturers VALUES (12, 'HikVision');
INSERT INTO Manufacturers VALUES (13, 'JVC');
INSERT INTO Manufacturers VALUES (14, 'Maginon');
INSERT INTO Manufacturers VALUES (15, 'Mobotix');
INSERT INTO Manufacturers VALUES (16, 'Oncam Grandeye');
INSERT INTO Manufacturers VALUES (17, 'Panasonic');
INSERT INTO Manufacturers VALUES (18, 'Pelco');
INSERT INTO Manufacturers VALUES (19, 'Sony');
INSERT INTO Manufacturers VALUES (20, 'TP-Link');
INSERT INTO Manufacturers VALUES (21, 'Trendnet');
INSERT INTO Manufacturers VALUES (22, 'VisionTek');
INSERT INTO Manufacturers VALUES (23, 'Vivotek');
INSERT INTO Manufacturers VALUES (24, 'Wansview');
*/

View File

@ -39,6 +39,7 @@ CREATE TABLE `Config` (
`Help` text,
`Category` varchar(32) NOT NULL default '',
`Readonly` tinyint(3) unsigned NOT NULL default '0',
`Private` BOOLEAN NOT NULL DEFAULT FALSE,
`Requires` text,
PRIMARY KEY (`Name`)
) ENGINE=@ZM_MYSQL_ENGINE@;
@ -188,7 +189,7 @@ CREATE TABLE `Events` (
`StorageId` smallint(5) unsigned default 0,
`SecondaryStorageId` smallint(5) unsigned default 0,
`Name` varchar(64) NOT NULL default '',
`Cause` varchar(32) NOT NULL default '',
`Cause` TEXT,
`StartDateTime` datetime default NULL,
`EndDateTime` datetime default NULL,
`Width` smallint(5) unsigned NOT NULL default '0',
@ -283,6 +284,7 @@ CREATE TABLE `Filters` (
`Id` int(10) unsigned NOT NULL auto_increment,
`Name` varchar(64) NOT NULL default '',
`UserId` int(10) unsigned,
`ExecuteInterval` int(10) unsigned NOT NULL default '60',
`Query_json` text NOT NULL,
`AutoArchive` tinyint(3) unsigned NOT NULL default '0',
`AutoUnarchive` tinyint(3) unsigned NOT NULL default '0',
@ -412,6 +414,7 @@ CREATE TABLE `Models` (
DROP TABLE IF EXISTS `MonitorPresets`;
CREATE TABLE `MonitorPresets` (
`Id` int(10) unsigned NOT NULL auto_increment,
`ModelId` int unsigned, FOREIGN KEY (`ModelId`) REFERENCES `Models` (Id),
`Name` varchar(64) NOT NULL default '',
`Type` enum('Local','Remote','File','Ffmpeg','Libvlc','cURL','WebSite','NVSocket','VNC') NOT NULL default 'Local',
`Device` tinytext,
@ -447,16 +450,28 @@ CREATE TABLE `Monitors` (
`Notes` TEXT,
`ServerId` int(10) unsigned,
`StorageId` smallint(5) unsigned default 0,
`ManufacturerId` int unsigned, FOREIGN KEY (`ManufacturerId`) REFERENCES `Manufacturers` (Id),
`ModelId` int unsigned, FOREIGN KEY (`ModelId`) REFERENCES `Models` (Id),
`Type` enum('Local','Remote','File','Ffmpeg','Libvlc','cURL','WebSite','NVSocket','VNC') NOT NULL default 'Local',
`Function` enum('None','Monitor','Modect','Record','Mocord','Nodect') NOT NULL default 'Monitor',
`Capturing` enum('None','Ondemand', 'Always') NOT NULL default 'Always',
`Analysing` enum('None','Always') NOT NULL default 'Always',
`AnalysisSource` enum('Primary','Secondary') NOT NULL DEFAULT 'Primary',
`Recording` enum('None', 'OnMotion', 'Always') NOT NULL default 'Always',
`Enabled` tinyint(3) unsigned NOT NULL default '1',
`DecodingEnabled` tinyint(3) unsigned NOT NULL default '1',
`JanusEnabled` BOOLEAN NOT NULL default false,
`JanusAudioEnabled` BOOLEAN NOT NULL default false,
`LinkedMonitors` varchar(255),
`Triggers` set('X10') NOT NULL default '',
`EventStartCommand` VARCHAR(255) NOT NULL DEFAULT '',
`EventEndCommand` VARCHAR(255) NOT NULL DEFAULT '',
`ONVIF_URL` VARCHAR(255) NOT NULL DEFAULT '',
`ONVIF_Username` VARCHAR(64) NOT NULL DEFAULT '',
`ONVIF_Password` VARCHAR(64) NOT NULL DEFAULT '',
`ONVIF_Options` VARCHAR(64) NOT NULL DEFAULT '',
`ONVIF_Event_Listener` BOOLEAN NOT NULL DEFAULT FALSE,
`use_Amcrest_API` BOOLEAN NOT NULL DEFAULT FALSE,
`Device` tinytext NOT NULL default '',
`Channel` tinyint(3) unsigned NOT NULL default '0',
`Format` int(10) unsigned NOT NULL default '0',
@ -487,6 +502,7 @@ CREATE TABLE `Monitors` (
`OutputContainer` enum('auto','mp4','mkv'),
`EncoderParameters` TEXT,
`RecordAudio` TINYINT NOT NULL DEFAULT '0',
`RecordingSource` enum('Primary','Secondary','Both') NOT NULL DEFAULT 'Primary',
`RTSPDescribe` tinyint(1) unsigned,
`Brightness` mediumint(7) NOT NULL default '-1',
`Contrast` mediumint(7) NOT NULL default '-1',
@ -539,7 +555,7 @@ CREATE TABLE `Monitors` (
`Longitude` DECIMAL(11,8),
`RTSPServer` BOOLEAN NOT NULL DEFAULT FALSE,
`RTSPStreamName` varchar(255) NOT NULL default '',
`Importance` enum('Not','Less','Normal'),
`Importance` enum('Normal','Less','Not') NOT NULL default 'Normal',
PRIMARY KEY (`Id`)
) ENGINE=@ZM_MYSQL_ENGINE@;
@ -971,81 +987,81 @@ INSERT INTO `Controls` VALUES (NULL,'Amcrest HTTP API','Ffmpeg','Amcrest_HTTP',0
-- Add some monitor preset values
--
INSERT into MonitorPresets VALUES (NULL,'Amcrest, IP8M-T2499EW 640x480, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp','NULL',554,'rtsp://<username>:<password>@<ip-address>/cam/realmonitor?channel=1&subtype=1',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,'Amcrest, IP8M-T2499EW 3840x2160, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp','NULL',554,'rtsp://<username>:<password>@<ip-address>/cam/realmonitor?channel=1&subtype=0',NULL,3840,2160,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 320x240, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&req_fps=5',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 640x480, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&req_fps=5',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 320x240, mpjpeg, B&W','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&color=0',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP, 640x480, mpjpeg, B&W','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&color=0',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 320x240, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&req_fps=5',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,5.0,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 640x480, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&req_fps=5',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis IP PTZ, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,5.0,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT into MonitorPresets VALUES (NULL,'Axis IP, mpeg4, unicast','Remote','rtsp',0,255,'rtsp','rtpUni','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,'Axis IP, mpeg4, multicast','Remote','rtsp',0,255,'rtsp','rtpMulti','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,'Axis IP, mpeg4, RTP/RTSP','Remote','rtsp',0,255,'rtsp','rtpRtsp','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,'Axis IP, mpeg4, RTP/RTSP/HTTP','Remote',NULL,NULL,NULL,'rtsp','rtpRtspHttp','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'D-link DCS-930L, 640x480, mjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/mjpeg.cgi',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'D-Link DCS-5020L, 640x480, mjpeg','Remote','http',0,0,'http','simple','<username>:<pwd>@<ip-address>','80','/video.cgi',NULL,640,480,0,NULL,1,'34',NULL,'<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,5.0,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Panasonic IP PTZ, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,5.0,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Gadspot IP, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Gadspot IP, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Gadspot IP, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/GetData.cgi',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Gadspot IP, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'IP Webcam by Pavel Khlebovich 1920x1080','Remote','/dev/video<?>','0',255,'http','simple','<ip-address>','8080','/video','',1920,1080,0,NULL,0,'0','','',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'VEO Observer, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Blue Net Video Server, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/cgi-bin/image.cgi?control=0&id=admin&passwd=admin',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,'ACTi IP, mpeg4, unicast','Remote',NULL,NULL,NULL,'rtsp','rtpUni','<ip-address>',7070,'','/track',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>/axis-media/media.amp?videocodec=h264',NULL,NULL,NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Vivotek FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>:554/live.sdp',NULL,NULL,NULL,352,240,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Axis FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>/axis-media/media.amp',NULL,NULL,NULL,640,480,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'ACTi TCM FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://admin:123456@<host/address>:7070',NULL,NULL,NULL,320,240,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), PAL, 320x240','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), PAL, 320x240, max 5 FPS','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), PAL, 640x480','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), PAL, 640x480, max 5 FPS','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), NTSC, 320x240','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), NTSC, 320x240, max 5 FPS','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), NTSC, 640x480','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L2), NTSC, 640x480, max 5 FPS','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), PAL, 320x240','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), PAL, 320x240, max 5 FPS','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), PAL, 640x480','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), PAL, 640x480, max 5 FPS','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), NTSC, 320x240','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), NTSC, 320x240, max 5 FPS','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), NTSC, 640x480','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'BTTV Video (V4L1), NTSC, 640x480, max 5 FPS','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Remote ZoneMinder','Remote',NULL,NULL,NULL,'http','simple','<ip-address>',80,'/cgi-bin/nph-zms?mode=jpeg&monitor=<monitor-id>&scale=100&maxfps=5&buffer=0',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI8620 FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:554/11',NULL,704,576,0,NULL,1,'10','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI8608W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:554/11',NULL,640,480,0,NULL,1,'11','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Foscam FI9821W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:88/videoMain',NULL,1280,720,0,NULL,1,'12','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Loftek Sentinel PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<ip-address>','80','/videostream.cgi?user=<username>&pwd=<password>&resolution=32&rate=11',NULL,640,480,4,NULL,1,'13','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Airlink 777W PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<username>:<password>@<ip-address>','80','/cgi/mjpg/mjpg.cgi',NULL,640,480,4,NULL,1,'7','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,'SunEyes SP-P1802SWPTZ','Libvlc','/dev/video<?>','0',255,'','rtpMulti','','80','rtsp://<ip-address>:554/11','',1920,1080,0,0.00,1,'16','-speed=64','<ip-address>:<port>',100,33);
INSERT INTO MonitorPresets VALUES (NULL,'Qihan IP, 1280x720, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp',NULL,554,'rtsp://<ip-address>/tcp_live/ch0_0',NULL,1280,720,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,'Qihan IP, 1920x1080, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp',NULL,554,'rtsp://<ip-address>/tcp_live/ch0_0',NULL,1920,1080,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Amcrest, IP8M-T2499EW 640x480, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp','NULL',554,'rtsp://<username>:<password>@<ip-address>/cam/realmonitor?channel=1&subtype=1',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Amcrest, IP8M-T2499EW 3840x2160, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp','NULL',554,'rtsp://<username>:<password>@<ip-address>/cam/realmonitor?channel=1&subtype=0',NULL,3840,2160,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 320x240, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&req_fps=5',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 640x480, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&req_fps=5',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 320x240, mpjpeg, B&W','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&color=0',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP, 640x480, mpjpeg, B&W','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&color=0',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 320x240, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=320x240&req_fps=5',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=320x240',NULL,320,240,3,5.0,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 640x480, mpjpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/mjpg/video.cgi?resolution=640x480&req_fps=5',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,NULL,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis IP PTZ, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/axis-cgi/jpg/image.cgi?resolution=640x480',NULL,640,480,3,5.0,1,4,NULL,'<ip-address>:<port>',100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Axis IP, mpeg4, unicast','Remote','rtsp',0,255,'rtsp','rtpUni','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Axis IP, mpeg4, multicast','Remote','rtsp',0,255,'rtsp','rtpMulti','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Axis IP, mpeg4, RTP/RTSP','Remote','rtsp',0,255,'rtsp','rtpRtsp','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'Axis IP, mpeg4, RTP/RTSP/HTTP','Remote',NULL,NULL,NULL,'rtsp','rtpRtspHttp','<ip-address>',554,'/mpeg4/media.amp','/trackID=',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'D-link DCS-930L, 640x480, mjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/mjpeg.cgi',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'D-Link DCS-5020L, 640x480, mjpeg','Remote','http',0,0,'http','simple','<username>:<pwd>@<ip-address>','80','/video.cgi',NULL,640,480,0,NULL,1,'34',NULL,'<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 320x240, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 320x240, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 320x240, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=320x240&Quality=Standard',NULL,320,240,3,5.0,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 640x480, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/nphMotionJpeg?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 640x480, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,NULL,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Panasonic IP PTZ, 640x480, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/SnapshotJPEG?Resolution=640x480&Quality=Standard',NULL,640,480,3,5.0,1,5,NULL,'<ip-address>:<port>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Gadspot IP, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Gadspot IP, jpeg, max 5 FPS','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Gadspot IP, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/GetData.cgi',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Gadspot IP, mpjpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'IP Webcam by Pavel Khlebovich 1920x1080','Remote','/dev/video<?>','0',255,'http','simple','<ip-address>','8080','/video','',1920,1080,0,NULL,0,'0','','',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'VEO Observer, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/Jpeg/CamImg.jpg',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Blue Net Video Server, jpeg','Remote','http',0,0,'http','simple','<ip-address>',80,'/cgi-bin/image.cgi?control=0&id=admin&passwd=admin',NULL,320,240,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT into MonitorPresets VALUES (NULL,NULL,'ACTi IP, mpeg4, unicast','Remote',NULL,NULL,NULL,'rtsp','rtpUni','<ip-address>',7070,'','/track',NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>/axis-media/media.amp?videocodec=h264',NULL,NULL,NULL,640,480,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Vivotek FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>:554/live.sdp',NULL,NULL,NULL,352,240,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Axis FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://<host/address>/axis-media/media.amp',NULL,NULL,NULL,640,480,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'ACTi TCM FFMPEG','Ffmpeg',NULL,NULL,NULL,NULL,NULL,'rtsp://admin:123456@<host/address>:7070',NULL,NULL,NULL,320,240,NULL,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), PAL, 320x240','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), PAL, 320x240, max 5 FPS','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), PAL, 640x480','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), PAL, 640x480, max 5 FPS','Local','/dev/video<?>',0,255,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), NTSC, 320x240','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), NTSC, 320x240, max 5 FPS','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,320,240,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), NTSC, 640x480','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L2), NTSC, 640x480, max 5 FPS','Local','/dev/video<?>',0,45056,NULL,'v4l2',NULL,NULL,NULL,NULL,640,480,1345466932,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), PAL, 320x240','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), PAL, 320x240, max 5 FPS','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), PAL, 640x480','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), PAL, 640x480, max 5 FPS','Local','/dev/video<?>',0,0,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), NTSC, 320x240','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), NTSC, 320x240, max 5 FPS','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,320,240,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), NTSC, 640x480','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'BTTV Video (V4L1), NTSC, 640x480, max 5 FPS','Local','/dev/video<?>',0,1,NULL,'v4l1',NULL,NULL,NULL,NULL,640,480,13,5.0,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Remote ZoneMinder','Remote',NULL,NULL,NULL,'http','simple','<ip-address>',80,'/cgi-bin/nph-zms?mode=jpeg&monitor=<monitor-id>&scale=100&maxfps=5&buffer=0',NULL,NULL,NULL,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Foscam FI8620 FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:554/11',NULL,704,576,0,NULL,1,'10','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Foscam FI8608W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:554/11',NULL,640,480,0,NULL,1,'11','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Foscam FI9821W FFMPEG H.264','Ffmpeg',NULL,NULL,NULL,NULL,'','','','rtsp://<username>:<pwd>@<ip-address>:88/videoMain',NULL,1280,720,0,NULL,1,'12','<admin_pwd>','<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Loftek Sentinel PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<ip-address>','80','/videostream.cgi?user=<username>&pwd=<password>&resolution=32&rate=11',NULL,640,480,4,NULL,1,'13','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Airlink 777W PTZ, 640x480, mjpeg','Remote','http',0,0,NULL,NULL,'<username>:<password>@<ip-address>','80','/cgi/mjpg/mjpg.cgi',NULL,640,480,4,NULL,1,'7','','<username>:<pwd>@<ip-address>',100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'SunEyes SP-P1802SWPTZ','Libvlc','/dev/video<?>','0',255,'','rtpMulti','','80','rtsp://<ip-address>:554/11','',1920,1080,0,0.00,1,'16','-speed=64','<ip-address>:<port>',100,33);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Qihan IP, 1280x720, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp',NULL,554,'rtsp://<ip-address>/tcp_live/ch0_0',NULL,1280,720,3,NULL,0,NULL,NULL,NULL,100,100);
INSERT INTO MonitorPresets VALUES (NULL,NULL,'Qihan IP, 1920x1080, RTP/RTSP','Ffmpeg','rtsp',0,255,'rtsp','rtpRtsp',NULL,554,'rtsp://<ip-address>/tcp_live/ch0_0',NULL,1920,1080,3,NULL,0,NULL,NULL,NULL,100,100);
--
-- Add some zone preset values
@ -1080,11 +1096,11 @@ CREATE TABLE MontageLayouts (
PRIMARY KEY (`Id`)
);
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('Freeform', '{ "default":{"float":"left","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('2 Wide', '{ "default":{"float":"left", "width":"49%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('Freeform', '{ "default":{"float":"left","left":"0px","right":"0px","top":"0px","bottom":"0px","width":"auto"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('2 Wide', '{ "default":{"float":"left", "width":"50%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('3 Wide', '{ "default":{"float":"left", "width":"33%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('4 Wide', '{ "default":{"float":"left", "width":"24.5%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('5 Wide', '{ "default":{"float":"left", "width":"19%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('4 Wide', '{ "default":{"float":"left", "width":"25%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
INSERT INTO MontageLayouts (`Name`,`Positions`) VALUES ('5 Wide', '{ "default":{"float":"left", "width":"20%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' );
CREATE TABLE Sessions (
id char(32) not null,
@ -1115,6 +1131,9 @@ CREATE TABLE Snapshot_Events (
-- We generally don't alter triggers, we drop and re-create them, so let's keep them in a separate file that we can just source in update scripts.
source @PKGDATADIR@/db/triggers.sql
source @PKGDATADIR@/db/manufacturers.sql
source @PKGDATADIR@/db/models.sql
--
-- Apply the initial configuration
--

View File

@ -28,8 +28,8 @@ SET @s = (SELECT IF(
AND table_name = 'Monitors'
AND column_name = 'TotalEvents'
) > 0,
"SELECT 'Column TotalEvents is already removed from Monitors'",
"ALTER TABLE `Monitors` DROP `TotalEvents`"
"ALTER TABLE `Monitors` DROP `TotalEvents`",
"SELECT 'Column TotalEvents is already removed from Monitors'"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
@ -50,8 +50,8 @@ SET @s = (SELECT IF(
AND table_name = 'Monitors'
AND column_name = 'TotalEventDiskSpace'
) > 0,
"SELECT 'Column TotalEventDiskSpace is already removed from Monitors'",
"ALTER TABLE `Monitors` DROP `TotalEventDiskSpace`"
"ALTER TABLE `Monitors` DROP `TotalEventDiskSpace`",
"SELECT 'Column TotalEventDiskSpace is already removed from Monitors'"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

View File

@ -56,7 +56,7 @@ EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitor_Status'
AND column_name = 'DayEvents'
AND column_name = 'DayEventDiskSpace'
) > 0,
"ALTER TABLE `Monitor_Status` DROP `DayEventDiskSpace`",
"SELECT 'Column DayEventDiskSpace already removed from Monitor_Status'"

47
db/zm_update-1.35.29.sql Normal file
View File

@ -0,0 +1,47 @@
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ManufacturerId'
) > 0,
"SELECT 'Column ManufacturerId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `ManufacturerId` int(10) unsigned AFTER `StorageId`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ManufacturerId'
) > 0,
"SELECT 'FOREIGN KEY for ManufacturerId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD FOREIGN KEY (`ManufacturerId`) REFERENCES `Manufacturers` (Id)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ModelId'
) > 0,
"SELECT 'Column ModelId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `ModelId` int(10) unsigned AFTER `ManufacturerId`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ModelId'
) > 0,
"SELECT 'FOREIGN KEY for ModelId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD FOREIGN KEY (`ModelId`) REFERENCES `Models` (Id)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

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

@ -0,0 +1 @@
ALTER TABLE `Monitors` MODIFY `Longitude` DECIMAL(11,8);

20
db/zm_update-1.37.10.sql Normal file
View File

@ -0,0 +1,20 @@
--
-- Update Config table to have Private
--
SELECT 'Checking for Private in Config';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Config'
AND table_schema = DATABASE()
AND column_name = 'Private'
) > 0,
"SELECT 'Column Private already exists in Config'",
"ALTER TABLE `Config` ADD COLUMN `Private` BOOLEAN NOT NULL DEFAULT FALSE AFTER `Readonly`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

18
db/zm_update-1.37.11.sql Normal file
View File

@ -0,0 +1,18 @@
--
-- Update Monitors table to have use_Amcrest_API
--
SELECT 'Checking for use_Amcrest_API in Monitors';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'use_Amcrest_API'
) > 0,
"SELECT 'Column use_Amcrest_API already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `use_Amcrest_API` BOOLEAN NOT NULL default false AFTER `ONVIF_Event_Listener`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

69
db/zm_update-1.37.12.sql Normal file
View File

@ -0,0 +1,69 @@
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'Capturing'
) > 0,
"SELECT 'Column Capturing already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `Capturing` enum('None','Ondemand', 'Always') NOT NULL default 'Always' AFTER `Function`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
UPDATE `Monitors` SET `Capturing` = 'None' WHERE `Function` = 'None';
UPDATE `Monitors` SET `Capturing` = 'Always' WHERE `Function` != 'None';
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'Analysing'
) > 0,
"SELECT 'Column Analysing already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `Analysing` enum('None','Always') NOT NULL default 'Always'"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
UPDATE `Monitors` SET `Analysing` = 'None' WHERE `Function` = 'Record' OR `Function` = 'Nodect' OR `Function` = 'None';
UPDATE `Monitors` SET `Analysing` = 'Always' WHERE `Function` = 'Modect' OR `Function` = 'Mocord';
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'AnalysisSource'
) > 0,
"SELECT 'Column AnalysisSource already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `AnalysisSource` enum('Primary','Secondary') NOT NULL DEFAULT 'Primary' AFTER `Analysing`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'Recording'
) > 0,
"SELECT 'Column Recording already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `Recording` enum('None', 'OnMotion', 'Always') NOT NULL default 'Always'"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
UPDATE `Monitors` SET `Recording` = 'None' WHERE `Function` = 'Monitor';
UPDATE `Monitors` SET `Recording` = 'OnMotion' WHERE `Function` = 'Modect' OR `Function` = 'Nodect';
UPDATE `Monitors` SET `Recording` = 'Always' WHERE `Function` = 'Mocord';
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'RecordingSource'
) > 0,
"SELECT 'Column RecordingSource already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `RecordingSource` enum('Primary','Secondary','Both') NOT NULL DEFAULT 'Primary' AFTER `RecordAudio`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

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

@ -0,0 +1,7 @@
UPDATE MontageLayouts SET `Positions` = '{ "default":{"float":"left","left":"0px","right":"0px","top":"0px","bottom":"0px","width":"auto"} }' WHERE `Name`='Freeform';
UPDATE MontageLayouts SET `Positions` = '{ "default":{"float":"left", "width":"49%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' WHERE `Name`='2 Wide';
UPDATE MontageLayouts SET `Positions` = '{ "default":{"float":"left", "width":"25%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' WHERE `Name`='4 Wide';
UPDATE MontageLayouts SET `Positions` = '{ "default":{"float":"left", "width":"20%","left":"0px","right":"0px","top":"0px","bottom":"0px"} }' WHERE `Name`='5 Wide';
UPDATE Monitors set Importance = 'Normal' where Importance IS NULL;
ALTER TABLE `Monitors` MODIFY `Importance` enum('Normal','Less','Not') NOT NULL default 'Normal';

74
db/zm_update-1.37.3.sql Normal file
View File

@ -0,0 +1,74 @@
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ManufacturerId'
) > 0,
"SELECT 'Column ManufacturerId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `ManufacturerId` int(10) unsigned AFTER `StorageId`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ManufacturerId'
) > 0,
"SELECT 'FOREIGN KEY for ManufacturerId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD FOREIGN KEY (`ManufacturerId`) REFERENCES `Manufacturers` (Id)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ModelId'
) > 0,
"SELECT 'Column ModelId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD `ModelId` int(10) unsigned AFTER `ManufacturerId`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE table_schema = DATABASE()
AND table_name = 'Monitors'
AND column_name = 'ModelId'
) > 0,
"SELECT 'FOREIGN KEY for ModelId already exists in Monitors'",
"ALTER TABLE `Monitors` ADD FOREIGN KEY (`ModelId`) REFERENCES `Models` (Id)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS WHERE table_schema = DATABASE()
AND table_name = 'MonitorPresets'
AND column_name = 'ModelId'
) > 0,
"SELECT 'Column ModelId already exists in MonitorPresets'",
"ALTER TABLE `MonitorPresets` ADD `ModelId` int(10) unsigned AFTER `Id`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*) FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE table_schema = DATABASE()
AND table_name = 'MonitorPresets'
AND column_name = 'ModelId'
) > 0,
"SELECT 'FOREIGN KEY for ModelId already exists in MonitorPresets'",
"ALTER TABLE `MonitorPresets` ADD FOREIGN KEY (`ModelId`) REFERENCES `Models` (Id)"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
UPDATE `MonitorPresets` SET `ModelId`=(SELECT `Id` FROM `Models` WHERE `Name`='IP8M-T2499EW') WHERE `Name` like 'Amcrest, IP8M-T2499EW
%';

View File

@ -0,0 +1,2 @@
source @PKGDATADIR@/db/manufacturers.sql
source @PKGDATADIR@/db/models.sql

31
db/zm_update-1.37.5.sql Normal file
View File

@ -0,0 +1,31 @@
--
-- This update adds EventStartCommand and EventEndCommand
--
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'EventEndCommand'
) > 0,
"SELECT 'Column EventEndCommand already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `EventEndCommand` VARCHAR(255) NOT NULL DEFAULT '' AFTER `Triggers`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'EventStartCommand'
) > 0,
"SELECT 'Column EventStartCommand already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `EventStartCommand` VARCHAR(255) NOT NULL DEFAULT '' AFTER `Triggers`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

18
db/zm_update-1.37.6.sql Normal file
View File

@ -0,0 +1,18 @@
--
-- Update Filters table to have a ExecuteInterval Column
--
SELECT 'Checking for ExecuteInterval in Filters';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Filters'
AND table_schema = DATABASE()
AND column_name = 'ExecuteInterval'
) > 0,
"SELECT 'Column ExecuteInterval already exists in Filters'",
"ALTER TABLE Filters ADD COLUMN `ExecuteInterval` int(10) unsigned NOT NULL default '60' AFTER `UserId`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

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

@ -0,0 +1,21 @@
/* Change Cause from varchar(32) to TEXT. We now include alarmed zone name */
ALTER TABLE `Events` MODIFY `Cause` TEXT;
--
-- Update Monitors table to have a ONVIF_Event_Listener Column
--
SELECT 'Checking for ONVIF_Event_Listener in Monitors';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'ONVIF_Event_Listener'
) > 0,
"SELECT 'Column ONVIF_Event_Listener already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `ONVIF_Event_Listener` BOOLEAN NOT NULL default false AFTER `ONVIF_Options`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

18
db/zm_update-1.37.8.sql Normal file
View File

@ -0,0 +1,18 @@
--
-- Update Monitors table to have JanusEnabled
--
SELECT 'Checking for JanusEnabled in Monitors';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'JanusEnabled'
) > 0,
"SELECT 'Column JanusEnabled already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `JanusEnabled` BOOLEAN NOT NULL default false AFTER `DecodingEnabled`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

18
db/zm_update-1.37.9.sql Normal file
View File

@ -0,0 +1,18 @@
--
-- Update Monitors table to have JanusEnabled
--
SELECT 'Checking for JanusAudioEnabled in Monitors';
SET @s = (SELECT IF(
(SELECT COUNT(*)
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = 'Monitors'
AND table_schema = DATABASE()
AND column_name = 'JanusAudioEnabled'
) > 0,
"SELECT 'Column JanusAudioEnabled already exists in Monitors'",
"ALTER TABLE `Monitors` ADD COLUMN `JanusAudioEnabled` BOOLEAN NOT NULL default false AFTER `JanusEnabled`"
));
PREPARE stmt FROM @s;
EXECUTE stmt;

@ -1 +1 @@
Subproject commit cd7fd49becad6010a1b8466bfebbd93999a39878
Subproject commit 1b40f1661f93f50fd5805f239d1e466a3bcf888f

View File

@ -5,7 +5,6 @@ Maintainer: Isaac Connor <isaac@zoneminder.com>
Uploaders: Isaac Connor <isaac@zoneminder.com>
Build-Depends: debhelper, sphinx-doc, dh-linktree, dh-apache2
,cmake
,libavdevice-dev
,libavcodec-dev
,libavformat-dev
,libavutil-dev
@ -14,7 +13,6 @@ Build-Depends: debhelper, sphinx-doc, dh-linktree, dh-apache2
,ffmpeg
,net-tools
,libbz2-dev
,libgcrypt20-dev
,libcurl4-gnutls-dev
,libturbojpeg0-dev
,default-libmysqlclient-dev | libmysqlclient-dev | libmariadbclient-dev-compat

View File

@ -41,7 +41,6 @@ Copyright: 2005-2013 Cake Software Foundation, Inc. (http://cakefoundation.org)
License: Expat
Files:
cmake/Modules/CheckPrototypeDefinition*.cmake
cmake/Modules/FindGLIB2.cmake
cmake/Modules/FindPolkit.cmake
cmake/Modules/GNUInstallDirs.cmake

View File

@ -9,7 +9,6 @@ Build-Depends: debhelper (>= 9), cmake
, libjpeg8-dev | libjpeg-dev
, libpcre3-dev
, libavcodec-dev, libavformat-dev (>= 3:0.svn20090204), libswscale-dev (>= 3:0.svn20090204), libavutil-dev
, libavdevice-dev
, libv4l-dev (>= 0.8.3)
, libbz2-dev
, ffmpeg | libav-tools
@ -17,7 +16,7 @@ Build-Depends: debhelper (>= 9), cmake
, libnetpbm10-dev
, libvlccore-dev, libvlc-dev
, libcurl4-gnutls-dev | libcurl4-nss-dev | libcurl4-openssl-dev
, libgcrypt11-dev, libpolkit-gobject-1-dev
, libpolkit-gobject-1-dev
, libphp-serialization-perl
, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl, libdbd-mysql-perl
, libwww-perl, libarchive-tar-perl, libarchive-zip-perl, libdevice-serialport-perl
@ -47,7 +46,7 @@ Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
,libnumber-bytes-human-perl
,libfile-slurp-perl
, libpcre3
, ffmpeg | libav-tools, libavdevice53 | libavdevice55 | libavdevice57
, ffmpeg | libav-tools
, rsyslog | system-log-daemon
, netpbm
, zip

View File

@ -1 +1 @@
../redhat/misc/redalert.wav
../redhat/common/redalert.wav

View File

@ -27,7 +27,7 @@ Source: ZoneMinder-%{version}.tar.gz
BuildRequires: cmake polkit-devel
BuildRequires: perl-DBI perl-DBD-mysql perl-Date-Manip perl-Sys-Mmap
BuildRequires: libjpeg62 libjpeg62-devel libmysqld-devel libSDL-devel libgcrypt-devel libgnutls-devel
BuildRequires: libjpeg62 libjpeg62-devel libmysqld-devel libSDL-devel libgnutls-devel
BuildRequires: libffmpeg-devel x264
BuildRequires: pcre-devel w32codec-all

View File

@ -9,7 +9,7 @@
%global ceb_version 1.0-zm
# RtspServer is configured as a git submodule
%global rtspserver_commit cd7fd49becad6010a1b8466bfebbd93999a39878
%global rtspserver_commit eab32851421ffe54fec0229c3efc44c642bc8d46
%global sslcert %{_sysconfdir}/pki/tls/certs/localhost.crt
%global sslkey %{_sysconfdir}/pki/tls/private/localhost.key
@ -36,7 +36,7 @@
%global _hardened_build 1
Name: zoneminder
Version: 1.36.5
Version: 1.37.12
Release: 1%{?dist}
Summary: A camera monitoring and analysis tool
Group: System Environment/Daemons
@ -352,7 +352,8 @@ ln -sf %{_sysconfdir}/zm/www/zoneminder.nginx.conf %{_sysconfdir}/zm/www/zonemin
%config(noreplace) %{_sysconfdir}/logrotate.d/zoneminder
%{_unitdir}/zoneminder.service
%{_datadir}/polkit-1/actions/com.zoneminder.systemctl.policy
%{_datadir}/polkit-1/actions/com.zoneminder.*
%{_datadir}/polkit-1/rules.d/com.zoneminder.arp-scan.rules
%{_bindir}/zmsystemctl.pl
%{_bindir}/zmaudit.pl
@ -430,6 +431,9 @@ ln -sf %{_sysconfdir}/zm/www/zoneminder.nginx.conf %{_sysconfdir}/zm/www/zonemin
%dir %attr(755,nginx,nginx) %{_localstatedir}/log/zoneminder
%changelog
* Mon Jul 05 2021 Andrew Bauer <zonexpertconsulting@outlook.com> - 1.37.1-1
- 1.37.x development build
* Tue Jun 22 2021 Andrew Bauer <zonexpertconsulting@outlook.com> - 1.36.5-1
- 1.36.5 release

View File

@ -8,14 +8,14 @@ Build-Depends: debhelper (>= 9), po-debconf (>= 1.0), autoconf, automake, libtoo
, libdate-manip-perl, libwww-perl
, libjpeg8-dev | libjpeg9-dev | libjpeg62-turbo-dev
, libpcre3-dev
, libavcodec-ffmpeg-dev, libavformat-ffmpeg-dev, libswscale-ffmpeg-dev, libavutil-ffmpeg-dev, libavdevice-ffmpeg-dev
, libavcodec-ffmpeg-dev, libavformat-ffmpeg-dev, libswscale-ffmpeg-dev, libavutil-ffmpeg-dev
, libv4l-dev (>= 0.8.3)
, libbz2-dev
, libsys-mmap-perl
, 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
, libpolkit-gobject-1-dev
, libdbi-perl, libnet-sftp-foreign-perl, libexpect-perl, libmime-tools-perl
Standards-Version: 3.9.6
Homepage: http://www.zoneminder.com/

View File

@ -15,7 +15,6 @@ DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
CFLAGS = -Wall
CXXFLAGS = -DHAVE_LIBCRYPTO
ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
DEBOPT = --enable-debug

View File

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

View File

@ -1,130 +0,0 @@
Zoneminder for Debian
---------------------
Initializing database
---------------------
pv /usr/share/zoneminder/db/zm_create.sql | sudo mysql --defaults-file=/etc/mysql/debian.cnf
OR
cat /usr/share/zoneminder/db/zm_create.sql | sudo mysql --defaults-file=/etc/mysql/debian.cnf
echo 'grant lock tables,alter,create,index,select,insert,update,delete on zm.* to 'zmuser'@localhost identified by "zmpass";'\
| sudo mysql --defaults-file=/etc/mysql/debian.cnf mysql
Hint: generate secure password with `pwgen` and update "/etc/zm/zm.conf"
accordingly.
The following command can help to ensure that zoneminder can read its
configuration file:
chgrp -c www-data /etc/zm/zm.conf
Upgrading database
------------------
The database is updated automatically on installation. You should not need to take this step.
Assuming that database is on "localhost" then the following command can be
used to upgrade "zm" database:
zmupdate.pl
Additional permissions may be required to perform upgrade:
echo 'grant lock tables, create, alter on zm.* to 'zmuser'@localhost identified by "zmpass";'\
| sudo mysql --defaults-file=/etc/mysql/debian.cnf mysql
The following command prints the current version of zoneminder database:
echo 'select Value from Config where Name = "ZM_DYN_CURR_VERSION";' \
| sudo mysql --defaults-file=/etc/mysql/debian.cnf --skip-column-names zm
Enabling service
----------------
By default Zoneminder service is not automatically started and needs to be
manually enabled once database is configured:
sudo systemctl enable zoneminder.service
Web server set-up
-----------------
There are few manual steps to get the web interface working:
## Apache2
Apache can be configured as folder "/zm" using sample .conf:
sudo a2enconf zoneminder
Alternatively Apache web site configuration template can be used to setup
zoneminder as "http://zoneminder":
sudo cp -v /usr/share/doc/zoneminder/examples/apache.conf /etc/apache2/sites-available/
sudo a2ensite zoneminder.conf
Common configuration steps for Apache2:
sudo a2enmod cgi
sudo service apache2 reload
## nginx / fcgiwrap
Nginx needs "php-fpm" package to support PHP and "fcgiwrap" package
for binary "cgi-bin" applications:
sudo apt-get install php-fpm fcgiwrap
To enable a URL alias that makes Zoneminder available from
http://yourserver/zm
the following line is to be added to "server" section of a web site
configuration:
include /usr/share/doc/zoneminder/examples/nginx.conf;
For "default" web site it would be sufficient to include the above
statement to the file
/etc/nginx/sites-enabled/default
To avoid problems with feeds from multiple cameras "fcgiwrap" should be
configured to start at least as many processes as there are cameras.
It can be done by adjusting DAEMON_OPTS in "/etc/default/fcgiwrap".
Systemd users may be affected by the following bug:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=792705
## Note:
When Zoneminder web site is running it may be necessary to set
Options/Paths/PATH_ZMS to "/zm/cgi-bin/nph-zms" or according to chosen web
site configuration.
Changing the location for images and events
-------------------------------------------
ZoneMinder is now able to be configured to use an alternative location for storing
events and images at compile time. This package makes use of that, so symlinks in
/usr/share/zoneminder/www are no longer necessary.
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

View File

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

View File

@ -1,3 +0,0 @@
zoneminder (1.35.6~20200825.27-xenial) xenial; urgency=low
*
-- Isaac Connor <isaac@zoneminder.com> Tue, 25 Aug 2020 09:28:18 -0400

View File

@ -1,3 +0,0 @@
.gitattributes
web/api/.gitattributes
web/api/.gitignore

View File

@ -1 +0,0 @@
9

View File

@ -1,57 +0,0 @@
# Remember to enable cgi mod (i.e. "a2enmod cgi").
ScriptAlias /zm/cgi-bin "/usr/lib/zoneminder/cgi-bin"
<Directory "/usr/lib/zoneminder/cgi-bin">
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
AllowOverride All
Require all granted
</Directory>
# Order matters. This alias must come first.
Alias /zm/cache /var/cache/zoneminder/cache
<Directory /var/cache/zoneminder/cache>
Options -Indexes +FollowSymLinks
AllowOverride None
<IfModule mod_authz_core.c>
# Apache 2.4
Require all granted
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order deny,allow
Allow from all
</IfModule>
</Directory>
Alias /zm /usr/share/zoneminder/www
<Directory /usr/share/zoneminder/www>
Options -Indexes +FollowSymLinks
<IfModule mod_dir.c>
DirectoryIndex index.php
</IfModule>
</Directory>
# For better visibility, the following directives have been migrated from the
# default .htaccess files included with the CakePHP project.
# Parameters not set here are inherited from the parent directive above.
<Directory "/usr/share/zoneminder/www/api">
RewriteEngine on
RewriteRule ^$ app/webroot/ [L]
RewriteRule (.*) app/webroot/$1 [L]
RewriteBase /zm/api
</Directory>
<Directory "/usr/share/zoneminder/www/api/app">
RewriteEngine on
RewriteRule ^$ webroot/ [L]
RewriteRule (.*) webroot/$1 [L]
RewriteBase /zm/api
</Directory>
<Directory "/usr/share/zoneminder/www/api/app/webroot">
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
RewriteBase /zm/api
</Directory>

View File

@ -1,165 +0,0 @@
Source: zoneminder
Section: net
Priority: optional
Maintainer: Isaac Connor <isaac@zoneminder.com>
Uploaders: Isaac Connor <isaac@zoneminder.com>
Build-Depends: debhelper (>= 9), dh-systemd, python3-sphinx, apache2-dev, dh-linktree, dh-systemd, dh-apache2
,cmake
,libavdevice-dev (>= 6:10~)
,libavcodec-dev (>= 6:10~)
,libavformat-dev (>= 6:10~)
,libavutil-dev (>= 6:10~)
,libswresample-dev | libavresample-dev
,libswscale-dev (>= 6:10~)
,ffmpeg | libav-tools
,net-tools
,libbz2-dev
,libgcrypt-dev | libgcrypt11-dev
,libcurl4-gnutls-dev
,libgnutls-openssl-dev
,libjpeg8-dev | libjpeg9-dev | libjpeg62-turbo-dev
,default-libmysqlclient-dev | libmysqlclient-dev | libmariadbclient-dev-compat
,libpcre3-dev
,libpolkit-gobject-1-dev
,libv4l-dev (>= 0.8.3) [!hurd-any]
,libvlc-dev
,libdate-manip-perl
,libdbd-mysql-perl
,libphp-serialization-perl
,libsys-mmap-perl [!hurd-any]
,libwww-perl
,libdata-uuid-perl
,libssl-dev
,libcrypt-eksblowfish-perl
,libdata-entropy-perl
,libvncserver-dev
Standards-Version: 3.9.8
Homepage: http://www.zoneminder.com/
Vcs-Browser: http://anonscm.debian.org/cgit/collab-maint/zoneminder.git
Vcs-Git: git://anonscm.debian.org/collab-maint/zoneminder.git
Package: zoneminder
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
,javascript-common
,libswscale-ffmpeg3|libswscale4|libswscale3|libswscale5
,libswresample2|libswresample3|libswresample24|libswresample-ffmpeg1
,ffmpeg | libav-tools
,libdate-manip-perl, libmime-lite-perl, libmime-tools-perl
,libdbd-mysql-perl
,libphp-serialization-perl
,libmodule-load-conditional-perl
,libnet-sftp-foreign-perl
,libarchive-zip-perl
,libdbd-mysql-perl
,libdevice-serialport-perl
,libimage-info-perl
,libjson-maybexs-perl
,libsys-mmap-perl [!hurd-any]
,liburi-encode-perl
,libwww-perl, liburi-perl
,libdata-dump-perl
,libdatetime-perl
,libclass-std-fast-perl
,libsoap-wsdl-perl
,libio-socket-multicast-perl
,libdigest-sha-perl
,libsys-cpu-perl, libsys-meminfo-perl
,libdata-uuid-perl
,libnumber-bytes-human-perl
,libfile-slurp-perl
,mysql-client | mariadb-client | virtual-mysql-client
,perl-modules
,php5-mysql | php-mysql, php5-gd | php-gd , php5-apcu | php-apcu , php-apc | php-apcu-bc, php-json | php5-json
,policykit-1
,rsyslog | system-log-daemon
,zip
,libpcre3
,libssl | libssl1.0.0 | libssl1.1
,libcrypt-eksblowfish-perl
,libdata-entropy-perl
,libvncclient1|libvncclient0
Recommends: ${misc:Recommends}
,libapache2-mod-php5 | libapache2-mod-php | php5-fpm | php-fpm
,mysql-server | mariadb-server | virtual-mysql-server
,zoneminder-doc (>= ${source:Version})
,ffmpeg
Suggests: fcgiwrap, logrotate
Description: video camera security and surveillance solution
ZoneMinder is intended for use in single or multi-camera video security
applications, including commercial or home CCTV, theft prevention and child
or family member or home monitoring and other care scenarios. It
supports capture, analysis, recording, and monitoring of video data coming
from one or more video or network cameras attached to a Linux system.
ZoneMinder also support web and semi-automatic control of Pan/Tilt/Zoom
cameras using a variety of protocols. It is suitable for use as a home
video security system and for commercial or professional video security
and surveillance. It can also be integrated into a home automation system
via X.10 or other protocols.
#Package: libzoneminder-perl
#Section: perl
#Architecture: all
#Multi-Arch: foreign
#Depends: ${misc:Depends}, ${perl:Depends}
# ,libarchive-zip-perl
# ,libdbd-mysql-perl
# ,libdevice-serialport-perl
# ,libimage-info-perl
# ,libjson-maybexs-perl
# ,libsys-mmap-perl [!hurd-any]
# ,liburi-encode-perl
# ,libwww-perl
#Description: ZoneMinder Perl libraries
# 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.
# .
# This package provides ZoneMinder Perl libraries; it can be used to
# write custom interfaces as well.
Package: zoneminder-doc
Section: doc
Architecture: all
Multi-Arch: foreign
Depends: ${misc:Depends}, ${sphinxdoc:Depends}, python3-sphinx-rtd-theme
Suggests: www-browser
Description: ZoneMinder documentation
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.
.
This package provides ZoneMinder documentation in HTML format.
Package: zoneminder-dbg
Section: debug
Priority: extra
Architecture: any
Depends: zoneminder (= ${binary:Version}), ${misc:Depends}
Description: Zoneminder -- debugging symbols
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.
.
This package provides debugging symbols

View File

@ -1,168 +0,0 @@
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: ZoneMinder
Upstream-Contact: Philip Coombes <philip.coombes@zoneminder.com>
Source: https://github.com/ZoneMinder/ZoneMinder
Comment:
This package was originally debianized by matrix <matrix@cecilia>
on Mon, 7 Mar 2005 02:07:57 -0500.
It was re-done for submission to the Debian project by Peter Howard
<pjh@northern-ridge.com.au> on Fri, 8 Dec 2006 10:19:43 +1100
Files-Excluded:
web/skins/*/js/jquery-*
Files: *
Copyright: 2001-2014 Philip Coombes <philip.coombes@zoneminder.com>
2008 Brian Rudy <brudyNO@SPAMpraecogito.com>
2014 Vincent Giovannone
2013 Tim Craig <timcraigNO@SPAMsonic.net>
2003-2008 Corey DeLasaux
2001-2010 Chris Kistner
License: GPL-2+
Files: distros/*
Copyright: 2001-2008 Philip Coombes <philip.coombes@zoneminder.com>
2014 Isaac Connor <iconnor@connortechnology.com>
2005 Serg Oskin
License: GPL-2+
Files: web/skins/*/js/jquery-*
Copyright: 2010 John Resig
2010 The Dojo Foundation
License: GPL-2 or Expat
Comment:
Dual licensed under the MIT or GPL Version 2 licenses.
http://jquery.org/license
.
Includes Sizzle.js http://sizzlejs.com/
Released under the MIT, BSD, and GPL Licenses.
Files: web/api/*
Copyright: 2005-2013 Cake Software Foundation, Inc. (http://cakefoundation.org)
License: Expat
Files:
cmake/Modules/CheckPrototypeDefinition*.cmake
cmake/Modules/FindGLIB2.cmake
cmake/Modules/FindPolkit.cmake
cmake/Modules/GNUInstallDirs.cmake
Copyright:
2005-2011 Kitware, Inc.
2010-2011 Andreas Schneider <asn@cryptomilk.org>
2009 Dario Freddi <drf@kde.org>
2008 Laurent Montel, <montel@kde.org>
2011 Nikita Krupen'ko <krnekit@gmail.com>
License: BSD-3-clause
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
.
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
.
* The names of Kitware, Inc., the Insight Consortium, or the names of
any consortium members, or of any contributors, may not be used to
endorse or promote products derived from this software without
specific prior written permission.
.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS ``AS IS''
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Files: cmake/Modules/FindPerlModules.cmake
Copyright: 2012 Iowa State University
License: Boost-1.0
Boost Software License - Version 1.0 - August 17th, 2003
.
Permission is hereby granted, free of charge, to any person or organization
obtaining a copy of the software and accompanying documentation covered by
this license (the "Software") to use, reproduce, display, distribute,
execute, and transmit the Software, and to prepare derivative works of the
Software, and to permit third-parties to whom the Software is furnished to
do so, all subject to the following:
.
The copyright notices in the Software and this entire statement, including
the above license grant, this restriction and the following disclaimer,
must be included in all copies of the Software, in whole or in part, and
all derivative works of the Software, unless such copies or derivative
works are solely in the form of machine-executable object code generated by
a source language processor.
.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
Files: debian/*
Copyright: 2015 Dmitry Smirnov <onlyjob@debian.org>
2007-2014 Peter Howard <pjh@northern-ridge.com.au>
2010-2012 Vagrant Cascadian <vagrant@debian.org>
2001-2008 Philip Coombes <philip.coombes@zoneminder.com>
License: GPL-2+
License: Expat
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
.
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
License: GPL-2+
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
.
The complete text of the GNU General Public License version 2
can be found in "/usr/share/common-licenses/GPL-2".
License: GPL-2
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; version 2 of the License.
.
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
.
The complete text of the GNU General Public License version 2
can be found in "/usr/share/common-licenses/GPL-2".

View File

@ -1,32 +0,0 @@
location /zm/cgi-bin {
gzip off;
alias /usr/lib/zoneminder/cgi-bin;
include /etc/nginx/fastcgi_params;
fastcgi_param SCRIPT_FILENAME $request_filename;
fastcgi_pass unix:/var/run/fcgiwrap.socket;
}
location /zm {
# if ($scheme ~ ^http:){
# rewrite ^(.*)$ https://$host$1 permanent;
# }
gzip off;
alias /usr/share/zoneminder/www;
index index.php;
location ~ \.php$ {
if (!-f $request_filename) { return 404; }
expires epoch;
include /etc/nginx/fastcgi_params;
fastcgi_param SCRIPT_FILENAME $request_filename;
fastcgi_index index.php;
fastcgi_pass unix:/var/run/php5-fpm.sock;
}
location ~ \.(jpg|jpeg|gif|png|ico)$ {
access_log off;
expires 33d;
}
}

View File

@ -1,7 +0,0 @@
[dch]
id-length = 0
[import-orig]
pristine-tar = False
merge = False

View File

@ -1,2 +0,0 @@
usr/share/man/man3
usr/share/perl5

View File

@ -1,96 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_LDFLAGS_MAINT_APPEND += -Wl,--as-needed
ifeq ($(DEB_BUILD_ARCH_OS),hurd)
ARGS:= -DZM_NO_MMAP=ON
endif
%:
dh $@ --parallel --buildsystem=cmake --builddirectory=dbuild \
--with systemd,sphinxdoc,apache2,linktree
override_dh_auto_configure:
dh_auto_configure -- $(ARGS) \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_TYPE=Release \
-DZM_CONFIG_DIR="/etc/zm" \
-DZM_CONFIG_SUBDIR="/etc/zm/conf.d" \
-DZM_RUNDIR="/run/zm" \
-DZM_SOCKDIR="/run/zm" \
-DZM_TMPDIR="/tmp/zm" \
-DZM_CGIDIR="/usr/lib/zoneminder/cgi-bin" \
-DZM_CACHEDIR="/var/cache/zoneminder/cache" \
-DZM_DIR_EVENTS="/var/cache/zoneminder/events" \
-DZM_PATH_SHUTDOWN="/sbin/shutdown" \
-DZM_PATH_ZMS="/zm/cgi-bin/nph-zms"
override_dh_clean:
dh_clean $(MANPAGES1)
$(RM) -r docs/_build
build-indep:
#$(MAKE) -C docs text
$(MAKE) -C docs html
MANPAGES1 = dbuild/scripts/zmupdate.pl.1
$(MANPAGES1):
# generate man page(s):
pod2man -s1 --stderr --utf8 $(patsubst %.1, %, $@) $@
## reproducible build:
LAST_CHANGE=$(shell dpkg-parsechangelog -S Date)
BUILD_DATE=$(shell LC_ALL=C date -u "+%B %d, %Y" -d "$(LAST_CHANGE)")
override_dh_installman: $(MANPAGES1)
$(MAKE) -C docs man SPHINXOPTS="-D today=\"$(BUILD_DATE)\""
dh_installman --language=C $(MANPAGES1)
override_dh_auto_install:
dh_auto_install --destdir=$(CURDIR)/debian/tmp
# remove worthless files:
$(RM) -v $(CURDIR)/debian/tmp/usr/share/perl5/*/*/*/.packlist
$(RM) -v $(CURDIR)/debian/tmp/usr/share/perl5/*/*.in
# remove empty directories:
find $(CURDIR)/debian/tmp/usr -type d -empty -delete -printf 'removed %p\n'
# remove extra-license-file:
$(RM) -v $(CURDIR)/debian/tmp/usr/share/zoneminder/www/api/lib/Cake/LICENSE.txt
override_dh_fixperms:
dh_fixperms
#
# As requested by the Debian Webapps Policy Manual §3.2.1
chown root:www-data $(CURDIR)/debian/zoneminder/etc/zm/zm.conf
chmod 640 $(CURDIR)/debian/zoneminder/etc/zm/zm.conf
override_dh_systemd_start:
dh_systemd_start --no-start
override_dh_systemd_enable:
dh_systemd_enable --no-enable
override_dh_apache2:
dh_apache2 --noenable
override_dh_strip:
[ -d "$(CURDIR)/debian/zoneminder-dbg" ] \
&& dh_strip --dbg-package=zoneminder-dbg \
|| dh_strip
#%:
# dh $@ --parallel --buildsystem=autoconf --with autoreconf
#
#override_dh_auto_configure:
# dh_auto_configure -- \
# --sysconfdir=/etc/zm \
# --with-mysql=/usr \
# --with-webdir=/usr/share/zoneminder \
# --with-ffmpeg=/usr \
# --with-cgidir=/usr/lib/cgi-bin \
# --with-webuser=www-data \
# --with-webgroup=www-data \
# --enable-mmap=yes

View File

@ -1 +0,0 @@
3.0 (quilt)

View File

@ -1,5 +0,0 @@
## We're using "libjs-jquery" instead.
source-is-missing web/skins/*/js/jquery-3.5.1.min.js
## Acknowledged, will repack eventually.
source-contains-prebuilt-javascript-object web/skins/*/js/jquery-3.5.1.min.js

View File

@ -1,8 +0,0 @@
Document: zoneminder-doc
Title: Zoneminder documentation
Abstract: This document describes how to use Zoneminder.
Section: System/Administration
Format: HTML
Index: /usr/share/doc/zoneminder-doc/html/index.html
Files: /usr/share/doc/zoneminder-doc/html/*

View File

@ -1 +0,0 @@
docs/_build/html usr/share/doc/zoneminder-doc/

View File

@ -1,2 +0,0 @@
## Convenience symlink:
/usr/share/doc/zoneminder-doc/html /usr/share/doc/zoneminder/html

View File

@ -1 +0,0 @@
conf debian/conf/apache2/zoneminder.conf nginx

View File

@ -1,5 +0,0 @@
Unless bug is specific to Debian please consider reporting it directly to
upstream developer(s):
https://github.com/ZoneMinder/ZoneMinder/issues

View File

@ -1,10 +0,0 @@
var/log/zm
var/lib/zm
var/cache/zoneminder/events
var/cache/zoneminder/images
var/cache/zoneminder/temp
var/cache/zoneminder/cache
usr/share/zoneminder/db
usr/share/zoneminder/fonts
etc/zm/
etc/zm/conf.d

View File

@ -1 +0,0 @@
README.md

View File

@ -1,2 +0,0 @@
debian/examples/*
dbuild/misc/apache.conf

View File

@ -1,12 +0,0 @@
etc/zm/zm.conf
etc/zm/conf.d/*
usr/bin
usr/lib/zoneminder
usr/share/polkit-1
usr/share/zoneminder/db
usr/share/zoneminder/www
usr/share/zoneminder/fonts
# libzoneminder-perl files:
usr/share/man/man3
usr/share/perl5

View File

@ -1 +0,0 @@
/var/tmp /usr/share/zoneminder/www/api/app/tmp

View File

@ -1,6 +0,0 @@
## cakephp
#replace /usr/share/php/Cake /usr/share/zoneminder/www/api/lib/Cake
## libjs-jquery
#replace /usr/share/javascript/jquery/jquery.min.js /usr/share/zoneminder/www/skins/classic/js/jquery-3.5.1.min.js
#replace /usr/share/javascript/jquery/jquery.min.js /usr/share/zoneminder/www/skins/flat/js/jquery-3.5.1.min.js

View File

@ -1,14 +0,0 @@
# Depends: policykit-1
unusual-interpreter usr/bin/zmsystemctl.pl #!/usr/bin/pkexec
# Intentionally not others-readable, #637685.
non-standard-file-perm etc/zm/zm.conf 0640 != 0644
# Bundled Cake PHP framework, not intended for direct execution:
script-not-executable usr/share/zoneminder/www/api/*
# Annoying but seems to be too much troubles to fix; should be fixed upstream:
script-with-language-extension usr/bin/*.pl
# dh-linktree:
package-contains-broken-symlink usr/share/zoneminder/www/api/lib/Cake/*

View File

@ -1,13 +0,0 @@
/var/log/zm/*.log {
missingok
notifempty
sharedscripts
delaycompress
compress
postrotate
/usr/bin/zmpkg.pl logrot >>/dev/null 2>&1 || :
endscript
daily
rotate 7
maxage 7
}

View File

@ -1 +0,0 @@
rm_conffile /etc/zm/apache.conf 1.28.1-5~

View File

@ -1 +0,0 @@
docs/_build/man/*.1

View File

@ -1,101 +0,0 @@
#! /bin/sh
set +e
if [ "$1" = "configure" ]; then
. /etc/zm/zm.conf
for CONFFILE in /etc/zm/conf.d/*.conf; do
. "$CONFFILE"
done
# The logs can contain passwords, etc... so by setting group root, only www-data can read them, not people in the www-data group
chown www-data:root /var/log/zm
chown www-data:www-data /var/lib/zm
chown www-data:www-data /var/cache/zoneminder /var/cache/zoneminder/*
if [ ! -e "/etc/apache2/mods-enabled/cgi.load" ] && [ "$(command -v a2enmod)" != "" ]; then
echo "The cgi module is not enabled in apache2. I am enabling it using a2enmod cgi."
a2enmod cgi
fi
if [ ! -e "/etc/apache2/mods-enabled/rewrite.load" ] && [ "$(command -v a2enmod)" != "" ]; then
echo "The rewrite module is not enabled in apache2. I am enabling it using a2enmod rewrite."
a2enmod rewrite
fi
if [ "$ZM_DB_HOST" = "localhost" ]; then
if [ -e "/lib/systemd/system/mysql.service" ] || [ -e "/lib/systemd/system/mariadb.service" ] || [ -e "/etc/init.d/mysql" ]; then
# Ensure zoneminder is stopped
deb-systemd-invoke stop zoneminder.service || exit $?
#
# Get mysql started if it isn't running
#
if [ -e "/lib/systemd/system/mariadb.service" ]; then
DBSERVICE="mariadb.service"
else
DBSERVICE="mysql.service"
fi
echo "Detected db service is $DBSERVICE"
if systemctl is-failed --quiet $DBSERVICE; then
echo "$DBSERVICE is in a failed state; it will not be started."
echo "If you have already resolved the problem preventing $DBSERVICE from running,"
echo "run sudo systemctl restart $DBSERVICE then run sudo dpkg-reconfigure zoneminder."
exit 1
fi
if ! systemctl is-active --quiet mysql.service mariadb.service; then
# Due to /etc/init.d service autogeneration, mysql.service always returns the status of mariadb.service
# However, mariadb.service will not return the status of mysql.service.
deb-systemd-invoke start $DBSERVICE
fi
# Make sure systemctl status exit code is 0; i.e. the DB is running
if systemctl is-active --quiet "$DBSERVICE"; then
mysqladmin --defaults-file=/etc/mysql/debian.cnf -f reload
# test if database if already present...
if ! $(echo quit | mysql --defaults-file=/etc/mysql/debian.cnf zm > /dev/null 2> /dev/null) ; then
echo "Creating zm db"
cat /usr/share/zoneminder/db/zm_create.sql | mysql --defaults-file=/etc/mysql/debian.cnf
if [ $? -ne 0 ]; then
echo "Error creating db."
exit 1;
fi
# This creates the user.
echo "CREATE USER '${ZM_DB_USER}'@localhost IDENTIFIED BY '${ZM_DB_PASS}';" | mysql --defaults-file=/etc/mysql/debian.cnf mysql
fi
echo "Updating permissions for user ${ZM_DB_USER}@localhost"
echo "GRANT LOCK TABLES,ALTER,DROP,SELECT,INSERT,UPDATE,DELETE,CREATE,INDEX,ALTER ROUTINE,CREATE ROUTINE, TRIGGER,EXECUTE,REFERENCES ON ${ZM_DB_NAME}.* TO '${ZM_DB_USER}'@localhost;" | mysql --defaults-file=/etc/mysql/debian.cnf mysql
zmupdate.pl -s --nointeractive
if [ $? -ne 0 ]; then
echo "Error updating db."
exit 1;
fi
zmupdate.pl --nointeractive -f
if [ $? -ne 0 ]; then
echo "Error updating config."
exit 1;
fi
# Add any new PTZ control configurations to the database (will not overwrite)
zmcamtool.pl --import >/dev/null 2>&1
echo "Done Updating; starting ZoneMinder."
else
echo 'NOTE: MySQL/MariaDB not running; please start mysql and run dpkg-reconfigure zoneminder when it is running.'
fi
else
echo 'MySQL/MariaDB not found; assuming remote server.'
fi
else
echo "Not doing database upgrade due to remote db server ($ZM_DB_HOST)."
fi
echo "Done Updating; starting ZoneMinder."
deb-systemd-invoke restart zoneminder.service
fi
#DEBHELPER#

View File

@ -1,14 +0,0 @@
#! /bin/sh
set -e
if [ "$1" = "purge" ]; then
echo "
Reminder: to completely remove \"zoneminder\" it may be necessary
* to delete database using the following sample command:
sudo mysqladmin --defaults-file=/etc/mysql/debian.cnf -f drop zm
* to delete remaining data files in "/var/cache/zoneminder".
"
fi
#DEBHELPER#

View File

@ -1,11 +0,0 @@
#!/bin/sh
set -e
## Remove obsolete symlink which is in the way of dh_apache2:
ol="/etc/apache2/conf-available/zoneminder.conf"
if [ -h "${ol}" ]; then
[ "$(readlink ${ol})" = "/etc/zm/apache.conf" ] && rm -f "${ol}"
fi
#DEBHELPER#

View File

@ -1,23 +0,0 @@
# ZoneMinder systemd unit file
# This file is intended to work with Debian distributions
[Unit]
Description=ZoneMinder CCTV recording and surveillance system
After=network.target mysql.service
# Remarked out so that it will start ZM on machines that don't have mysql installed
#Requires=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=/run/zm/zm.pid
Restart=always
RestartSec=10
Environment=TZ=:/etc/localtime
TimeoutSec=600
[Install]
WantedBy=multi-user.target

View File

@ -1,4 +0,0 @@
d /run/zm 0755 www-data www-data
d /tmp/zm 0755 www-data www-data
d /var/tmp/zm 0755 www-data www-data
d /var/cache/zoneminder/cache 0755 www-data www-data

View File

@ -2,9 +2,8 @@ Source: zoneminder
Section: net
Priority: optional
Maintainer: Isaac Connor <isaac@zoneminder.com>
Build-Depends: debhelper (>= 12), sphinx-doc, python3-sphinx, dh-linktree, dh-apache2
Build-Depends: debhelper (>= 11), sphinx-doc, python3-sphinx, dh-linktree, dh-apache2
,cmake
,libavdevice-dev
,libavcodec-dev
,libavformat-dev
,libavutil-dev
@ -13,12 +12,10 @@ Build-Depends: debhelper (>= 12), sphinx-doc, python3-sphinx, dh-linktree, dh-ap
,ffmpeg
,net-tools
,libbz2-dev
,libgcrypt20-dev
,libcurl4-gnutls-dev
,libjpeg-turbo8-dev | libjpeg62-turbo-dev | libjpeg8-dev | libjpeg9-dev
,libturbojpeg0-dev
,default-libmysqlclient-dev | libmysqlclient-dev | libmariadbclient-dev-compat
,libpcre3-dev
,libpolkit-gobject-1-dev
,libv4l-dev [!hurd-any]
,libvlc-dev
@ -33,17 +30,20 @@ Build-Depends: debhelper (>= 12), sphinx-doc, python3-sphinx, dh-linktree, dh-ap
,libdata-entropy-perl
,libvncserver-dev
,libjwt-gnutls-dev|libjwt-dev
,libgsoap-dev
Standards-Version: 4.5.0
Homepage: https://www.zoneminder.com/
Package: zoneminder
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
,sudo
,javascript-common
,libswscale5
,libswresample3
,libswscale5|libswscale4
,libswresample3|libswresample2
,ffmpeg
,libdate-manip-perl, libmime-lite-perl, libmime-tools-perl
,libcurl4, libcurl4-gnutls-dev
,libdatetime-perl, libdate-manip-perl, libmime-lite-perl, libmime-tools-perl
,libdbd-mysql-perl
,libphp-serialization-perl
,libmodule-load-conditional-perl
@ -71,11 +71,11 @@ Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
,policykit-1
,rsyslog | system-log-daemon
,zip
,libpcre3
,libcrypt-eksblowfish-perl
,libdata-entropy-perl
,libvncclient1|libvncclient0
,libjwt-gnutls0
,libjwt-gnutls0|libjwt0
,libgsoap-2.8.104|libgsoap-2.8.91|libgsoap-2.8.75|libgsoap-2.8.60|libgsoap10
Recommends: ${misc:Recommends}
,libapache2-mod-php | php-fpm
,default-mysql-server | mariadb-server | virtual-mysql-server

View File

@ -41,7 +41,6 @@ Copyright: 2005-2013 Cake Software Foundation, Inc. (http://cakefoundation.org)
License: Expat
Files:
cmake/Modules/CheckPrototypeDefinition*.cmake
cmake/Modules/FindGLIB2.cmake
cmake/Modules/FindPolkit.cmake
cmake/Modules/GNUInstallDirs.cmake

View File

@ -19,6 +19,7 @@ override_dh_auto_configure:
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_MAN=0 \
-DZM_NO_PCRE=ON \
-DZM_CONFIG_DIR="/etc/zm" \
-DZM_CONFIG_SUBDIR="/etc/zm/conf.d" \
-DZM_RUNDIR="/run/zm" \

View File

@ -5,6 +5,12 @@ set +e
create_db () {
echo "Checking for db"
mysqladmin --defaults-file=/etc/mysql/debian.cnf -f reload
if [ $? -ne 0 ]; then
echo "Cannot talk to database. You will have to create the db manually with something like:";
echo "cat /usr/share/zoneminder/db/zm_create.sql | mysql -u root";
return;
fi
# test if database if already present...
if ! $(echo quit | mysql --defaults-file=/etc/mysql/debian.cnf zm > /dev/null 2> /dev/null) ; then
echo "Creating zm db"

View File

@ -5,7 +5,8 @@
Description=ZoneMinder CCTV recording and surveillance system
After=network.target mysql.service
# Remarked out so that it will start ZM on machines that don't have mysql installed
#Requires=mysql.service
# Override it by placing an override.conf in /etc/systemd/system/zoneminder.service.d
#BindsTo=mysql.service
[Service]
#User=www-data

View File

@ -1,4 +1,4 @@
d /run/zm 0755 www-data www-data
d /tmp/zm 0755 www-data www-data
d /var/tmp/zm 0755 www-data www-data
d /var/tmp/zm 0755 www-data www-data 7d
d /var/cache/zoneminder/cache 0755 www-data www-data

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