# HG changeset patch # User Jaroslav Hajek # Date 1216416810 -7200 # Node ID efabe34cce70d47d55b629725051acf47cb16208 # Parent 2c0a0edae59664192af244af532bab5db1b74254 make configure compatible with FTGL ver <= 2.1.2 diff -r 2c0a0edae596 -r efabe34cce70 ChangeLog --- a/ChangeLog Sat Jul 19 22:59:14 2008 -0400 +++ b/ChangeLog Fri Jul 18 23:33:30 2008 +0200 @@ -1,3 +1,8 @@ +2008-07-21 Jaroslav Hajek + + * configure.in: Extend FTGL test to test for both ftgl.h and FTGL.h. + Use HAVE_FTGL_UPPERCASE to indicate the latter (version <= 2.1.2). + 2008-07-19 Rafael Laboissiere * octMakefile.in (CONF_DISTFILES): Include acx_blas_f77_func.m4 in diff -r 2c0a0edae596 -r efabe34cce70 configure.in --- a/configure.in Sat Jul 19 22:59:14 2008 -0400 +++ b/configure.in Fri Jul 18 23:33:30 2008 +0200 @@ -664,9 +664,13 @@ [warn_freetype="FreeType library not found. Native renderer will not have on-screen text"]) if test -z "$warn_freetype"; then AC_LANG_PUSH(C++) - AC_CHECK_HEADERS([FTGL/ftgl.h ftgl.h]) - if test "$ac_cv_header_FTGL_ftgl_h" = yes \ - || test "$ac_cv_header_ftgl_h" = yes; then + has_ftgl_h=yes + AC_CHECK_HEADERS([FTGL/ftgl.h ftgl.h], break, [ + AC_CHECK_HEADERS([FTGL/FTGL.h FTGL.h], [ + AC_DEFINE(HAVE_FTGL_UPPERCASE,1,[Define to 1 if you have FTGL.h or FTGL/FTGL.h]) + break + ], has_ftgl_h=no)]) + if test "$has_ftgl_h" = yes; then AC_MSG_CHECKING([for FTGLTextureFont in -lftgl]) save_LIBS="$LIBS" save_CXXFLAGS="$CXXFLAGS" @@ -674,9 +678,17 @@ CXXFLAGS="$CXXFLAGS $FT2_CFLAGS" AC_TRY_LINK([ #ifdef HAVE_FTGL_FTGL_H +#ifdef HAVE_FTGL_UPPERCASE +#include +#else #include +#endif #elif HAVE_FTGL_H +#ifdef HAVE_FTGL_UPPERCASE +#include +#else #include +#endif #endif], [ FTGLTextureFont font("");], [ OPENGL_LIBS="$OPENGL_LIBS $FT2_LIBS -lftgl"