[FFmpeg-trac] #1428(build system:new): Several missing dependencies in the build system

FFmpeg trac at avcodec.org
Thu Jun 7 23:13:41 CEST 2012


#1428: Several missing dependencies in the build system
-------------------------------------+-------------------------------------
             Reporter:  jamal        |                     Type:  defect
               Status:  new          |                 Priority:  normal
            Component:  build        |                  Version:  git-
  system                             |  master
             Keywords:  amv latm     |               Blocked By:
  jacosub dirac dwt iac              |  Reproduced by developer:  0
             Blocking:               |
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------
 Here are some more missing dependencies i found thanks to Mans' --enable-
 random option.

 ----

 {{{
 ./configure --disable-everything --enable-encoder=amv
 }}}
 fails with
 {{{
 LD      ffmpeg_g.exe
 libavcodec/libavcodec.a(utils.o): In function `avcodec_get_name':
 D:\msys\1.0\home\jamal\ffmpeg/./libavcodec/codec_names.h:221: undefined
 reference to `ff_amv_encoder'
 libavcodec/libavcodec.a(allcodecs.o): In function `avcodec_register_all':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/allcodecs.c:75: undefined
 reference to `ff_amv_encoder'
 collect2: ld returned 1 exit status
 make: *** [ffmpeg_g.exe] Error 1
 }}}

 The amv encoder has no entry in libavcodec/Makefile.
 It uses the same files as the mjpeg encoder so it's a matter of
 duplicating the mjpeg entry for it:
 {{{
 OBJS-$(CONFIG_AMV_ENCODER)             += mjpegenc.o mjpeg.o           \
                                           mpegvideo_enc.o motion_est.o \
                                           ratecontrol.o mpeg12data.o   \
                                           mpegvideo.o
 }}}
 Also, like the mjpeg encoder it needs to enable aandct in the configure
 script:
 {{{
 amv_encoder_select="aandct"
 }}}

 ----
 {{{
 ./configure --disable-everything --enable-muxer=jacosub
 ./configure --disable-everything --enable-muxer=latm
 }}}
 Fail with
 {{{
 LD      ffmpeg_g.exe
 libavformat/libavformat.a(jacosubenc.o):jacosubenc.c:(.data+0x34):
 undefined reference to `ff_raw_write_packet'
 collect2: ld returned 1 exit status
 make: *** [ffmpeg_g.exe] Error 1
 }}}
 and
 {{{
 LD      ffmpeg_g.exe
 libavformat/libavformat.a(latmenc.o): In function `latm_write_packet':
 D:\msys\1.0\home\jamal\ffmpeg/libavformat/latmenc.c:153: undefined
 reference to `ff_raw_write_packet'
 collect2: ld returned 1 exit status
 make: *** [ffmpeg_g.exe] Error 1
 }}}

 Both the latm and jacosub muxers need rawenc.c to be compiled.
 On libavformat/Makefile
 {{{
 OBJS-$(CONFIG_JACOSUB_MUXER)             += jacosubenc.o
 ...
 OBJS-$(CONFIG_LATM_MUXER)                += latmenc.o
 }}}
 Should be
 {{{
 OBJS-$(CONFIG_JACOSUB_MUXER)             += jacosubenc.o rawenc.o
 ...
 OBJS-$(CONFIG_LATM_MUXER)                += latmenc.o rawenc.o
 }}}

 ----
 {{{
 ./configure --disable-everything --enable-decoder=dirac
 }}}
 fails with

 {{{
 LD      ffmpeg_g.exe
 libavcodec/libavcodec.a(diracdec.o): In function `svq3_get_ue_golomb':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/golomb.h:132: undefined reference
 to `ff_interleaved_dirac_golomb_vlc_code'
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/golomb.h:128: undefined reference
 to `ff_interleaved_golomb_vlc_len'
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/golomb.h:135: undefined reference
 to `ff_interleaved_dirac_golomb_vlc_code'
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/golomb.h:119: undefined reference
 to `ff_interleaved_golomb_vlc_len'
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/golomb.h:122: undefined reference
 to `ff_interleaved_ue_golomb_vlc_code'

 ...
 [Another few dozen golomb errors here from different functions]
 ...

 libavcodec/libavcodec.a(dwt.o): In function `ff_dwt_init':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/dwt.c:994: undefined reference to
 `ff_snow_inner_add_yblock'
 libavcodec/libavcodec.a(dwt.o): In function `ff_spatial_idwt_init2':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/dwt.c:1504: undefined referenceto
 `ff_spatial_idwt_init_mmx'
 libavcodec/libavcodec.a(dwt.o): In function `ff_dwt_init':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/dwt.c:997: undefined reference to
 `ff_dwt_init_x86'
 }}}

 This shows that the Dirac decoder depends on dwt and golomb, and that dwt
 needs snow.c
 Adding
 {{{
 dirac_decoder_select="dwt golomb"
 }}}
 To the configure script, and making
 {{{
 OBJS-$(CONFIG_DWT)                     += dwt.o
 }}}
 be
 {{{
 OBJS-$(CONFIG_DWT)                     += dwt.o snow.o
 }}}
 in libavcodec/Makefile fixes this.

 Also, you can remove dwt.o from the dirac decoder dependencies in
 libavcodec/Makefile now that dwt will be enabled with the configure
 addition.

 ----

 {{{
 ./configure --disable-everything --enable-decoder=iac
 }}}
 fails with
 {{{
 LD      ffmpeg_g.exe
 libavcodec/libavcodec.a(imc.o): In function `imc_decode_close':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/imc.c:933: undefined reference to
 `ff_fft_end'
 libavcodec/libavcodec.a(imc.o): In function `imc_decode_init':
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/imc.c:140: undefined reference to
 `ff_sine_window_init'
 D:\msys\1.0\home\jamal\ffmpeg/libavcodec/imc.c:188: undefined reference to
 `ff_fft_init'
 collect2: ld returned 1 exit status
 make: *** [ffmpeg_g.exe] Error 1
 }}}

 This is the new Indeo Audio decoder added a few days ago. It simply needs
 a line in the configure script:

 {{{
 iac_decoder_select="fft mdct sinewin"
 }}}

 Which is a copy of the imc decoder one, given that both share the same
 functions.
 I'm not sure why mdct is in there, though, since it doesn't seem to be
 used by these decoders.

 ----

 Sorry for taking a few days reporting these, since now they wont make it
 to ffmpeg 0.11.1
 I had this ready but got sidetracked with the dirac crash from the other
 ticket.

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/1428>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list