Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 149794 - libI810XvMC.so is missing a link to libdrm.so
Summary: libI810XvMC.so is missing a link to libdrm.so
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal
Assignee: Gentoo X packagers
URL: https://bugs.freedesktop.org/show_bug...
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks:
 
Reported: 2006-10-01 17:49 UTC by Kai Krakow
Modified: 2007-05-13 17:14 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
config log of failed linking of the conftest program (config.log.gz,23.06 KB, application/x-gzip)
2006-10-15 14:18 UTC, Kai Krakow
Details
i810xvmc.patch (i810xvmc.patch,453 bytes, patch)
2007-01-13 20:27 UTC, Joshua Baergen (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kai Krakow 2006-10-01 17:49:03 UTC
I have VIDEO_CARDS="i810" and USE="xvmc" enabled, and emerging xine-lib does not create xineplug_vo_out_xvmc.so output plugin. This is because the configure script fails on some symbols when linking the test program against libI810XvMC.so. The failing symbols are drm_* because libdrm.so is not linked.

I used "ebuild xine-lib...ebuild unpack compile" to unpack the source and starting the configure script. During configure I interrupted and changed it to use "-lI810XvMC -ldrm" instead of only "-lI810XvMC". Now the test does not fail, the missing library is build. This should be fixed but I am too unfamiliar with autotools to provide a patch. Also I am not sure if this is hitting I810 users only.
Comment 1 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-10-01 21:18:04 UTC
In theory, libI810XvMC should take care of its own NEEDED dependencies.
X11 team can you confirm that the library needs to be linked to libdrm to work? In that case, I'd say the library misses to link to it from upstream (and will fail with --as-needed too).
Comment 2 Joshua Baergen (RETIRED) gentoo-dev 2006-10-02 07:38:25 UTC
As far as I know, the i810 driver does need a libdrm link as long as i810 is built +dri.  Otherwise, I don't believe the link is made.

I'm not sure about the specific libraries, but glancing at the xvmc code it does look like it should be linked against libdrm.
Comment 3 Kai Krakow 2006-10-02 10:53:03 UTC
So, xine-lib should check if xf86-video-i810 was built with the dri-useflag and link the configure check against the xvmc-driver accordingly. But I am pretty sure i810-xvmc won't work without dri anyway. Well, my dri-useflag is set. BTW xvmc still doesn't work for me because xine-lib now finds xvmc but cannot initialize the xvmc surface - but this is another story. At least I now have something to try with. ;-)
Comment 4 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-10-02 11:03:24 UTC
Uh, no, xine-lib should not check anything. I'd rather say that i810 driver should be fixed to fullfill its own dependencies.
Comment 5 Kai Krakow 2006-10-02 12:37:08 UTC
Well, it works later when the xvmc-driver is loaded dynamically by xine-lib. It just doesn't pass the configure test which links statically (as far as I understood).
Comment 6 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-10-02 12:52:17 UTC
Can you attach the failed config.log?
Comment 7 Kai Krakow 2006-10-02 15:34:44 UTC
I'll provide the "failed" config.log later... Well, however it does not really fail. It just fails the i810-xvmc test and disables xvmc support. Do you also need other logs?
Comment 8 Joshua Baergen (RETIRED) gentoo-dev 2006-10-07 17:22:12 UTC
Attaching the config.log would still be helpful.
Comment 9 Kai Krakow 2006-10-12 08:10:51 UTC
(In reply to comment #8)
> Attaching the config.log would still be helpful.

I'll take some time to do that on the weekend... Hold on. ;-)

Comment 10 Kai Krakow 2006-10-15 14:18:00 UTC
Created attachment 99762 [details]
config log of failed linking of the conftest program

The problem can be found at around line 1714 in the log:

configure:30527: i686-pc-linux-gnu-gcc -o conftest -DENABLE_IPV6 -Os -march=pentium3 -mtune=pentium3 -mcpu=pentium3 -pipe -msse -mmmx -fomit-frame-pointer -mfpmath=387,ss
e -fweb -frename-registers -funit-at-a-time -ftracer -frename-registers -ffunction-sections   -Wl,-O1 -Wl,--sort-common -z combreloc -Wl,--enable-new-dtags conftest.c -lI
810XvMC -L//usr/lib -lXvMC   -lSM -lICE -lXv -lXext   >&5
/var/tmp/portage/xine-lib-1.1.2-r2/temp/ccNToy8b.o: In function `main':
conftest.c:(.text.main+0x1): undefined reference to `XvMCPutSlice'
//usr/lib/libI810XvMC.so: undefined reference to `drmCommandWriteRead'
//usr/lib/libI810XvMC.so: undefined reference to `drmCommandWrite'
...
Comment 11 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-10-15 23:47:36 UTC
So it seems that libI810XvMC is not linking libdrm when it'sreally needed. The problem is, anyway, that the library does not provide XvMCPutSlice which means the test will fail anyway.

X11 if you want to fix the linking, but it won't help xine-lib I'm afraid... anyway next xine-lib version will just use XvMCW and be done with it.

And for your information, --enable-new-dtags is totally useless in Gentoo.
Comment 12 Kai Krakow 2006-10-16 02:40:04 UTC
Hi!

(In reply to comment #11)
> And for your information, --enable-new-dtags is totally useless in Gentoo.

This may come from my LD_FLAGS set in make.conf... But well, why is it useless? Just to feed my curiousness? ;-)
Comment 13 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-10-16 02:46:05 UTC
Because it is forced on in Gentoo.
Comment 14 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-11-30 19:10:58 UTC
This is probably a problem of the driver itself rather than mine. But it's also fixed in 1.1.3 as it links to libXvMCW and it does not even use link tests, so...
Comment 15 Joshua Baergen (RETIRED) gentoo-dev 2007-01-13 17:50:19 UTC
Bug filed upstream.

Diego, you probably don't care about this bug anymore, but I'll let you remove yourself from CC.  Thanks for spotting the issue :)
Comment 16 Joshua Baergen (RETIRED) gentoo-dev 2007-01-13 20:26:42 UTC
Bug has been fixed upstream.
Comment 17 Joshua Baergen (RETIRED) gentoo-dev 2007-01-13 20:27:12 UTC
Created attachment 106847 [details, diff]
i810xvmc.patch

Fixes XvMC linking.
Comment 18 Joshua Baergen (RETIRED) gentoo-dev 2007-01-14 00:24:01 UTC
Comment on attachment 106847 [details, diff]
i810xvmc.patch

The fix has been fixed upstream. :)
Comment 19 Joshua Baergen (RETIRED) gentoo-dev 2007-04-14 17:40:59 UTC
This will be fixed in the 2.0 release of the i810/intel driver.
Comment 20 Joshua Baergen (RETIRED) gentoo-dev 2007-05-13 17:14:27 UTC
(In reply to comment #19)
> This will be fixed in the 2.0 release of the i810/intel driver.
> 

Which has been in the tree for a while.  Closing.