Page 1 of 1
1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Jul 20, 2015 12:19 pm
by achix
After 3 days of struggle and tweaking :
zm_event.cpp
zm_local_camera.cpp
zm_thread.h
zm_comms.cpp
zm_event.h
zm_logger.cpp
zm_timer.h
zm_comms.h
zm_ffmpeg_camera.cpp
zm_monitor.cpp
zmc.cpp
and
scripts/ZoneMinder/CMakeLists.txt
scripts/ZoneMinder/CMakeFiles/zmperlmodules.dir/build.make
with cmake cmd as :
cmake -C zm_conf.cmake -DCMAKE_C_COMPILER=gcc48 -DCMAKE_CXX_COMPILER=g++48 -DCMAKE_VERBOSE_MAKEFILE=ON -DHAVE_SENDFILE=OFF -DCMAKE_BUILD_TYPE=Debug .
I finally managed to correctly compile and install zoneminder 1.28.1 on FreeBSD 10.1 with updated packages.
However, it core dumps on zmc, its problem is the inclusion of zm_monitor.h. It core dumps with zm_monitor.h even if the body of main is empty. gdb ./zmc zmc.core shows nothing.
If anyone cares to shed some light into looking into this, that would be great.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Wed Jul 22, 2015 2:51 pm
by achix
After hacking zm_image.cpp with :
#define ZM_STRIP_SSE 1
and reverting back to CLANG/LLVM I FINALLY MANAGED TO HAVE STREAMING via zmc!!!!!!
and also reverting back to IPC SSH mem
cmake -C zm_conf.cmake -DCMAKE_VERBOSE_MAKEFILE=ON -DHAVE_SENDFILE=OFF -DCMAKE_BUILD_TYPE=Debug -DZM_NO_MMAP=ON .
stay tuned....
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Wed Jul 22, 2015 6:49 pm
by achix
Got my first motion detection.
Remarks so far :
- all listed above programs/scripts indeed need editing
- gcc48 g++48 do *NOT* produce a functioning zmc,
- so CLANG/LLVM is a must
- some ASM code will not compile with CLANG, hence the hack with zm_image.cpp
- some perl scripts (/usr/local/lib/perl5/ZoneMinder/General.pm) need tweaking, are broken by default
- for some reason creation of /usr/local/lib/perl5/site_perl/ZoneMinder/Memory.pm (program used by external perl scripts) did not respect -DZM_NO_MMAP=ON , while at the same time /usr/local/lib/perl5/ZoneMinder/Memory.pm seemed ok. Had to manually edit /usr/local/lib/perl5/site_perl/ZoneMinder/Memory.pm to revert back to SYSV IPC SHM, instead of mmap .
- MMAP does not seem to work with FreeBSD, had to revert to IPC SHM.
I cannot promise any port soon. But after I got the whole thing working + the monitoring perl for alarms , I will try to upload somewhere the resulting source tarball, in order to build, one is supposed to follow the instructions posted here, and make it work.
Then someone might pick it up and make a port out of it. Some changes like this one with zm_image.cpp do not seem so innocent to me, and I do not understand their internals, still fail to see where assembly code fits into place, but any way.
If anyone wants to help anyway, it would be great.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Sat Jul 25, 2015 5:11 am
by achix
I tried with FreeBSD's mmap, and using a tmpfs fs for shared mem, but it turned out rather ugly. While I got some results via zmc and zms, the whole system was unstable. Reverted back to IPC SHM.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 03, 2015 1:46 am
by Hilbe
Subscribed. Thanks for your effort!
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 03, 2015 10:55 am
by achix
Hilbe wrote:Subscribed. Thanks for your effort!
Thanx for your interest.
I will try to make a set of patches against the official tarball, (to be compiled the traditional way as described in this thread, not FreeBSD-port style), and make it available somehow.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 03, 2015 4:23 pm
by achix
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 03, 2015 4:33 pm
by Hilbe
Any chance of a FreeBSD port update, I prefer the centralized update management that way too. I'm in no rush, I have a working Zoneminder on CentOS Behyve VM.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 03, 2015 4:45 pm
by achix
Hilbe wrote:
Any chance of a FreeBSD port update, I prefer the centralized update management that way too. I'm in no rush, I have a working Zoneminder on CentOS Behyve VM.
well this seems work for you then, get the patches, build a port and submit it to FreeBSD!
or just follow the instructions here.
I had better experiences with zoneminder on FreeBSD than Linux tho.
Also, thanx for sharing your CentOS Behyve setup. Did you make it play well out of the box? Or did it need some tweaking ?
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Sun Aug 16, 2015 6:49 pm
by Hilbe
achix wrote:Hilbe wrote:
Any chance of a FreeBSD port update, I prefer the centralized update management that way too. I'm in no rush, I have a working Zoneminder on CentOS Behyve VM.
well this seems work for you then, get the patches, build a port and submit it to FreeBSD!
or just follow the instructions here.
I had better experiences with zoneminder on FreeBSD than Linux tho.
Also, thanx for sharing your CentOS Behyve setup. Did you make it play well out of the box? Or did it need some tweaking ?
CentOS and ZM work great. Simple setup using the zmrepo. Hardest part was figuring out behyve and getting it to work properly with CentOS - took some tricks to get it to use Grub2.
Would be cool if someone took over the port on FreeBSD. Prefer the native vs virtualized approach.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Mon Aug 17, 2015 7:52 am
by achix
Hilbe wrote:
Would be cool if someone took over the port on FreeBSD. Prefer the native vs virtualized approach.
nothing prevents you from building your native zoneminder executables following the instructions and code from this very thread. I don't think that a port is something to expect any time soon. Since I got my native zoneminder running, I realized I consumed all my time slots devoted to this. There have been some lousy attempts from FreeBSD people to create and submit a port, but since they didn't really have any interest on zoneminder, the results were poor.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Tue Apr 12, 2016 10:43 am
by chebo
achix wrote:Hilbe wrote:
Would be cool if someone took over the port on FreeBSD. Prefer the native vs virtualized approach.
nothing prevents you from building your native zoneminder executables following the instructions and code from this very thread. I don't think that a port is something to expect any time soon. Since I got my native zoneminder running, I realized I consumed all my time slots devoted to this. There have been some lousy attempts from FreeBSD people to create and submit a port, but since they didn't really have any interest on zoneminder, the results were poor.
Hello. Do I understand correctly that you can install zoneminder on Freebsd? Please tell me in 2 words how to do it using your patch.
Re: 1.28.1 for FreeBSD 10.1-RELEASE-p10
Posted: Tue Apr 12, 2016 12:10 pm
by achix
subscribe to some FreeBSD list, grab my patches, ask questions there, come back here if you need further help.