Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#4067 closed defect (fixed)

build failure due to old libxcb (1.8.1-2+deb7u1 debian wheezy)

Reported by: kevmitch Owned by:
Priority: important Component: avdevice
Version: git-master Keywords: xcb
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

On git master (32e666c354e4a3160d8cf1d303cb51990b095c87)

$./configure
<attached>
$ make


CC libavdevice/alldevices.o
CC libavdevice/alsa-audio-common.o
CC libavdevice/alsa-audio-dec.o
CC libavdevice/alsa-audio-enc.o
CC libavdevice/avdevice.o
CC libavdevice/dv1394.o
CC libavdevice/fbdev_common.o
CC libavdevice/fbdev_dec.o
CC libavdevice/fbdev_enc.o
CC libavdevice/jack_audio.o
CC libavdevice/lavfi.o
CC libavdevice/oss_audio.o
CC libavdevice/oss_audio_dec.o
CC libavdevice/oss_audio_enc.o
CC libavdevice/timefilter.o
CC libavdevice/v4l2-common.o
CC libavdevice/v4l2.o
CC libavdevice/v4l2enc.o
CC libavdevice/xcbgrab.o
libavdevice/xcbgrab.c:50:5: error: unknown type name ‘xcb_shm_seg_t’
libavdevice/xcbgrab.c: In function ‘setup_window’:
libavdevice/xcbgrab.c:581:5: error: implicit declaration of function ‘xcb_shape_rectangles’ [-Werror=implicit-function-declaration]
libavdevice/xcbgrab.c:581:35: error: ‘XCB_SHAPE_SO_SUBTRACT’ undeclared (first use in this function)
libavdevice/xcbgrab.c:581:35: note: each undeclared identifier is reported only once for each function it appears in
libavdevice/xcbgrab.c:582:26: error: ‘XCB_SHAPE_SK_BOUNDING’ undeclared (first use in this function)
cc1: some warnings being treated as errors
make: * [libavdevice/xcbgrab.o] Error 1

Build works fine with libxcb=1.10-3 on Debian unstable/testing

Attachments (2)

configure.result (10.8 KB ) - added by kevmitch 10 years ago.
configure output with libxcb1-dev=1.8.1-2+deb7u1
patchx11xcb.diff (1.1 KB ) - added by Carl Eugen Hoyos 10 years ago.

Download all attachments as: .zip

Change History (11)

by kevmitch, 10 years ago

Attachment: configure.result added

configure output with libxcb1-dev=1.8.1-2+deb7u1

comment:1 by kevmitch, 10 years ago

Component: undeterminedavdevice
Keywords: xcb added
Version: unspecifiedgit-master

comment:2 by Carl Eugen Hoyos, 10 years ago

Could you provide the output of the following command?

$ grep XCB config.h

comment:3 by kevmitch, 10 years ago

$ grep XCB config.h
#define CONFIG_LIBXCB 1
#define CONFIG_LIBXCB_SHM 0
#define CONFIG_LIBXCB_XFIXES 0
#define CONFIG_X11GRAB_XCB_INDEV 1

by Carl Eugen Hoyos, 10 years ago

Attachment: patchx11xcb.diff added

comment:4 by Carl Eugen Hoyos, 10 years ago

Does attached patch change anything in the output of make libavdevice/xcbgrab.o?

comment:5 by kevmitch, 10 years ago

Yes, that seems to fix it

$ make libavdevice/xcbgrab.o
CC      libavdevice/xcbgrab.o
libavdevice/xcbgrab.c: In function ‘setup_window’:
libavdevice/xcbgrab.c:583:5: warning: "XCB_SHAPE_RECTANGLES" is not defined [-Wundef]
libavdevice/xcbgrab.c:567:21: warning: unused variable ‘rect’ [-Wunused-variable]

comment:6 by Carl Eugen Hoyos, 10 years ago

I believe the fix is not yet complete but could you test the following with my first patch applied?

$ ffmpeg -f x11grab -i :0 -t 10 -qscale 2 -y out.mov

Is out.mov created and is it playable?

Could you provide the output of the following command?

$ ls -l /usr/include/xcb

comment:7 by kevmitch, 10 years ago

yes, the mov is playable. It does however only cover the top left 640x480 pixels. Not sure if it was supposed to grab my whole screen or not.

$ ls -l /usr/include/xcb
total 936
-rw-r--r-- 1 root root 461305 May 15  2013 xproto.h
-rw-r--r-- 1 root root  12293 May 15  2013 xc_misc.h
-rw-r--r-- 1 root root  17847 May 15  2013 xcb.h
-rw-r--r-- 1 root root   3887 May 15  2013 xcbext.h
-rw-r--r-- 1 root root 447460 May 15  2013 glx.h
-rw-r--r-- 1 root root   3674 May 15  2013 bigreq.h

comment:8 by Carl Eugen Hoyos, 10 years ago

Priority: normalimportant
Reproduced by developer: set
Resolution: fixed
Status: newclosed

I committed my patch above as 792f0f20456cc24f1f1b9ee445e50737d65e38df and 8c0ae9015a2bd8b3f4f92c35570e592e7fdeaef0
The fix should be improved but since this is a build failure I pushed the small change.
Thank you for the report and thank you for testing!

in reply to:  7 comment:9 by Carl Eugen Hoyos, 10 years ago

Replying to kevmitch:

yes, the mov is playable. It does however only cover the top left 640x480 pixels. Not sure if it was supposed to grab my whole screen or not.

vga is the default for -video_size / -s for x11grab, I believe this is documented.

Note: See TracTickets for help on using tickets.