Mercurial > octave-antonio
diff configure.ac @ 15117:3735a0e783cb gui
more tweaks for the gui build
* configure.ac (HAVE_QT, GUIDIR): New variables.
Don't run qmake unless it is found. Don't check for moc, uic, or rcc
unless qmake is available. List Qt headers and libraries in summary
message.
* Makefile.am (SUBDIRS): Add @GUIDIR@ to the list.
* common.mk (do_subst_config_vals): Substitute OCTAVE_CONF_QT_INCDIR
and OCTAVE_CONF_QT_LIBDIR.
* gui/src/Makefile.am: Simplify pattern rule for moc files.
(octave_gui_CPPFLAGS): = Include -I@QT_INCDIR@ in the list.
(octave_gui_LDADD): Include ../../liboctave/liboctave.la and
../../libcruft/libcruft.la in the list.
(libqterminal_la_CPPFLAGS): Include -I@QT_INCDIR@ in the list.
* toplev.cc (octave_config_info): New struct fields, QT_INCDIR and
QT_LIBDIR.
* oct-conf.in.h (OCTAVE_CONF_QT_INCDIR, OCTAVE_CONF_QT_LIBDIR):
New macros.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sun, 05 Aug 2012 16:43:55 -0400 |
parents | 3d7a7ae53bbf |
children | 089b98bdaebf |
line wrap: on
line diff
--- a/configure.ac Sun Aug 05 20:04:53 2012 +0100 +++ b/configure.ac Sun Aug 05 16:43:55 2012 -0400 @@ -2132,19 +2132,26 @@ ### GUI/Qt related tests. -AC_CHECK_PROGS(MOC, [moc moc-qt4 moc-qt5]) -AC_CHECK_PROGS(UIC, [uic uic-qt4 uic-qt5]) -AC_CHECK_PROGS(RCC, [rcc]) +HAVE_QT=false +GUIDIR= +QT_INCDIR= +QT_LIBDIR= AC_CHECK_PROGS(QMAKE, [qmake qmake-qt4 qmake-qt5]) - -AC_SUBST(MOC) -AC_SUBST(UIC) - -QT_INCDIR=`$QMAKE -query | sed -n -e 's/^QT_INSTALL_HEADERS://p'` -QT_LIBDIR=`$QMAKE -query | sed -n -e 's/^QT_INSTALL_LIBS://p'` - +if test -n "$QMAKE"; then + QT_INCDIR=`$QMAKE -query | sed -n -e 's/^QT_INSTALL_HEADERS://p'` + QT_LIBDIR=`$QMAKE -query | sed -n -e 's/^QT_INSTALL_LIBS://p'` + AC_CHECK_PROGS(MOC, [moc moc-qt4 moc-qt5]) + AC_CHECK_PROGS(UIC, [uic uic-qt4 uic-qt5]) + AC_CHECK_PROGS(RCC, [rcc]) + if test -n "$MOC" && test -n "$UIC" && test -n "$RCC"; then + HAVE_QT=true + AC_DEFINE([HAVE_QT], 1, [Define to 1 if Qt is available (must have moc, uic, and rcc programs and developer header files and libraries installed)]) + GUIDIR=gui + fi +fi AC_SUBST(QT_INCDIR) AC_SUBST(QT_LIBDIR) +AC_SUBST(GUIDIR) case "$canonical_host_type" in *-*-mingw* | *-*-msdosmsvc*) win32_terminal=yes ;; @@ -2420,6 +2427,8 @@ QHULL LDFLAGS: $QHULL_LDFLAGS QHULL libraries: $QHULL_LIBS QRUPDATE libraries: $QRUPDATE_LIBS + Qt headers: $QT_INCDIR + Qt libraries: $QT_LIBDIR READLINE libraries: $READLINE_LIBS REGEX libraries: $REGEX_LIBS TERM libraries: $TERM_LIBS