Errors during rebuild

Forum for questions and support relating to the 1.24.x releases only.
Locked
pete
Posts: 12
Joined: Wed Aug 30, 2006 12:42 am

Errors during rebuild

Post by pete »

I lost my old zm system so I'm trying to build a new one. Installed Opensuse 11.3 and downloaded the 1.24 zm source archive. I had to install about a dozen more items during configure, but it finally completed successfully using the following options.

./configure --with-webdir=/var/www/zm --with-cgidir=/var/www/cgi-bin

Now when I run make, it errors immediately with:

fizzy:/home/zm/ZoneMinder-1.24.2 # make
make all-recursive
make[1]: Entering directory `/home/zm/ZoneMinder-1.24.2'
Making all in src
make[2]: Entering directory `/home/zm/ZoneMinder-1.24.2/src'
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -I/usr/include -frepo -g -O2 -MT zmc.o -MD -MP -MF ".deps/zmc.Tpo" -c -o zmc.o zmc.cpp; \
then mv -f ".deps/zmc.Tpo" ".deps/zmc.Po"; else rm -f ".deps/zmc.Tpo"; exit 1; fi
In file included from zm_image.h:26:0,
from zm_monitor.h:25,
from zmc.cpp:28:
zm_jpeg.h:39:85: error: declaration of C function ‘void jpeg_mem_src(jpeg_decompress_struct*, const JOCTET*, int)’ conflicts with
/usr/include/jpeglib.h:959:14: error: previous declaration ‘void jpeg_mem_src(jpeg_decompress_struct*, unsigned char*, long unsigned int)’ here
zm_jpeg.h:40:81: error: declaration of C function ‘void jpeg_mem_dest(jpeg_compress_struct*, JOCTET*, int*)’ conflicts with
/usr/include/jpeglib.h:956:14: error: previous declaration ‘void jpeg_mem_dest(jpeg_compress_struct*, unsigned char**, long unsigned int*)’ here
make[2]: *** [zmc.o] Error 1
make[2]: Leaving directory `/home/zm/ZoneMinder-1.24.2/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/zm/ZoneMinder-1.24.2'
make: *** [all] Error 2
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

The libjpeg people added some memory based functions which they happened to name exactly the same as the ones in ZM. You might want to try the 1.24.3 preview release available from the thread in this forum. If not then a simple workaround is to rename all references and declarations of jpeg_mem_src/dest to zm_jpeg_mem_src/dest.
Phil
pete
Posts: 12
Joined: Wed Aug 30, 2006 12:42 am

Post by pete »

Thanks. Downloaded the 1.24.3 build and got it to compile. If you use opensuse, make sure that you include the ZM_SSL_LIB option with configure as make will complain about not finding libcrypt and md5 stuff if you don't.

So I got everything built and installed, apache is up, running, and tested with a basic index.html, installed the tables in mysql, ran zmpkg.pl start, and tried to load index.php. I get a blank screen with the following in my apache error_log file:

[Sat Mar 05 07:35:18 2011] [error] [client 192.168.1.100] PHP Parse error: syntax error, unexpected $end in /var/www/htdocs/includes/functions.php on line 2319

So I went and looked in functions.php and line 2319 is the end? I'm getting close but this error is a bit ambiguous. Can someone offer some advice as to what the problem might be? Thanks again for the help.
mastertheknife
Posts: 678
Joined: Wed Dec 16, 2009 4:32 pm
Location: Israel

Post by mastertheknife »

Verify php short tags enabled in your php.ini

mastertheknife
pete
Posts: 12
Joined: Wed Aug 30, 2006 12:42 am

Post by pete »

That did it. Got a zm screen now and now I can start adding cameras. Thanks!
pete
Posts: 12
Joined: Wed Aug 30, 2006 12:42 am

Post by pete »

OK, got the basic package up and running and then I figured I'd install ffmpeg and recompile. Got the code to build and install OK w/o errors but when I run zmpkg.pl start now, I get the following in the messages file:

Mar 10 17:03:02 fizzy zmpkg[4204]: ERR [Unable to run "sudo -u apache /usr/local/bin/zmfix", output is ""]
Mar 10 17:03:28 fizzy zmfix[4223]: ERR [Attempt to fetch string value for ZM_COLOUR_JPEG_FILES, actual type is boolean. Try running 'zmupdate.pl -f' to reload config.]

I ran the zmupdate.pl -f and it seems to complete successfully, but no change in the error. Do I need to run something else or change a configuration somewhere? Thanks.
pete
Posts: 12
Joined: Wed Aug 30, 2006 12:42 am

Post by pete »

One more thing. zm was shut down when I ran zmupdate.pl -f. Have done some searching on the forums and this issue seems to happen with rebuilds and upgrades. I've tried restarting both apache and mysql, but still having the same problem. Thanks.
Locked