[mythtv] Problem linking latest CVS

Dan Schwarz mythtv-dev@snowman.net
Sun Jan 12 21:01:06 EST 2003


Now that I'm back in business with MythTV, I decided to do an update to 
the head last night... and simultaneously did a debian apt-get dist 
upgrade to bring my system up to the current bleeding edge.

My mistake, never make two major changes at once!

Did a make distclean && make and it complained that QMAKESPEC was not 
set. I know about QTDIR, but QMAKESPEC...?  A little Googling later, I 
found out what this should be, and I set 
QMAKESPEC=/usr/share/qt/mkspecs/linux-g++ .
Clean rebuild, now everything seems to compile, but I get tons of link 
errors (Undefined Reference) against all QT functions.

For example, here's the make output trying to link mythepg main.o
g++  -o mythepg main.o   -L/usr/share/qt/lib -L/usr/X11R6/lib 
-L../../libs/libmyth -L../../libs/libmythtv -L../../libs/libavcodec 
-lmythtv -lavcodec -lmyth-0.8 -lXinera
ma -lqt-mt -lXext -lX11 -lm -lpthread

Errors:
main.o(.text+0x7a): In function `main':
: undefined reference to `QApplication::QApplication[in-charge](int&, 
char**)'
main.o(.text+0x9d): In function `main':
: undefined reference to `QSqlDatabase::defaultConnection'
and so on...

/usr/share/qt/lib  has symlinks to all the right libraries

lrwxrwxrwx    1 root     root           30 2003-01-11 23:08 libqt-mt.so 
-> ../../../lib/libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           30 2003-01-11 23:08 
libqt-mt.so.3 -> ../../../lib/libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           30 2003-01-11 23:08 
libqt-mt.so.3.1 -> ../../../lib/libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           27 2003-01-11 23:08 libqt.so -> 
../../../lib/libqt.so.3.1.1
lrwxrwxrwx    1 root     root           27 2003-01-11 23:08 libqt.so.3 
-> ../../../lib/libqt.so.3.1.1
lrwxrwxrwx    1 root     root           27 2003-01-11 23:08 libqt.so.3.1 
-> ../../../lib/libqt.so.3.1.1

The symlinks point to the right files in /usr/lib...

dschwarz@linuxbox:/usr/lib$ ls -l libqt*
-rw-r--r--    1 root     root     13753166 2002-12-20 18:37 libqt.a
lrwxrwxrwx    1 root     root           20 2002-08-07 18:49 
libqthreads.so.9 -> libqthreads.so.9.0.0
-rw-r--r--    1 root     root         3888 2002-03-27 10:18 
libqthreads.so.9.0.0
lrwxrwxrwx    1 root     root           18 2002-11-23 00:35 
libqtmcop.so.1 -> libqtmcop.so.1.0.0
-rw-r--r--    1 root     root        28744 2002-10-06 08:29 
libqtmcop.so.1.0.0
-rw-r--r--    1 root     root     13921798 2002-12-20 18:37 libqt-mt.a
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 libqt-mt.so 
-> libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.2 -> libqt-mt.so.2.3.2
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.2.3 -> libqt-mt.so.2.3.2
-rw-r--r--    1 root     root      4783172 2002-12-24 09:05 
libqt-mt.so.2.3.2
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.3 -> libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.3.1 -> libqt-mt.so.3.1.1
-rw-r--r--    1 root     root      6075812 2002-12-20 18:37 
libqt-mt.so.3.1.1dschwarz@linuxbox:/usr/lib$ ls -l libqt*
-rw-r--r--    1 root     root     13753166 2002-12-20 18:37 libqt.a
lrwxrwxrwx    1 root     root           20 2002-08-07 18:49 
libqthreads.so.9 -> libqthreads.so.9.0.0
-rw-r--r--    1 root     root         3888 2002-03-27 10:18 
libqthreads.so.9.0.0
lrwxrwxrwx    1 root     root           18 2002-11-23 00:35 
libqtmcop.so.1 -> libqtmcop.so.1.0.0
-rw-r--r--    1 root     root        28744 2002-10-06 08:29 
libqtmcop.so.1.0.0
-rw-r--r--    1 root     root     13921798 2002-12-20 18:37 libqt-mt.a
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 libqt-mt.so 
-> libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.2 -> libqt-mt.so.2.3.2
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.2.3 -> libqt-mt.so.2.3.2
-rw-r--r--    1 root     root      4783172 2002-12-24 09:05 
libqt-mt.so.2.3.2
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.3 -> libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           17 2003-01-11 23:08 
libqt-mt.so.3.1 -> libqt-mt.so.3.1.1
-rw-r--r--    1 root     root      6075812 2002-12-20 18:37 
libqt-mt.so.3.1.1
lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so -> 
libqt.so.3.1.1
lrwxrwxrwx    1 root     root           14 2003-01-11 23:07 libqt.so.2 
-> libqt.so.2.3.2
lrwxrwxrwx    1 root     root           14 2003-01-11 23:07 libqt.so.2.3 
-> libqt.so.2.3.2
-rw-r--r--    1 root     root      4767364 2002-12-24 09:05 libqt.so.2.3.2
lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so.3 
-> libqt.so.3.1.1
lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so.3.1 
-> libqt.so.3.1.1
-rw-r--r--    1 root     root      6011396 2002-12-20 18:37 libqt.so.3.1.1

lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so -> 
libqt.so.3.1.1
lrwxrwxrwx    1 root     root           14 2003-01-11 23:07 libqt.so.2 
-> libqt.so.2.3.2
lrwxrwxrwx    1 root     root           14 2003-01-11 23:07 libqt.so.2.3 
-> libqt.so.2.3.2
-rw-r--r--    1 root     root      4767364 2002-12-24 09:05 libqt.so.2.3.2
lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so.3 
-> libqt.so.3.1.1
lrwxrwxrwx    1 root     root           14 2003-01-11 23:08 libqt.so.3.1 
-> libqt.so.3.1.1
-rw-r--r--    1 root     root      6011396 2002-12-20 18:37 libqt.so.3.1.1

So, what's going wrong here?  Any ideas why it fails to link?

Thanks!

Dan






More information about the mythtv-dev mailing list