[FFmpeg-devel] [PATCH]Only enable xcb-shm if error fields are?available in the header

Clément Bœsch u at pkh.me
Thu Dec 25 19:46:42 CET 2014


On Thu, Dec 25, 2014 at 05:52:36PM +0000, Carl Eugen Hoyos wrote:
> Carl Eugen Hoyos <cehoyos <at> ag.or.at> writes:
> 
> > Clément Bœsch <u <at> pkh.me> writes:
> > 
> > > > -        check_pkg_config xcb-shm xcb/shm.h xcb_shm_attach || {
> > > > +        check_pkg_config xcb-shm xcb/shm.h xcb_shm_attach &&
> > > > +        check_code cc xcb/xcb.h "xcb_generic_error_t e; 
> > > > e.resource_id = 0" || {
> > > 
> > > No, you just want something like check_pkg_config "xcb-shm >= 1.4"
> 
> Could you provide a patch that I could test?
> (I don't think your idea works but since I 
> don't know much about pkg-config, I may miss 
> something.)
> 

Assuming the ticket is correct according to the versions, this should do the
trick:

diff --git a/configure b/configure
index 9085200..9b33234 100755
--- a/configure
+++ b/configure
@@ -5063,7 +5063,7 @@ if ! disabled libxcb; then
 
 if enabled libxcb; then
     disabled libxcb_shm || {
-        check_pkg_config xcb-shm xcb/shm.h xcb_shm_attach || {
+        check_pkg_config "xcb-shm >= 1.4" xcb/shm.h xcb_shm_attach || {
             enabled libxcb_shm && die "ERROR: libxcb_shm not found";
         } && check_header sys/shm.h && enable libxcb_shm; }
 

[...]

-- 
Clément B.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20141225/6f676f07/attachment.asc>


More information about the ffmpeg-devel mailing list