There appears to be a missing include in zm_local_camera.cpp file. After adding the below headers (most of which I'm sure are superfluous), it compiles.
It is one of these (or more):
< #include <stdlib.h>
< #include <string.h>
< #include <limits.h>
< #include <time.h>
< #include <sys/time.h>
< #include <mysql/mysql.h>
<
< #include <set>
< #include <map>
<
< #include "zm.h"
< #include "zm_image.h"
< #include "zm_stream.h"
The manifestation of this ommission (in Centos 6) is:
[root@dmz2 src]# make zm_local_camera.o
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -I/usr/include -g -O2 -MT zm_local_camera.o -MD -MP -MF .deps/zm_local_camera.Tpo -c -o zm_local_camera.o zm_local_camera.cpp
zm_local_camera.cpp: In static member function ‘static bool LocalCamera::GetCurrentSettings(const char*, char*, int, bool)’:
zm_local_camera.cpp:774: error: ‘PATH_MAX’ was not declared in this scope
zm_local_camera.cpp:779: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:781: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:782: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:799: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:801: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:811: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:936: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:961: error: ‘queryDevice’ was not declared in this scope
zm_local_camera.cpp:1086: error: ‘queryDevice’ was not declared in this scope
make: *** [zm_local_camera.o] Error 1
Missing header file in zm_local_camera.cpp
-
- Posts: 2
- Joined: Tue Oct 11, 2011 4:16 pm
Re: Missing header file in zm_local_camera.cpp
I was getting this same error when compiling (or trying to) on Scientific Linux 6.1. SL6 is another RHEL variant like CentOS.
I can confirm that these extra includes allow zoneminder 1.25.0 to compile on Scientific Linux 6.1.
Any hopes of have this added to 1.25.1? Any ideas why this is needed? Is this only affecting RHEL variants?
I can confirm that these extra includes allow zoneminder 1.25.0 to compile on Scientific Linux 6.1.
Any hopes of have this added to 1.25.1? Any ideas why this is needed? Is this only affecting RHEL variants?