From: werner s. <wsc...@us...> - 2005-09-22 20:15:09
|
Update of /cvsroot/lmuse/muse/m4 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20689/m4 Modified Files: qt.m4 Log Message: qt4 port, chunk 1 Index: qt.m4 =================================================================== RCS file: /cvsroot/lmuse/muse/m4/qt.m4,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** qt.m4 12 Jul 2004 23:13:40 -0000 1.4 --- qt.m4 22 Sep 2005 20:11:50 -0000 1.5 *************** *** 3,6 **** --- 3,7 ---- dnl \author J.E. Hoffmann <je...@gm...> dnl + AC_DEFUN(CONFIGURE_QT, [ *************** *** 9,15 **** QT_CFLAGS="" QT_LIBS="" MOC="moc" ! UIC="uic" ! qt_includes="/usr/include/qt" qt_libraries="" qt_binaries="" --- 10,17 ---- QT_CFLAGS="" QT_LIBS="" + QT_DEBUG_LIBS="" MOC="moc" ! UIC="uic3" ! qt_includes="/usr/qt4/include" qt_libraries="" qt_binaries="" *************** *** 19,40 **** if test -z "$QTDIR"; then AC_MSG_RESULT(no) - AC_MSG_WARN([ - - ***************** WARNING ***************** - - YOU HAVE NOT SET YOUR 'QTDIR' ENVIRONMENT VARIABLE!!! - - This is the source of most people's problems when - configuring muse. If the configuration fails to find - qt, try setting your QTDIR environment variable to - the directory where qt is installed. - - ******************************************* - - ]) - echo -ne "\a" - echo -ne "\a" - echo -ne "\a" - sleep 7 else AC_MSG_RESULT(yes) --- 21,24 ---- *************** *** 43,47 **** qt_binaries="$QTDIR/bin" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic"; fi fi --- 27,31 ---- qt_binaries="$QTDIR/bin" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic3"; fi fi *************** *** 71,75 **** qt_binaries="$withval/bin" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic"; ]) --- 55,59 ---- qt_binaries="$withval/bin" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic3"; ]) *************** *** 91,95 **** qt_binaries="$withval" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic"; ]) --- 75,79 ---- qt_binaries="$withval" MOC="$qt_binaries/moc"; ! UIC="$qt_binaries/uic3"; ]) *************** *** 109,119 **** saved_CPPFLAGS="$CPPFLAGS" saved_LIBS="$LIBS" ! CPPFLAGS="$saved_CPPFLAGS -I$qt_includes" if test -n "$qt_libraries"; then ! LIBS="$saved_LIBS -L$qt_libraries -lqt-mt -lqui" ! QT_LIBS="-L$qt_libraries -lqt-mt -lqui" else ! LIBS="$saved_LIBS -lqt-mt -lqui -lm $X11_LIBS" ! QT_LIBS="-lqt-mt -lqui" fi AC_MSG_CHECKING([for QT includes ($qt_includes)]) --- 93,113 ---- saved_CPPFLAGS="$CPPFLAGS" saved_LIBS="$LIBS" ! CPPFLAGS="$saved_CPPFLAGS -I$qt_includes -I$qt_includes/QtGui -I$qt_includes/QtCore" if test -n "$qt_libraries"; then ! LIBS="$saved_LIBS -L$qt_libraries" ! if test "$MINGW32" != "1"; then ! QT_LIBS="-L$qt_libraries -lQtCore -lQtGui -lQtXml -lQt3Support" ! else ! QT_LIBS="-L$qt_libraries -lQtCore4 -lQtGui4 -lQtXml4" ! fi ! QT_DEBUG_LIBS="-L$qt_libraries -lQtCore_debug -lQtGui_debug -lQtXml_debug -lQt3Support_debug" else ! LIBS="$saved_LIBS -lm $X11_LIBS" ! if test "$MINGW32" != "1"; then ! QT_LIBS="-lQtCore -lQtGui -lQtXml -lQt3Support" ! else ! QT_LIBS="-lQtCore4 -lQtGui4 -lQtXml4" ! fi ! QT_DEBUG_LIBS="-lQtCore_debug -lQtGui_debug -lQtXml_debug -lQt3Support_debug" fi AC_MSG_CHECKING([for QT includes ($qt_includes)]) *************** *** 121,129 **** [ AC_LANG_PUSH(C++) ! AC_TRY_CPP([#include <qapplication.h>], qt_includes_found=yes, qt_includes_found=no) AC_LANG_POP(C++) if test "$qt_includes_found" = "yes"; then ! QT_CFLAGS="-I$qt_includes" AC_MSG_RESULT(yes) else --- 115,123 ---- [ AC_LANG_PUSH(C++) ! AC_TRY_CPP([#include <QtGui/QApplication>], qt_includes_found=yes, qt_includes_found=no) AC_LANG_POP(C++) if test "$qt_includes_found" = "yes"; then ! QT_CFLAGS="-I$qt_includes -I$qt_includes/Qt3Support -I$qt_includes/QtGui -I$qt_includes/QtCore -I$qt_includes/Qt" AC_MSG_RESULT(yes) else *************** *** 146,154 **** if test "$muse_qttest" = "yes"; then AC_TRY_RUN([ ! #include <qapplication.h> int main(int argc, char **argv) { ! QApplication app(argc, argv, false); ! } ],[ --- 140,148 ---- if test "$muse_qttest" = "yes"; then AC_TRY_RUN([ ! #include <QApplication> int main(int argc, char **argv) { ! QApplication app(argc, argv); ! } ],[ *************** *** 170,174 **** AC_MSG_CHECKING([for QT moc ($MOC)]) ! output=`eval "$MOC --help 2>&1 | grep Qt"` if test -z "$output"; then AC_MSG_RESULT(no) --- 164,168 ---- AC_MSG_CHECKING([for QT moc ($MOC)]) ! output=`eval "$MOC -v 2>&1 | sed -e '1q' | grep Qt"` if test -z "$output"; then AC_MSG_RESULT(no) *************** *** 179,183 **** AC_MSG_CHECKING([for QT uic ($UIC)]) ! output=`eval "$UIC --help 2>&1 | grep Qt"` if test -z "$output"; then AC_MSG_RESULT(no) --- 173,177 ---- AC_MSG_CHECKING([for QT uic ($UIC)]) ! output=`eval "$UIC -v 2>&1 | sed -e '1q' | grep Qt"` if test -z "$output"; then AC_MSG_RESULT(no) *************** *** 186,189 **** --- 180,184 ---- AC_MSG_RESULT(yes) fi + CPPFLAGS="$saved_CPPFLAGS" LIBS="$saved_LIBS" *************** *** 209,218 **** if test "$muse_qttest" = "yes"; then AC_TRY_RUN([ #include <qglobal.h> int main() { ! int version = ($qt_major_version << 16) ! + ($qt_minor_version << 8) ! + $qt_micro_version; if (QT_VERSION < version) return(1); return(0); --- 204,214 ---- if test "$muse_qttest" = "yes"; then AC_TRY_RUN([ + #include <stdio.h> #include <qglobal.h> int main() { ! int version = ($qt_major_version << 16) ! + ($qt_minor_version << 8) ! + $qt_micro_version; if (QT_VERSION < version) return(1); return(0); *************** *** 237,240 **** --- 233,237 ---- AC_SUBST(QT_CFLAGS) AC_SUBST(QT_LIBS) + AC_SUBST(QT_DEBUG_LIBS) AC_SUBST(MOC) AC_SUBST(UIC) |