broken compile on Slack 12.1

Forum for questions and support relating to the 1.24.x releases only.
Locked
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

broken compile on Slack 12.1

Post by nuck »

Hi guys.

Yesterday I managed to get 1.23 installed on Slackware 12.1 so tonight I though I'd take a run at ZM 1.24. I ran into a couple of minor glitches with the configure script which for the most part aren't overly concerning. The configure script is looking for declaration of _doprnt that looks to be in conflict with another library. Anywho, I pressed on and tried a make and here is the output :

make all-recursive
make[1]: Entering directory `/usr/src/ZoneMinder-1.24.0'
Making all in src
make[2]: Entering directory `/usr/src/ZoneMinder-1.24.0/src'
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zmc.o -MD -MP -MF .deps/zmc.Tpo -c -o zmc.o zmc.cpp
mv -f .deps/zmc.Tpo .deps/zmc.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_box.o -MD -MP -MF .deps/zm_box.Tpo -c -o zm_box.o zm_box.cpp
mv -f .deps/zm_box.Tpo .deps/zm_box.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_buffer.o -MD -MP -MF .deps/zm_buffer.Tpo -c -o zm_buffer.o zm_buffer.cpp
mv -f .deps/zm_buffer.Tpo .deps/zm_buffer.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_camera.o -MD -MP -MF .deps/zm_camera.Tpo -c -o zm_camera.o zm_camera.cpp
mv -f .deps/zm_camera.Tpo .deps/zm_camera.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_comms.o -MD -MP -MF .deps/zm_comms.Tpo -c -o zm_comms.o zm_comms.cpp
mv -f .deps/zm_comms.Tpo .deps/zm_comms.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_config.o -MD -MP -MF .deps/zm_config.Tpo -c -o zm_config.o zm_config.cpp
mv -f .deps/zm_config.Tpo .deps/zm_config.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_coord.o -MD -MP -MF .deps/zm_coord.Tpo -c -o zm_coord.o zm_coord.cpp
mv -f .deps/zm_coord.Tpo .deps/zm_coord.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm.o -MD -MP -MF .deps/zm.Tpo -c -o zm.o zm.cpp
mv -f .deps/zm.Tpo .deps/zm.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_db.o -MD -MP -MF .deps/zm_db.Tpo -c -o zm_db.o zm_db.cpp
mv -f .deps/zm_db.Tpo .deps/zm_db.Po
gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -g -O2 -MT zm_debug.o -MD -MP -MF .deps/zm_debug.Tpo -c -o zm_debug.o zm_debug.c
mv -f .deps/zm_debug.Tpo .deps/zm_debug.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_event.o -MD -MP -MF .deps/zm_event.Tpo -c -o zm_event.o zm_event.cpp
mv -f .deps/zm_event.Tpo .deps/zm_event.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_exception.o -MD -MP -MF .deps/zm_exception.Tpo -c -o zm_exception.o zm_exception.cpp
mv -f .deps/zm_exception.Tpo .deps/zm_exception.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_file_camera.o -MD -MP -MF .deps/zm_file_camera.Tpo -c -o zm_file_camera.o zm_file_camera.cpp
mv -f .deps/zm_file_camera.Tpo .deps/zm_file_camera.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_image.o -MD -MP -MF .deps/zm_image.Tpo -c -o zm_image.o zm_image.cpp
zm_image.cpp: In member function 'void Image::Blend(const Image&, int) const':
zm_image.cpp:768: warning: operation on 'pdest' may be undefined
mv -f .deps/zm_image.Tpo .deps/zm_image.Po
gcc -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -g -O2 -MT zm_jpeg.o -MD -MP -MF .deps/zm_jpeg.Tpo -c -o zm_jpeg.o zm_jpeg.c
mv -f .deps/zm_jpeg.Tpo .deps/zm_jpeg.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -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
mv -f .deps/zm_local_camera.Tpo .deps/zm_local_camera.Po
g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include -I/usr/include -Wall -Wno-sign-compare -fno-inline -frepo -g -O2 -MT zm_monitor.o -MD -MP -MF .deps/zm_monitor.Tpo -c -o zm_monitor.o zm_monitor.cpp
In file included from zm_rtsp.h:30,
from zm_remote_camera_rtsp.h:27,
from zm_monitor.cpp:34:
zm_sdp.h:222: error: use of enum 'RTSPLowerTransport' without previous declaration
make[2]: *** [zm_monitor.o] Error 1
make[2]: Leaving directory `/usr/src/ZoneMinder-1.24.0/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/ZoneMinder-1.24.0'
make: *** [all] Error 2


Any ideas?? I can post the configure log file, but at 1600+ lines I thought it best to suggest the idea before blindly posting it.

Thanks,
Drew.
majost
Posts: 14
Joined: Sun Oct 12, 2008 9:36 pm

Post by majost »

This appears to be an enum in the lastest version of FFMpeg

See the following url for details: http://cekirdek.pardus.org.tr/~ismail/f ... sp_8h.html

It may be possible to hack together a patch against zoneminder to make this build and function properly.

On a related note -- What MythTV does to avoid these kinds of support and debugging issues is, they import a snapshot of ffmpeg to their trunk and build their library ontop of their imported ffmpeg. I believe their idea is to prevent them from having code break when upstream refactors code, and keep support issues based on unsupported versions of ffmpeg down to a minimum. This said, anyone know if this is on the roadmap for ZoneMinder in the 1.25 release?
majost
Posts: 14
Joined: Sun Oct 12, 2008 9:36 pm

Post by majost »

As stated with my last submitted patch, you can just upgrade your version of ffmpeg -- but if you are in a situation like me, and find that other stuff will break as a result, then here is the patch for the error "
zm_sdp.h:222: error: use of enum 'RTSPLowerTransport' without previous declaration"

Code: Select all

--- ZoneMinder-1.24.0/src/zm_sdp.h	2008-10-16 08:02:41.000000000 -0700
+++ ZoneMinder-1.24.0/src/zm_sdp.h	2008-11-28 23:23:34.000000000 -0800
@@ -219,7 +219,7 @@
     int seq;        /* RTSP command sequence number */
     char session_id[512];
     enum RTSPTransport transport;
-    enum RTSPLowerTransport lower_transport;
+    enum RTSPProtocol rtp_protocol;
     enum RTSPServerType server_type;
     char last_reply[2048]; /* XXX: allocate ? */
     void *cur_tx;
Please note this only fixes the build time error -- and not in a very nice way.I have not actually tested the binary code which this produces. This said, I cannot attest to whether or not the actual RSTP functionality will or will not function as the author intended, nor any other functionality for that matter.

This appears to be the result of some more recent re-factoring, and the check-in notes can be found at the following URL: http://lists.mplayerhq.hu/pipermail/ffm ... 17283.html
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

Thanks majost.

I upgraded the system (recent Slack install) with a bunch of stuff from the slacky.eu site to get ffmpeg and all of it's dependencies installed (why re-invent the wheel when the heavy lifting has already been done?) so your probably right that chances are I'm knackered without doing custom builds outside of ZM 1.24 itself.

I'll give your patch a run when I get a chance and see how it goes.

Thanks again.
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

I ended up deciding to upgrade ffmpeg. Can someone who knows better please look over this configure run of ffmpeg and tell me if I have met all of the requirements for ZoneMinder ?

install prefix /usr
source path /usr/src/build/ffmpeg
C compiler gcc
.align is power-of-two no
ARCH x86_32 (generic)
big-endian no
yasm yes
MMX enabled yes
CMOV enabled no
CMOV is fast no
EBX available yes
EBP available yes
gprof enabled no
debug symbols no
strip symbols yes
optimizations yes
static yes
shared yes
postprocessing support yes
software scaler enabled yes
new filter support no
filters using lavformat no
video hooking yes
Imlib2 support yes
FreeType support yes
network support yes
IPv6 support yes
threading support pthreads
SDL support yes
Sun medialib support no
AVISynth enabled no
libamr-nb support yes
libamr-wb support yes
libdc1394 support yes
libdirac enabled no
libfaac enabled yes
libfaad enabled yes
libfaad dlopened yes
libgsm enabled yes
libmp3lame enabled yes
libnut enabled yes
libschroedinger enabled no
libspeex enabled no
libtheora enabled yes
libvorbis enabled yes
libx264 enabled yes
libxvid enabled yes
zlib enabled yes
bzlib enabled yes

Enabled decoders:
aac flashsv pcm_s32le
aasc flic pcm_s8
ac3 flv pcm_u16be
adpcm_4xm fourxm pcm_u16le
adpcm_adx fraps pcm_u24be
adpcm_ct gif pcm_u24le
adpcm_ea h261 pcm_u32be
adpcm_ea_maxis_xa h263 pcm_u32le
adpcm_ea_r1 h263i pcm_u8
adpcm_ea_r2 h264 pcm_zork
adpcm_ea_r3 huffyuv pcx
adpcm_ea_xas idcin png
adpcm_g726 imc ptx
adpcm_ima_amv indeo2 qdm2
adpcm_ima_dk3 indeo3 qdraw
adpcm_ima_dk4 interplay_dpcm qpeg
adpcm_ima_ea_eacs interplay_video qtrle
adpcm_ima_ea_sead jpegls ra_144
adpcm_ima_qt kmvc ra_288
adpcm_ima_smjpeg libamr_nb rawvideo
adpcm_ima_wav libamr_wb rl2
adpcm_ima_ws libfaad roq
adpcm_ms libgsm roq_dpcm
adpcm_sbpro_2 libgsm_ms rpza
adpcm_sbpro_3 loco rv10
adpcm_sbpro_4 mace3 rv20
adpcm_swf mace6 sgi
adpcm_thp mdec shorten
adpcm_xa mimic smackaud
adpcm_yamaha mjpeg smacker
alac mjpegb smc
amv mlp snow
ape mmvideo sol_dpcm
asv1 motionpixels sonic
asv2 mp2 sp5x
atrac3 mp3 sunrast
avs mp3adu svq1
bethsoftvid mp3on4 svq3
bfi mpc7 targa
bmp mpc8 theora
c93 mpeg1video thp
cavs mpeg2video tiertexseqvideo
cinepak mpeg4 tiff
cljr mpegvideo truemotion1
cook msmpeg4v1 truemotion2
cscd msmpeg4v2 truespeech
cyuv msmpeg4v3 tscc
dca msrle tta
dnxhd msvideo1 txd
dsicinaudio mszh ulti
dsicinvideo nellymoser vb
dvbsub nuv vc1
dvdsub pcm_alaw vcr1
dvvideo pcm_dvd vmdaudio
dxa pcm_f32be vmdvideo
eac3 pcm_f32le vmnc
eacmv pcm_f64be vorbis
eatgq pcm_f64le vp3
eatgv pcm_mulaw vp5
eightbps pcm_s16be vp6
eightsvx_exp pcm_s16le vp6a
eightsvx_fib pcm_s16le_planar vp6f
escape124 pcm_s24be vqa
ffv1 pcm_s24daud wavpack
ffvhuff pcm_s24le wmav1
flac pcm_s32be wmav2
wmv1 ws_snd1 xsub
wmv2 xan_dpcm zlib
wmv3 xan_wc3 zmbv
wnv1 xl

Enabled encoders:
ac3 libmp3lame pcm_u16le
adpcm_adx libtheora pcm_u24be
adpcm_g726 libvorbis pcm_u24le
adpcm_ima_qt libx264 pcm_u32be
adpcm_ima_wav libxvid pcm_u32le
adpcm_ms ljpeg pcm_u8
adpcm_swf mjpeg pcm_zork
adpcm_yamaha mp2 pgm
alac mpeg1video pgmyuv
asv1 mpeg2video png
asv2 mpeg4 ppm
bmp msmpeg4v1 qtrle
dnxhd msmpeg4v2 rawvideo
dvbsub msmpeg4v3 roq
dvdsub nellymoser roq_dpcm
dvvideo pam rv10
ffv1 pbm rv20
ffvhuff pcm_alaw sgi
flac pcm_f32be snow
flashsv pcm_f32le sonic
flv pcm_f64be sonic_ls
gif pcm_f64le svq1
h261 pcm_mulaw targa
h263 pcm_s16be tiff
h263p pcm_s16le vorbis
huffyuv pcm_s24be wmav1
jpegls pcm_s24daud wmav2
libamr_nb pcm_s24le wmv1
libamr_wb pcm_s32be wmv2
libfaac pcm_s32le zlib
libgsm pcm_s8 zmbv
libgsm_ms pcm_u16be

Enabled parsers:
aac dvdsub mpeg4video
ac3 h261 mpegaudio
cavsvideo h263 mpegvideo
dca h264 pnm
dirac mjpeg vc1
dnxhd mlp vp3
dvbsub

Enabled demuxers:
aac ipmovie pcm_u16be
ac3 libnut pcm_u16le
aiff lmlm4 pcm_u24be
amr m4v pcm_u24le
apc matroska pcm_u32be
ape mjpeg pcm_u32le
asf mlp pcm_u8
ass mm pva
au mmf rawvideo
avi mov redir
avs mp3 rl2
bethsoftvid mpc rm
bfi mpc8 roq
c93 mpegps rpl
daud mpegts rtsp
dirac mpegtsraw sdp
dnxhd mpegvideo segafilm
dsicin msnwc_tcp shorten
dts mtv siff
dv mvi smacker
dxa mxf sol
ea nsv str
ea_cdata nut swf
eac3 nuv thp
ffm ogg tiertexseq
flac oma tta
flic pcm_alaw txd
flv pcm_f32be vc1
fourxm pcm_f32le vc1t
gsm pcm_f64be vmd
gxf pcm_f64le voc
h261 pcm_mulaw wav
h263 pcm_s16be wc3
h264 pcm_s16le wsaud
idcin pcm_s24be wsvqa
iff pcm_s24le wv
image2 pcm_s32be xa
image2pipe pcm_s32le yuv4mpegpipe
ingenient pcm_s8

Enabled muxers:
ac3 ipod pcm_f64le
adts libnut pcm_mulaw
aiff m4v pcm_s16be
amr matroska pcm_s16le
asf matroska_audio pcm_s24be
asf_stream mjpeg pcm_s24le
ass mmf pcm_s32be
au mov pcm_s32le
avi mp2 pcm_s8
avm2 mp3 pcm_u16be
crc mp4 pcm_u16le
daud mpeg1system pcm_u24be
dirac mpeg1vcd pcm_u24le
dnxhd mpeg1video pcm_u32be
dts mpeg2dvd pcm_u32le
dv mpeg2svcd pcm_u8
eac3 mpeg2video psp
ffm mpeg2vob rawvideo
flac mpegts rm
flv mpjpeg roq
framecrc mxf rtp
gif null swf
gxf nut tg2
h261 ogg tgp
h263 pcm_alaw vc1t
h264 pcm_f32be voc
image2 pcm_f32le wav
image2pipe pcm_f64be yuv4mpegpipe

Enabled protocols:
file pipe tcp
http rtp udp

Enabled filters:
crop

Enabled bsfs:
dump_extradata mov2textsub noise
h264_mp4toannexb mp3_header_compress remove_extradata
imx_dump_header mp3_header_decompress text2movsub
mjpega_dump_header

Enabled indevs:
dv1394 oss v4l2
libdc1394 v4l x11_grab_device

Enabled outdevs:
oss

License: unredistributable
Creating config.mak and config.h...
Last edited by nuck on Sat Nov 29, 2008 9:34 pm, edited 1 time in total.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Looks good.
A working config for ffmpeg is --enable-shared --enable-swscaler --enable-pthreads --enable-gpl

ZM does not require any of the extra libraries you have compiled in but it certainly shouldn't hurt to have them ;)
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

Thanks Cordel.

ZM built fine this time around. Just had to upgrade x264 (install yasm) and ffmpeg to get it to build. And now it's tinker time :D
Locked