From 71e5fefec995d92bb486de616b39a1037fe7abcf Mon Sep 17 00:00:00 2001 From: Manish Singh Date: Sat, 15 Apr 2000 21:50:19 +0000 Subject: [PATCH] tightened the regexs for build tool sanity checks * autogen.sh: tightened the regexs for build tool sanity checks * configure.in: more gtkxmhtml lib fixes (blargh) -Yosh --- ChangeLog | 6 ++++ autogen.sh | 6 ++-- configure.in | 83 ++++++++++++++++++++++++++-------------------------- 3 files changed, 50 insertions(+), 45 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5bb5699cc6..655008cd7a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Sat Apr 15 15:10:39 PDT 2000 Manish Singh + + * autogen.sh: tightened the regexs for build tool sanity checks + + * configure.in: more gtkxmhtml lib fixes (blargh) + 2000-04-15 Michael Natterer * app/gdisplay_ops.c (gdisplay_shrink_wrap): after resizing the diff --git a/autogen.sh b/autogen.sh index 4b95492d0a..1b68bd25de 100755 --- a/autogen.sh +++ b/autogen.sh @@ -34,7 +34,7 @@ echo "see the file HACKING for more information..." echo echo "Testing autoconf... " -VER=`autoconf --version | sed "s/[a-zA-Z]*//g"` +VER=`autoconf --version | sed "s/.* \([0-9.]*\)$/\1/"` if expr $VER \>= 2.13 >/dev/null; then echo "looks OK." else @@ -43,7 +43,7 @@ else fi echo "Testing automake... " -VER=`automake --version | grep automake | sed "s/[a-zA-Z()]//g"` +VER=`automake --version | grep automake | sed "s/.* \([0-9.]*\)$/\1/"` if expr $VER \>= 1.4 >/dev/null; then echo "looks OK." else @@ -52,7 +52,7 @@ else fi echo "Testing gettextize... " -VER=`gettextize --version | grep gettext | sed "s#[a-zA-Z()/]##g;s/0.//"` +VER=`gettextize --version | grep gettext | sed "s/.* \([0-9.]*\)$/\1/;s/0.//"` if expr $VER \>= 10.35 >/dev/null; then echo "looks OK." else diff --git a/configure.in b/configure.in index 843c8f562c..092e86c796 100644 --- a/configure.in +++ b/configure.in @@ -404,6 +404,47 @@ if test "$have_glib_inline" = "no"; then AC_C_INLINE fi +dnl This is for the help browser +AC_PATH_PROG(GNOME_CONFIG,gnome-config,no) +if test "$GNOME_CONFIG" = "no"; then + dnl Test for standalone GtkXMHTML widget + HELPBROWSER= + if test -n "$LIBPNG" && test -n "$LIBJPEG" && test -n "$LIBXPM"; then + helpbrowser_save_LIBS=$LIBS + LIBS="$LIBS $LIBPNG $LIBJPEG $LIBXPM" + AC_CHECK_LIB(gtkxmhtml, gtk_xmhtml_new, + GTKXMHTML_CFLAGS=$GTK_CFLAGS + GTKXMHTML_LIBS="-lgtkxmhtml $GTK_LIBS $LIBPNG $LIBJPEG $LIBXPM" + HELPBROWSER=helpbrowser, + AC_MSG_WARN(*** Help browser plug-in will not be built (GtkXMHTML library not found) ***)) + LIBS=$helpbrowser_save_LIBS + else + AC_MSG_WARN(*** Help browser plug-in will not be built (PNG, JPEG or XPM libraries not found) ***) + fi +else + GTKXMHTML_CFLAGS=`$GNOME_CONFIG --cflags gnomeui` + GTKXMHTML_LIBS=`$GNOME_CONFIG --libs gtkxmhtml` + HELPBROWSER=helpbrowser +fi + +dnl Sanity check to make sure the headers are there too and that gnome-config +dnl didn't lie to us +if test -n "$HELPBROWSER"; then + CPPFLAGS="$CPPFLAGS $GTKXMHTML_CFLAGS" + LDFLAGS="$LDFLAGS `echo $GTKXMHTML_LIBS | sed 's/\(.*\)\(-lgtkxmhtml.*\)/\1/'`" + LIBS="$LIBS $GTKXMHTML_LIBS" + + AC_MSG_CHECKING([to see if we can build with GtkXMHTML]) + AC_TRY_LINK([#include ], [return 0;], + gtkxmhtml_ok=yes, gtkxmhtml_ok=no) + AC_MSG_RESULT($gtkxmhtml_ok) + + if test "$gtkxmhtml_ok" = no; then + AC_MSG_WARN(*** Help browser plug-in will not be built (GtkXMHTML setup busted) ***) + HELPBROWSER= + fi +fi + CPPFLAGS="$gimp_save_CPPFLAGS" LDFLAGS="$gimp_save_LDFLAGS" LIBS="$gimp_save_LIBS" @@ -541,48 +582,6 @@ if test $ac_cv_path_LPC_COMMAND != ":"; then LPC_DEF="-DLPC_COMMAND=\\\"$ac_cv_path_LPC_COMMAND\\\"" fi -dnl This is for the help browser -AC_PATH_PROG(GNOME_CONFIG,gnome-config,no) -if test "$GNOME_CONFIG" = "no"; then - HELPBROWSER= - dnl Test for standalone GtkXMHTML widget - AC_CHECK_LIB(gtkxmhtml, gtk_xmhtml_new, - GTKXMHTML_CFLAGS=$GTK_CFLAGS - GTKXMHTML_LIBS="-lgtkxmhtml $GTK_LIBS" - HELPBROWSER=helpbrowser, - AC_MSG_WARN(*** Help browser plug-in will not be built (GtkXMHTML library not found) ***)) -else - GTKXMHTML_CFLAGS=`$GNOME_CONFIG --cflags gnomeui` - GTKXMHTML_LIBS=`$GNOME_CONFIG --libs gtkxmhtml` - HELPBROWSER=helpbrowser -fi - -dnl Sanity check to make sure the headers are there too and that gnome-config -dnl didn't lie to us -if test -n "$HELPBROWSER"; then - gimp_save_CPPFLAGS="$CPPFLAGS" - gimp_save_LDFLAGS="$LDFLAGS" - gimp_save_LIBS="$LIBS" - - CPPFLAGS="$CPPFLAGS $GTKXMHTML_CFLAGS" - LDFLAGS="$LDFLAGS `echo $GTKXMHTML_LIBS | sed 's/\(.*\)\(-lgtkxmhtml.*\)/\1/'`" - LIBS="$LIBS $GTKXMHTML_LIBS" - - AC_MSG_CHECKING([to see if we can build with GtkXMHTML]) - AC_TRY_LINK([#include ], [return 0;], - gtkxmhtml_ok=yes, gtkxmhtml_ok=no) - AC_MSG_RESULT($gtkxmhtml_ok) - - if test "$gtkxmhtml_ok" = no; then - AC_MSG_WARN(*** Help browser plug-in will not be built (GtkXMHTML setup busted) ***) - HELPBROWSER= - fi - - CPPFLAGS="$gimp_save_CPPFLAGS" - LDFLAGS="$gimp_save_LDFLAGS" - LIBS="$gimp_save_LIBS" -fi - dnl This is for the gimp-perl plug-in AC_ARG_ENABLE(perl, [ --disable-perl do not build perl extension [by default enabled] --enable-perl[=prefix] use specified prefix for perl (see INSTALL)])