# HG changeset patch # User Rik # Date 1346818223 25200 # Node ID 2f0b74cf8b4dd5c7f0750ee689c13c96eb62c05b # Parent f19d0bce85da769df6f1e941f8ef6dc0c08b8fc8 configure.ac: Conditionally build GUI using same construct as conditionally building DOCs. * configure.ac: New variable GUIDIR is AC_SUBSTituted into Makefile.am to determine whether to build GUI directory. diff -r f19d0bce85da -r 2f0b74cf8b4d Makefile.am --- a/Makefile.am Tue Sep 04 19:24:06 2012 -0700 +++ b/Makefile.am Tue Sep 04 21:10:23 2012 -0700 @@ -67,14 +67,8 @@ include m4/module.mk -if AMCOND_BUILD_GUI -GUIDIR = libgui -else -GUIDIR = -endif - # Subdirectories in which to run `make all'. -SUBDIRS = libgnu liboctave libinterp $(GUIDIR) src scripts @DOCDIR@ examples test +SUBDIRS = libgnu liboctave libinterp @GUIDIR@ src scripts @DOCDIR@ examples test if ! AMCOND_BUILD_DOCS dist-hook: diff -r f19d0bce85da -r 2f0b74cf8b4d configure.ac --- a/configure.ac Tue Sep 04 19:24:06 2012 -0700 +++ b/configure.ac Tue Sep 04 21:10:23 2012 -0700 @@ -2182,8 +2182,9 @@ HAVE_QT=false QT_INCDIR= QT_LIBDIR= +win32_terminal=no build_gui=yes -win32_terminal=no +GUIDIR=libgui AC_ARG_ENABLE(gui, [AS_HELP_STRING([--disable-gui], [don't build the GUI])], [if test "$enableval" = no; then build_gui=no; fi], [build_gui=yes]) @@ -2245,18 +2246,24 @@ OCTAVE_CHECK_FUNC_SETPLACEHOLDERTEXT case "$canonical_host_type" in - *-*-mingw* | *-*-msdosmsvc*) win32_terminal=yes ;; + *-*-mingw* | *-*-msdosmsvc*) + win32_terminal=yes + ;; *) AC_CHECK_HEADERS([pty.h libutil.h util.h]) AC_SEARCH_LIBS([openpty], [util], [AC_DEFINE(HAVE_OPENPTY, [], [Define whether openpty exists])]) ;; esac +else + ## GUI disabled. Eliminate building GUIDIR directory + GUIDIR= fi AM_CONDITIONAL([AMCOND_BUILD_GUI], [test $build_gui = yes]) AM_CONDITIONAL([WIN32_TERMINAL], [test $win32_terminal = yes]) AC_SUBST(QT_INCDIR) AC_SUBST(QT_LIBDIR) +AC_SUBST(GUIDIR) ### Run configure in subdirectories.