summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorAlbert Astals Cid <aacid@kde.org>2005-12-08 18:17:42 +0000
committerAlbert Astals Cid <aacid@kde.org>2005-12-08 18:17:42 +0000
commit830b61bfd1c985fe14ec4d0f6724c8f70e924fc1 (patch)
treea19eafd3191664e90c530861eb969d006e105698 /configure.ac
parent0a1c33ed17fd7053ed455da3444856a5dab3c9b4 (diff)
* configure.ac: Detect if gettimeofday is available, fixes for correct
linking to Qt4 on windows * goo/GooTimer.[cc|h]: Only build if gettimeofday is available * poppler/Gfx.cc: Only use the timer for profiling if gettimeofday is available * poppler/GlobalParams.cc: Remove extra unlockGlobalParams that was making windows hang * splash/SplashFTFontEngine.cc: i need unistd.h on windows also * splash/SplashFontFile.cc: i need unistd.h on windows also
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac14
1 files changed, 13 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 240bfde8..52345b75 100644
--- a/configure.ac
+++ b/configure.ac
@@ -16,6 +16,7 @@ AC_PROG_CC_STDC
#fi
AC_PROG_CXX
AC_PROG_INSTALL
+AC_CHECK_FUNC(gettimeofday, AC_DEFINE(HAVE_GETTIMEOFDAY, 1, [Defines if gettimeofday is available on your system]))
dnl Enable these unconditionally.
AC_DEFINE([A4_PAPER], [1], [Default to A4 paper.])
@@ -320,6 +321,7 @@ dnl What to test
qt4_test_include="QtCore/QCoreApplication"
qt4_test_la_library="libQtCore.la"
qt4_test_library="libQtCore.so"
+qt4_windows_test_library="QtCore4.dll"
dnl Check for Qt4 headers
AC_MSG_CHECKING([for Qt4 headers])
@@ -345,6 +347,12 @@ for qt4_check in $qt4_libdirs ; do
qt4_libdir="$qt4_check"
break
fi
+
+ if test -r "$qt4_check/$qt4_windows_test_library" ; then
+ qt4_libdir="$qt4_check"
+ windows_qt="yes"
+ break
+ fi
done
AC_MSG_RESULT([$qt4_libdir])
@@ -356,7 +364,11 @@ fi
dnl Set the variables
POPPLER_QT4_CXXFLAGS="-I$qt4_incdir"
-POPPLER_QT4_LIBS="-L$qt4_libdir -lQtCore -lQtGui"
+if test x$windows_qt = xyes; then
+ POPPLER_QT4_LIBS="-L$qt4_libdir -lQtCore4 -lQtGui4"
+else
+ POPPLER_QT4_LIBS="-L$qt4_libdir -lQtCore -lQtGui"
+fi
AC_SUBST(POPPLER_QT4_CXXFLAGS)
AC_SUBST(POPPLER_QT4_LIBS)