Page 1 of 1

[SOLVED] CentOS 6.2 64 bit: make error: [zm_local_camera.o]

Posted: Thu Feb 02, 2012 12:19 pm
by neuropa
Hi,
I am getting a compile error, installing Zoneminder 1.25.0 on CentOS 6.2 64 bit.
Ffmpeg version: N-37454-gd76864d

Here is the error after 'make':

Code: Select all

In file included from zm_local_camera.cpp:24:
zm_local_camera.h:101: error: ‘PixelFormat’ does not name a type
zm_local_camera.h:102: error: ‘PixelFormat’ does not name a type
zm_local_camera.h:103: error: ISO C++ forbids declaration of ‘AVFrame’ with no type
zm_local_camera.h:103: error: expected ‘;’ before ‘*’ token
zm_local_camera.cpp:44: error: ‘PixelFormat’ does not name a type
zm_local_camera.cpp:259: error: expected constructor, destructor, or type conversion before ‘*’ token
zm_local_camera.cpp: In constructor ‘LocalCamera::LocalCamera(int, const std::string&, int, int, const std::string&, int, int, int, int, int, int, int, bool)’:
zm_local_camera.cpp:324: error: ‘imagePixFormat’ was not declared in this scope
zm_local_camera.cpp:324: error: ‘PIX_FMT_GRAY8’ was not declared in this scope
zm_local_camera.cpp:324: error: ‘PIX_FMT_RGB24’ was not declared in this scope
zm_local_camera.cpp:325: error: ‘capturePixFormat’ was not declared in this scope
zm_local_camera.cpp:325: error: ‘getFfPixFormatFromV4lPalette’ was not declared in this scope
zm_local_camera.cpp: In member function ‘void LocalCamera::Initialise()’:
zm_local_camera.cpp:341: error: ‘AV_LOG_DEBUG’ was not declared in this scope
zm_local_camera.cpp:341: error: ‘av_log_set_level’ was not declared in this scope
zm_local_camera.cpp:343: error: ‘AV_LOG_QUIET’ was not declared in this scope
zm_local_camera.cpp:343: error: ‘av_log_set_level’ was not declared in this scope
zm_local_camera.cpp:464: error: ‘capturePictures’ was not declared in this scope
zm_local_camera.cpp:464: error: expected type-specifier before ‘AVFrame’
zm_local_camera.cpp:464: error: expected ‘;’ before ‘AVFrame’
zm_local_camera.cpp:488: error: ‘imagePixFormat’ was not declared in this scope
zm_local_camera.cpp:488: error: ‘capturePixFormat’ was not declared in this scope
zm_local_camera.cpp:490: error: ‘avcodec_alloc_frame’ was not declared in this scope
zm_local_camera.cpp:493: error: ‘AVPicture’ was not declared in this scope
zm_local_camera.cpp:493: error: expected primary-expression before ‘)’ token
zm_local_camera.cpp:493: error: ‘avpicture_fill’ was not declared in this scope
zm_local_camera.cpp:631: error: ‘capturePictures’ was not declared in this scope
zm_local_camera.cpp:631: error: expected type-specifier before ‘AVFrame’
zm_local_camera.cpp:631: error: expected ‘;’ before ‘AVFrame’
zm_local_camera.cpp:639: error: ‘imagePixFormat’ was not declared in this scope
zm_local_camera.cpp:639: error: ‘capturePixFormat’ was not declared in this scope
zm_local_camera.cpp:641: error: ‘avcodec_alloc_frame’ was not declared in this scope
zm_local_camera.cpp:644: error: ‘AVPicture’ was not declared in this scope
zm_local_camera.cpp:644: error: expected primary-expression before ‘)’ token
zm_local_camera.cpp:644: error: ‘avpicture_fill’ was not declared in this scope
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
zm_local_camera.cpp: In member function ‘virtual int LocalCamera::Capture(Image&)’:
zm_local_camera.cpp:1643: error: expected initializer before ‘*’ token
zm_local_camera.cpp:1645: error: ‘imagePixFormat’ was not declared in this scope
zm_local_camera.cpp:1645: error: ‘capturePixFormat’ was not declared in this scope
zm_local_camera.cpp:1649: error: ‘SWS_BICUBIC’ was not declared in this scope
zm_local_camera.cpp:1649: error: ‘sws_getCachedContext’ was not declared in this scope
zm_local_camera.cpp:1653: error: ‘tmpPicture’ was not declared in this scope
zm_local_camera.cpp:1653: error: ‘avcodec_alloc_frame’ was not declared in this scope
zm_local_camera.cpp:1656: error: ‘avpicture_get_size’ was not declared in this scope
zm_local_camera.cpp:1657: error: ‘av_malloc’ was not declared in this scope
zm_local_camera.cpp:1660: error: ‘AVPicture’ was not declared in this scope
zm_local_camera.cpp:1660: error: expected primary-expression before ‘)’ token
zm_local_camera.cpp:1660: error: ‘avpicture_fill’ was not declared in this scope
zm_local_camera.cpp:1662: error: ‘capturePictures’ was not declared in this scope
zm_local_camera.cpp:1662: error: ‘tmpPicture’ was not declared in this scope
zm_local_camera.cpp:1662: error: ‘sws_scale’ was not declared in this scope
make[2]: *** [zm_local_camera.o] Error 1
make[2]: Leaving directory `/usr/src/ZoneMinder-1.25.0/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/ZoneMinder-1.25.0'
make: *** [all] Error 2
Any suggestion?
Thanks...

Re: CentOS 6.2 64 bit: make[2]: *** [zm_local_camera.o] Erro

Posted: Fri Feb 03, 2012 3:03 pm
by butlerm1977
I got past a very similar build / make issue on CentOS 5.6 x64 installing ZM 1.25. Looks like the git version of ffmpeg has something going on right now, version change or something. This error just started cropping up within the last week or so. I used to have no problems following the CentOS wiki.

To get around this, I did make uninstall to remove ffmpeg. Then installed ffmpeg (0.6.5) and ffmpeg-devel using yum. After that, the ./configure and make ran with no errors.

Re: CentOS 6.2 64 bit: make[2]: *** [zm_local_camera.o] Erro

Posted: Fri Feb 03, 2012 5:45 pm
by neuropa
So, do you think that compiling a previous release of ffmpeg will solve the problem?
I've got a working installation with CentOS 6.0 and Zoneminder 1.25.0 several months ago...

Re: CentOS 6.2 64 bit: make[2]: *** [zm_local_camera.o] Erro

Posted: Fri Feb 03, 2012 7:01 pm
by butlerm1977
Sounds like a good plan. Let us know which version works for you.

Re: CentOS 6.2 64 bit: make[2]: *** [zm_local_camera.o] Erro

Posted: Thu Feb 09, 2012 11:07 pm
by rdctaylor
I had the same issue with CentOS 6.2 and the ffmpeg from git. I followed the suggestion in this thread by uninstalling the git version and yum installing both ffmpeg and the devel and the compile worked.

Thank you!

Re: CentOS 6.2 64 bit: make[2]: *** [zm_local_camera.o] Erro

Posted: Fri Feb 10, 2012 9:29 am
by neuropa
I tried with ffmpeg version N-35287-g7076967 from git and works!