Opened 10 years ago

Closed 10 years ago

#5417 closed defect (fixed)

Cannot build ffmpeg with --enable-libopenh264

Reported by: Sauron Owned by:
Priority: normal Component: avcodec
Version: git-master Keywords: libopenh264
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
How to reproduce:

$ ./configure --enable-fontconfig --enable-gcrypt --enable-libbluray  --enable-libcelt --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenh264 --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libv4l2 --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libxcb --enable-libxcb-shm --enable-libxcb-xfixes --enable-libxcb-shape --enable-opengl --enable-openssl --enable-gpl --enable-nonfree --enable-version3
$ make

Output:

libavcodec/libopenh264enc.c:54:85: error: ‘SM_AUTO_SLICE’ undeclared here (not in a function)
     { "slice_mode", "set slice mode", OFFSET(slice_mode), AV_OPT_TYPE_INT, { .i64 = SM_AUTO_SLICE }, SM_SINGLE_SLICE, SM_RESERVED, VE, "slice_mode" },
                                                                                     ^
libavcodec/libopenh264enc.c:56:87: error: ‘SM_ROWMB_SLICE’ undeclared here (not in a function)
         { "rowmb", "one slice per row of macroblocks", 0, AV_OPT_TYPE_CONST, { .i64 = SM_ROWMB_SLICE }, 0, 0, VE, "slice_mode" },
                                                                                       ^
libavcodec/libopenh264enc.c:58:68: error: ‘SM_DYN_SLICE’ undeclared here (not in a function)
         { "dyn", "Dynamic slicing", 0, AV_OPT_TYPE_CONST, { .i64 = SM_DYN_SLICE }, 0, 0, VE, "slice_mode" },
                                                                    ^
libavcodec/libopenh264enc.c: In function ‘svc_encode_init’:
libavcodec/libopenh264enc.c:196:23: warning: assignment makes integer from pointer without a cast [enabled by default]
         s->slice_mode = SM_DYN_SLICE;
                       ^
libavcodec/libopenh264enc.c:198:28: error: ‘SSpatialLayerConfig’ has no member named ‘sSliceCfg’
     param.sSpatialLayers[0].sSliceCfg.uiSliceMode               = s->slice_mode;
                            ^
libavcodec/libopenh264enc.c:198:38: error: request for member ‘uiSliceMode’ in something not a structure or union
     param.sSpatialLayers[0].sSliceCfg.uiSliceMode               = s->slice_mode;
                                      ^
libavcodec/libopenh264enc.c:198:5: warning: statement with no effect [-Wunused-value]
     param.sSpatialLayers[0].sSliceCfg.uiSliceMode               = s->slice_mode;
     ^
libavcodec/libopenh264enc.c:199:28: error: ‘SSpatialLayerConfig’ has no member named ‘sSliceCfg’
     param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceNum = avctx->slices;
                            ^
libavcodec/libopenh264enc.c:199:38: error: request for member ‘sSliceArgument’ in something not a structure or union
     param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceNum = avctx->slices;
                                      ^
libavcodec/libopenh264enc.c:199:53: error: request for member ‘uiSliceNum’ in something not a structure or union
     param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceNum = avctx->slices;
                                                     ^
libavcodec/libopenh264enc.c:199:5: warning: statement with no effect [-Wunused-value]
     param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceNum = avctx->slices;
     ^
libavcodec/libopenh264enc.c:201:23: warning: comparison between pointer and integer [enabled by default]
     if (s->slice_mode == SM_DYN_SLICE) {
                       ^
libavcodec/libopenh264enc.c:204:36: error: ‘SSpatialLayerConfig’ has no member named ‘sSliceCfg’
             param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceSizeConstraint = s->max_nal_size;
                                    ^
libavcodec/libopenh264enc.c:204:46: error: request for member ‘sSliceArgument’ in something not a structure or union
             param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceSizeConstraint = s->max_nal_size;
                                              ^
libavcodec/libopenh264enc.c:204:61: error: request for member ‘uiSliceSizeConstraint’ in something not a structure or union
             param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceSizeConstraint = s->max_nal_size;
                                                             ^
libavcodec/libopenh264enc.c:204:13: warning: statement with no effect [-Wunused-value]
             param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceSizeConstraint = s->max_nal_size;
             ^
common.mak:60: ошибка выполнения рецепта для цели «libavcodec/libopenh264enc.o»

Used the last snapshot of libopenh264 from https://github.com/cisco/openh264.

ffmpeg version: N-79222-gc9ad357 (from VERSION file)

Change History (5)

comment:1 by Carl Eugen Hoyos, 10 years ago

Priority: importantnormal
Status: newopen

comment:2 by darksab0r, 10 years ago

Yes, the building is broken with openh264 1.6+

in reply to:  1 comment:3 by marillat, 10 years ago

Replying to cehoyos:

Feel free to test this patch:
http://ffmpeg.org/pipermail/ffmpeg-devel/2016-March/190980.html

This patch fix this build.

comment:4 by bermond, 10 years ago

I can confirm that this issue is fixed by git commit 293676c476733e81d7b596736add6cd510eb6960.

Now FFmpeg git master vesion compiles correctly with latest OpenH264 1.6.0.

Last edited 10 years ago by bermond (previous) (diff)

comment:5 by Carl Eugen Hoyos, 10 years ago

Resolution: fixed
Status: openclosed
Note: See TracTickets for help on using tickets.