Garry Williams - 2007-07-04

I can't figure out what I'm doing wrong.

I'm trying to compile tora-1.3.22svn on Fedora 7.  (I got the identical
errors with tora-1.3.21 so tried the latest available to see if would
help.)

If I just run configure without any parameters and no environment
variables, I get this in the config.log:

configure:30477: g++ -o conftest  -DQT_THREAD_SUPPORT -g -O2 -D_REENTRANT -INO 
   -LNONE    conftest.cpp  -lqt-mt -lpng -lz -lm -ljpeg  -lSM -lICE -lXext -lX11
-lSM -lICE  -lpthread  >&5
conftest.cpp:2:21: error: qglobal.h: No such file or directory
conftest.cpp:3:26: error: qapplication.h: No such file or directory
conftest.cpp:4:20: error: qevent.h: No such file or directory
conftest.cpp:5:21: error: qstring.h: No such file or directory
conftest.cpp: In function 'int main()':
conftest.cpp:9: error: 'QString' has not been declared
configure:30480: $? = 1
configure: failed program was:
#include "confdefs.h"
#include <qglobal.h>
#include <qapplication.h>
#include <qevent.h>
#include <qstring.h>
/* #include <qstyle.h> */

int main() {
  QString::fromLatin1("Elvis is alive");
  return 0;
}
configure:30520: error: Qt (>= Qt 3.1.0) (headers and libraries) not found.
      Please check your installation! For more details about this problem,
      look at the end of config.log.

I concluded that the configure script didn't know how to find my qt
headers for some reason.

So I tried this:

CXXFLAGS=`pkg-config --cflags qt-mt` ./configure

and I get this in the config.log:

configure:30477: g++ -o conftest  -DQT_THREAD_SUPPORT -DQT_SHARED -DQT_TABLET_SU
PPORT -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -D_REENTRANT -I/usr/lib/qt-3.3/include 
-D_REENTRANT -INO     -LNONE    conftest.cpp  -lqt-mt -lpng -lz -lm -ljpeg  -lS
M -lICE -lXext -lX11 -lSM -lICE  -lpthread  >&5
/usr/bin/ld: cannot find -lqt-mt
collect2: ld returned 1 exit status
configure:30480: $? = 1
configure: failed program was:
#include "confdefs.h"
#include <qglobal.h>
#include <qapplication.h>
#include <qevent.h>
#include <qstring.h>
/* #include <qstyle.h> */

int main() {
  QString::fromLatin1("Elvis is alive");
  return 0;
}
configure:30520: error: Qt (>= Qt 3.1.0) (headers and libraries) not found.
      Please check your installation! For more details about this problem,
      look at the end of config.log.

Finally, I try this:

CXXFLAGS=`pkg-config --cflags qt-mt` LDFLAGS=`pkg-config --libs-only-L qt-mt` ./configure

And now the error is mysterious because this is what I get in config.log:

configure:30477: g++ -o conftest  -DQT_THREAD_SUPPORT -DQT_SHARED -DQT_TABLET_SU
PPORT -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -D_REENTRANT -I/usr/lib/qt-3.3/include 
-D_REENTRANT -INO    -L/usr/lib/qt-3.3/lib   -LNONE    conftest.cpp  -lqt-mt -l
png -lz -lm -ljpeg  -lSM -lICE -lXext -lX11 -lSM -lICE  -lpthread  >&5
configure:30480: $? = 0
configure:30520: error: Qt (>= Qt 3.1.0) (headers) not found.
      Please check your installation! For more details about this problem,
      look at the end of config.log.

Does anyone know what I'm doing wrong?

--
Garry Williams