[mythtv] Building myth against xorg from svn

Yan Seiner yan at seiner.com
Tue Feb 9 14:13:20 UTC 2010

My system is based on Debian Lenny.  I have the standard Debian xorg 
installed at /usr.  However, I am running bleeding edge xorg at /usr/local/.

I'm trying to build myth against the new xorg, and it wants to pull in 
the X libs from /usr.  The net result is that the linking fails:

g++  -o mythavtest version.o main.o    -L/usr/lib -L../../libs/libmyth 
-L../../libs/libmythtv -L../../libs/libavutil -L../../libs/libavcodec 
-L../../libs/libavformat -L../../libs/libswscale -L../../libs/libmythdb 
-L../../libs/libmythui -L../../libs/libmythupnp -lmythtv-0.22 
-lmythavformat-0.22 -lmythavutil-0.22 -lmythavcodec-0.22 
-lmythswscale-0.22 -lmythupnp-0.22 -lmythdb-0.22 -lmythui-0.22 
-lmyth-0.22 -L../../libs/libmythlivemedia -lmythlivemedia-0.22 
-L../../libs/libmythfreemheg -lmythfreemheg-0.22 
-L../../libs/libmythhdhomerun -lmythhdhomerun-0.22 -lfreetype -lz 
-L/usr/lib -ldirectfb -lfusion -ldirect -L/usr/X11R6/lib -lXinerama 
-lX11 -lXext -lXxf86vm -lXv -lXrandr -lXvMCNVIDIA -lXvMC 
-L/usr/local/lib -lpthread -lGLU -lGL -lQtSql -lQtXml -lQtOpenGL -lQtGui 
-lQtNetwork -lQtCore
/usr/bin/ld: warning: libxcb-xlib.so.0, needed by /usr/lib/libX11.so, 
not found (try using -rpath or -rpath-link)
/usr/lib/libX11.so: undefined reference to `xcb_xlib_lock'
/usr/lib/libX11.so: undefined reference to `xcb_get_request_sent'
/usr/local/lib/libXi.so.6: undefined reference to `XESetWireToEventCookie'
/usr/local/lib/libXi.so.6: undefined reference to `XESetCopyEventCookie'
/usr/lib/libX11.so: undefined reference to `xcb_xlib_unlock'
collect2: ld returned 1 exit status
make[2]: *** [mythavtest] Error 1
make[2]: Leaving directory 
make[1]: *** [sub-mythavtest-make_default] Error 2
make[1]: Leaving directory `/data20/src/mythtv/mythtv-trunk/mythtv/programs'
make: *** [sub-programs-make_default-ordered] Error 2

My build script:

ACLOCAL="aclocal -I ${PREFIX}/share/aclocal"

export ACLOCAL
export PREFIX

#make clean

./configure --extra-ldflags=-L/usr/local/lib --xvmc-lib=XvMCNVIDIA

make && make install

However, in spite of specifically setting the prefix and ldflags, the 
g++ line above still has -L/usr/lib as the first lib argument, which 
means that myth tries to link against the older xorg.

How do I tell it not to link against /usr/lib, ever?



   ,>/'_         o__
   (_)\(_)       ,>/'_          o__
A day may come  (_)\(_)         ,>/'_      o__
when the courage of men fails, (_)\(_)     ,>/'_ 
when we forsake our friends and break all (_)\(_)
bonds of fellowship, but it is not this day.
It is not this day!
This day we ride!

More information about the mythtv-dev mailing list