Add two new switches --enable-wx-opengl and --enable-wx-styledtextctrl, useful

for development purposes, but also useful to avoid invoking the wonderfully slow
g++ to test for availability during multiple ./configure runs.

Originally committed to SVN as r2020.
This commit is contained in:
Amar Takhar 2008-03-11 07:24:10 +00:00
parent ae67877863
commit 4c3dde50f6

View file

@ -184,7 +184,7 @@ if test "$with_pulseaudio" = "yes"; then
AC_DEFINE(WITH_PULSEAUDIO, 1, [Enable PulseAudio support]) AC_DEFINE(WITH_PULSEAUDIO, 1, [Enable PulseAudio support])
fi fi
AC_ARG_WITH(openal,[ --without-openal build without OpenAL audio provider. AC_ARG_WITH(openal,[ --without-openal build without OpenAL audio provider.
(default: auto)], openal_disabled="(disabled)") (default: auto)], openal_disabled="(disabled)")
if test "x$with_openal" != xno; then if test "x$with_openal" != xno; then
PKG_CHECK_MODULES(OPENAL, openal >= 0.0.8, [found_audio=yes; with_openal=yes], [with_openal=no]) PKG_CHECK_MODULES(OPENAL, openal >= 0.0.8, [found_audio=yes; with_openal=yes], [with_openal=no])
@ -541,20 +541,30 @@ fi
aegisub_save_CPPLAGS="$CPPLAGS" aegisub_save_CPPLAGS="$CPPLAGS"
CPPFLAGS="$WX_CFLAGS" CPPFLAGS="$WX_CFLAGS"
AC_ARG_ENABLE(wx-opengl, [ --enable-wx-opengl Force wxwidgets OpenGL support. ])
AC_MSG_CHECKING([wxWidgets OpenGL support]) AC_MSG_CHECKING([wxWidgets OpenGL support])
AC_TRY_COMPILE([#include <wx/glcanvas.h>], if test "$enable_wx_opengl" != "yes"; then
[wxGLCanvas *canvas;], AC_TRY_COMPILE([#include <wx/glcanvas.h>],
with_wxgl=yes, with_wxgl=no) [wxGLCanvas *canvas;],
with_wxgl=yes, with_wxgl=no)
else
with_wxgl="yes"
fi
AC_MSG_RESULT($with_wxgl) AC_MSG_RESULT($with_wxgl)
if test "$with_wxgl" = "no"; then if test "$with_wxgl" = "no"; then
AC_MSG_FAILURE([wxWidgets OpenGL support missing]) AC_MSG_FAILURE([wxWidgets OpenGL support missing])
fi fi
AC_ARG_ENABLE(wx-styledtextctrl, [ --enable-wx-styledtextctrl
Force wxwidgets StyledTextCtrl support. ])
AC_MSG_CHECKING([wxWidgets StyledTextCtrl support]) AC_MSG_CHECKING([wxWidgets StyledTextCtrl support])
AC_TRY_COMPILE([#include <wx/stc/stc.h>], if test "$enable_wx_styledtextctrl" != "yes"; then
[wxStyledTextCtrl *canvas;], AC_TRY_COMPILE([#include <wx/stc/stc.h>],
with_wxstc=yes, with_wxstc=no) [wxStyledTextCtrl *canvas;],
with_wxstc=yes, with_wxstc=no)
else
with_wxstc="yes"
fi
AC_MSG_RESULT($with_wxstc) AC_MSG_RESULT($with_wxstc)
if test "$with_wxstc" = "no"; then if test "$with_wxstc" = "no"; then