Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#31347 - [skype] no webcam support in multilib without LD_PRELOAD

Attached to Project: Community Packages
Opened by PiousMinion (PiousMinion) - Thursday, 30 August 2012, 23:46 GMT
Last edited by Thomas Bächler (brain0) - Monday, 03 September 2012, 09:19 GMT
Task Type Bug Report
Category Packages: Multilib
Status Closed
Assigned To Florian Pritz (bluewind)
Architecture x86_64
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
Webcam support for skype in multilib does not work at all without starting it as follows:
LD_PRELOAD=/usr/lib32/libv4l/v4l1compat.so skype

Evidence of this can be found all over the place including arch wiki pages for skype and webcam support:
https://www.google.com/search?q=site:archlinux.org+skype+LD_PRELOAD

Additional info:
4.0.0.8-1

Steps to reproduce:
Install skype and lib32-v4l-utils.
Fire up skype normally and notice your camera doesn't work.
This task depends upon

Closed by  Thomas Bächler (brain0)
Monday, 03 September 2012, 09:19 GMT
Reason for closing:  Implemented
Comment by Jelle van der Waa (jelly) - Friday, 31 August 2012, 12:21 GMT
This really depends on you're webcam, so I don't think the package will change.
Comment by PiousMinion (PiousMinion) - Friday, 31 August 2012, 14:03 GMT
It actually depends on hundreds upon hundreds of known webcams and many more which are unknown, not just mine.
http://mxhaard.free.fr/spca5xx.html

Correct if wrong, but doesn't this affect any webcam that doesn't have a v4l2 driver? If so, then it affects far more webcams than I first imagined.
Comment by Thomas Bächler (brain0) - Sunday, 02 September 2012, 16:16 GMT
You are entirely incorrect. v4l1convert allows v4l1 applications to use v4l2 drivers (and skype uses v4l2, not v4l1). Current Linux kernels do not support v4l1 drivers at all.

The PRELOAD file that should be used is in fact v4l2convert.so. Using that wrapper is a good idea regardless of whether your camera works as-is or not.

From the v4l-utils documentation:

wrappers
--------

The functionality provided by libv4l1 for v4l1 apps and libv4l2 for v4l2 apps
can also be used by existing apps without modifying them. For this purpose
2 wrapper libraries are provided which can be preloaded before starting the
application using the LD_PRELOAD environment variable. These wrappers will
then intercept calls to open/close/ioctl/etc. and if these calls directed
towards a video device the wrapper will redirect the call to the libv4lX
counterparts.

The preloadable libv4l1 wrapper which adds v4l2 device compatibility to v4l1
applications is called v4l1compat.so. The preloadable libv4l2 wrapper which
adds support for various pixelformats to v4l2 applications is called
v4l2convert.so.
Comment by Florian Pritz (bluewind) - Sunday, 02 September 2012, 17:41 GMT
I've added a wrapper script to skype 4.0.0.8-2, please test.
Comment by Met Merilius (merilius) - Sunday, 02 September 2012, 20:22 GMT
The previous release (1) used to work for me, and the camera was working too.
Now (release 2) I am getting error messages and skype crashes occasionally (my camera works):

$ skype
ERROR: ld.so: object '/usr/lib32/libv4l/v4l1compat.so' from LD_PRELOAD cannot be preloaded: ignored. # <-- at startup
libv4l2: error dequeuing buf: Invalid argument # <-- at camera preview window destruction
unregistered interface queried # <-- at exit (happened only once)
unregistered interface queried
Aborted
Comment by Thomas Bächler (brain0) - Sunday, 02 September 2012, 20:36 GMT
Met, I don't know what you have done, but your first error message shows that you probably exported LD_PRELOAD=... into your general environment. This is a very bad idea.
Comment by Thomas Bächler (brain0) - Sunday, 02 September 2012, 20:43 GMT
BTW, "libv4l2: error dequeuing buf: Invalid argument" - this happens to me too, I remember that it always happened.
Comment by Met Merilius (merilius) - Sunday, 02 September 2012, 21:46 GMT
Thanks Thomas, my mistake. I haven't exported LD_PRELOAD globally but made a similar trick. Long time ago I set alias skype='LD_PRELOAD=/usr/lib32/libv4l/v4l1compat.so skype' (note v4l1compat.so, not v4l2convert.so) and forgot about it. Now when I unalias'ed skype, skype loads without this error message. The second error (dequeuing) appears only with v4l2convert.so set. And my camera works even if I don't preload anything.
Comment by PiousMinion (PiousMinion) - Monday, 03 September 2012, 07:43 GMT
4.0.0.8-2 is working flawlessly for me.
Unless others are having issues I'd consider this closed.

Thank you for the prompt resolution. :)

Loading...