Subject: Re: xmms-infinity plugin -- work in progress
To: Tomasz Luchowski <zuntum@netbsd.org>
From: Oleg Polianski <Oleg.Polianski@clear.co.nz>
List: tech-pkg
Date: 08/16/2001 18:48:32
Tomasz Luchowski <zuntum@netbsd.org> writes:

 Well, actually `libXf86dga' is not compiled in PIC by default so this
 approach should not work at all. You need to recompile `libXf86dga' with
 `-fPIC' option to get it really work.

> I remember I used to do something similair with libXdpms.a to make avifile happy,
> now I did:
> 	cd /usr/X11R6
> 	cc -shared -o libXxf86dga.so.0.0 libXxf86dga.a
>         ln -sf libXxf86dga.so.0.0 libXxf86dga.so.0
> 
> And the plugin compiled. It works "properly" (displays something), locks xmms
> permanently, though. Sound stops working, I can see only video. I can't even close
> preferences menu.
> 
> When additionally I tried doing:
> 	ln -s sf libXxf86dga.so.0 libXxf86dga.so, the package does not want to compile:
> 
> checking for SDL - version >= 1.0.6... no
> 
> config.log says:
> 
> configure:2546: cc -o conftest -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include -O2 -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include/SDL -D_REENTRANT -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include  -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib  -Wl,-R/usr/pkg/lib -Wl,-R/usr/pkg/lib conftest.c -lintl -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib -Wl,-R/usr/pkg/lib -Wl,-rpath,/usr/pkg/lib -Wl,-rpath,/usr/X11R6/lib -lSDL -lpthread -lm -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib -Wl,-R/usr/pkg/lib -lesd -laudiofile -lm -lossaudio -L/usr/X11R6/lib -lX11 -lXext -lXxf86vm -lXxf86dga 1>&5
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryVersion'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryDirectVideo'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryExtension'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGADirectVideo'
> collect2: ld returned 1 exit status
> 
> When I built shared version of libXxf86vm (with so.0 -> so link) I get even more undefined references:
> 
> configure:2546: cc -o conftest -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include -O2 -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include/SDL -D_REENTRANT -I/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/include  -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib  -Wl,-R/usr/pkg/lib -Wl,-R/usr/pkg/lib conftest.c -lintl -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib -Wl,-R/usr/pkg/lib -Wl,-rpath,/usr/pkg/lib -Wl,-rpath,/usr/X11R6/lib -lSDL -lpthread -lm -L/usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib -Wl,-R/usr/pkg/lib -lesd -laudiofile -lm -lossaudio -L/usr/X11R6/lib -lX11 -lXext -lXxf86vm -lXxf86dga 1>&5
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeQueryVersion'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeSetViewPort'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryVersion'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeQueryExtension'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryDirectVideo'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeGetViewPort'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeLockModeSwitch'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGAQueryExtension'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86DGADirectVideo'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeSwitchToMode'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeGetAllModeLines'
> /usr/cvs/pkgsrc/audio/xmms-infinity/work.i386/.buildlink/lib/libSDL.so: undefined reference to `XF86VidModeGetModeLine'
> collect2: ld returned 1 exit status
> 
> I don't understand it. I'm going to recompile SDL with shared versions of libXxf86{dga,vm} and see if this changes anything.
> 
> -- 
> /* Tomasz Luchowski <zuntum@netbsd.org> */

-- 
        -- Oleg Polianski <Oleg.Polianski@clear.co.nz>