dfaulkner
June 11th, 2006, 08:23 PM
Hi All, I'm trying to build ZoneMinder on Ubuntu (my first zm build and my first on ubuntu). I'm a long-time Linux hack, but I've new to the world of video codecs.
:idea:Update: see my reply (http://ubuntuforums.org/showthread.php?p=1127342#post1127342) to this post for my solution.
This is the last command executed by make (wrapped for convenience), along with the error(s) I get:
g++ -g -O3 -march=pentium4 -L/usr/lib -L/usr/lib/mysql \
-ldc1394_control -logg -ldts -lvorbisenc -ltheora -lgsm \
-o zmc zmc.o zm.o zm_db.o zm_config.o zm_coord.o zm_box.o zm_poly.o \
zm_image.o zm_event.o zm_zone.o zm_camera.o zm_local_camera.o \
zm_remote_camera.o zm_file_camera.o zm_monitor.o zm_user.o zm_mpeg.o \
zm_jpeg.o zm_regexp.o zm_signal.o zm_buffer.o zm_debug.o \
-lavformat -lavcodec -lavutil -lpcre -lcrypto -lmysqlclient -ldl -lz -ljpeg
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_init': undefined reference to `dts_init'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_frame'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_blocks_num'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_block'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_samples'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_blocks_num'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_syncinfo'
collect2: ld returned 1 exit status
I believe I've specified all the correct libraries. For completeness, here is the configure command I'm using:
./configure \
--with-webdir=/var/www/zm/html \
--with-cgidir=/var/www/zm/cgi \
--with-webuser=www-data \
--with-webgroup=www-data \
--with-extralibs="-ldc1394_control -logg -ldts -lvorbisenc -ltheora -lgsm" \
CFLAGS="-g -O3 -march=pentium4" \
CXXFLAGS="-g -O3 -march=pentium4" \
ZM_DB_NAME=zm \
ZM_DB_USER=zm \
ZM_DB_PASS=*******
I've installed the build-essential package and the following packages that I believe are needed by Zone Minder:
libmysqlclient15-dev # mysql client headers
libjpeg62 libjpeg-progs libjpeg62-dev # JPEG libraries and development files
ffmpeg ffmpeg2theora libfreetype6-dev libavcodec-dev libavformat-dev # MPEG video encoding.
libssl-dev openssl libssl0.9.8-dbg libssl0.9.8 # because the docs said I'd need SSL
libpcre3 libpcre3-dev # because configure complained.
libdate-manip-perl # for Date::Manip
libwww-perl libio-socket-ssl-perl libmailtools-perl libhtml-format-perl libcompress-zlib-perl # for LWP and associated libraries
libdevice-serialport-perl # for RS232 PTZ control
libarchive-tar-perl libarchive-zip-perl # for automatic event uploading
libmime-perl libmime-lite-perl # for automatic event email notification
Configure still complains about a missing X10::ActiveHome perl module but (1) it's not packaged within ubuntu, and (2) I don't need it.
I tried to install the following packages, but they were already installed:
libdc1394-dev libogg-dev libvorbis-dev libtheora-dev libgsm1-dev libdts-dev
My first attempt at the build was without the --with-extralibs option passed to configure. As you might imagine, the linker errors were much longer. After I added in the extralibs, including -ldts, Every other undefined reference error went away, but the errors relating to libdts remain.
I've checked /usr/lib/libdts.a and /usr/lib/libdts_pic.a with nm, and I get exactly what I expect (output below edited for length):
$ nm /usr/lib/libdts.a
parse.o:
[...]
00003bbe T dts_block
0000000b T dts_blocks_num
00000000 r dts_channels
U dts_downmix
U dts_downmix_init
0000020a T dts_dynrng
00000798 T dts_frame
00000235 T dts_free
00000020 T dts_init
000000a0 r dts_sample_rates
00000000 T dts_samples
000016b2 T dts_subframe_footer
000017f3 T dts_subframe_header
00002a19 T dts_subsubframe
00000654 T dts_syncinfo
[...]
I see no reason why I shouldn't be able to link against /usr/lib/libdts.a. :confused:Am I missing something obvious? Thanks very much for any assistance you can offer.
:idea:Update: see my reply (http://ubuntuforums.org/showthread.php?p=1127342#post1127342) to this post for my solution.
This is the last command executed by make (wrapped for convenience), along with the error(s) I get:
g++ -g -O3 -march=pentium4 -L/usr/lib -L/usr/lib/mysql \
-ldc1394_control -logg -ldts -lvorbisenc -ltheora -lgsm \
-o zmc zmc.o zm.o zm_db.o zm_config.o zm_coord.o zm_box.o zm_poly.o \
zm_image.o zm_event.o zm_zone.o zm_camera.o zm_local_camera.o \
zm_remote_camera.o zm_file_camera.o zm_monitor.o zm_user.o zm_mpeg.o \
zm_jpeg.o zm_regexp.o zm_signal.o zm_buffer.o zm_debug.o \
-lavformat -lavcodec -lavutil -lpcre -lcrypto -lmysqlclient -ldl -lz -ljpeg
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_init': undefined reference to `dts_init'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_frame'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_blocks_num'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_block'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_samples'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_blocks_num'
/usr/lib/libavcodec.a(dtsdec.o): In function `dts_decode_frame': undefined reference to `dts_syncinfo'
collect2: ld returned 1 exit status
I believe I've specified all the correct libraries. For completeness, here is the configure command I'm using:
./configure \
--with-webdir=/var/www/zm/html \
--with-cgidir=/var/www/zm/cgi \
--with-webuser=www-data \
--with-webgroup=www-data \
--with-extralibs="-ldc1394_control -logg -ldts -lvorbisenc -ltheora -lgsm" \
CFLAGS="-g -O3 -march=pentium4" \
CXXFLAGS="-g -O3 -march=pentium4" \
ZM_DB_NAME=zm \
ZM_DB_USER=zm \
ZM_DB_PASS=*******
I've installed the build-essential package and the following packages that I believe are needed by Zone Minder:
libmysqlclient15-dev # mysql client headers
libjpeg62 libjpeg-progs libjpeg62-dev # JPEG libraries and development files
ffmpeg ffmpeg2theora libfreetype6-dev libavcodec-dev libavformat-dev # MPEG video encoding.
libssl-dev openssl libssl0.9.8-dbg libssl0.9.8 # because the docs said I'd need SSL
libpcre3 libpcre3-dev # because configure complained.
libdate-manip-perl # for Date::Manip
libwww-perl libio-socket-ssl-perl libmailtools-perl libhtml-format-perl libcompress-zlib-perl # for LWP and associated libraries
libdevice-serialport-perl # for RS232 PTZ control
libarchive-tar-perl libarchive-zip-perl # for automatic event uploading
libmime-perl libmime-lite-perl # for automatic event email notification
Configure still complains about a missing X10::ActiveHome perl module but (1) it's not packaged within ubuntu, and (2) I don't need it.
I tried to install the following packages, but they were already installed:
libdc1394-dev libogg-dev libvorbis-dev libtheora-dev libgsm1-dev libdts-dev
My first attempt at the build was without the --with-extralibs option passed to configure. As you might imagine, the linker errors were much longer. After I added in the extralibs, including -ldts, Every other undefined reference error went away, but the errors relating to libdts remain.
I've checked /usr/lib/libdts.a and /usr/lib/libdts_pic.a with nm, and I get exactly what I expect (output below edited for length):
$ nm /usr/lib/libdts.a
parse.o:
[...]
00003bbe T dts_block
0000000b T dts_blocks_num
00000000 r dts_channels
U dts_downmix
U dts_downmix_init
0000020a T dts_dynrng
00000798 T dts_frame
00000235 T dts_free
00000020 T dts_init
000000a0 r dts_sample_rates
00000000 T dts_samples
000016b2 T dts_subframe_footer
000017f3 T dts_subframe_header
00002a19 T dts_subsubframe
00000654 T dts_syncinfo
[...]
I see no reason why I shouldn't be able to link against /usr/lib/libdts.a. :confused:Am I missing something obvious? Thanks very much for any assistance you can offer.