[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: CVS update: configure.ac



  User: danmc   
  Date: 06/09/23 23:57:58

  Modified:    .        configure.ac libgeda.pc.in
  Log:
  Improve gdlib detection.  Now instead of just dropping gd support
  
  if gdlib is not found, have configure error out with a message
  
  that tells the user what needs to be fixed or what feature will
  
  be missing if --disable-gd is used.  
  
  
  
  Also add a variable to libgeda.pc.in so pkg-config can determine
  
  if libgeda was compiled with gdlib support.  This makes determination
  
  of this by gschem more robust.
  
  
  
  
  Revision  Changes    Path
  1.34      +33 -27    eda/geda/gaf/libgeda/configure.ac
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: configure.ac
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/libgeda/configure.ac,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- configure.ac	22 Sep 2006 18:48:06 -0000	1.33
  +++ configure.ac	24 Sep 2006 03:57:58 -0000	1.34
  @@ -1,3 +1,5 @@
  +# $Id: configure.ac,v 1.34 2006/09/24 03:57:58 danmc Exp $
  +#
   # Process this file with autoconf to produce a configure script.
   AC_INIT
   AC_CONFIG_SRCDIR([include/libgeda.h])
  @@ -148,35 +150,38 @@
   ############################################################################
   # Check for libgd start
   # 
  -AC_PATH_PROG(LIBGDCONFIG, gdlib-config, no, ${PATH})
  +LIBGEDA_HASGD=no
  +if test "X$no_gd" != "Xyes"  ; then
  +
  +	AC_PATH_PROG(LIBGDCONFIG, gdlib-config, no, ${PATH})
  +
  +	if test "$LIBGDCONFIG" = "no" ; then
  +		AC_MSG_ERROR([Cannot find gdlib-config.
  +Make sure it is installed and in your PATH.
  +gdlib-config is part of the GD library available from www.boutell.com/gd.
  +This is needed for png export.  If you wish to compile libgeda without
  +png support then use --disable-gd.
  +])
   
  -if test "$LIBGDCONFIG" = "no"
  -then
  -   GD_CFLAGS=
  -   GD_LIBS=
  -   GD_VERSION=
  -   GD="no"
  -else
  -   if test "$no_gd" = "yes" 
  -   then
  -     echo found gd, but disabling gd support.
  -     GD_CFLAGS=
  -     GD_LIBS=
  -     GD_VERSION=
  -     GD="no"
      else 
        GD_CFLAGS=`$LIBGDCONFIG --cflags`
        GD_LIBS1=`$LIBGDCONFIG --ldflags`
        GD_LIBS2=`$LIBGDCONFIG --libs`
  -     GD_LIBS="$GD_LIBS1 $GD_LIBS2"
  +		GD_LIBS="$GD_LIBS1 $GD_LIBS2 -lgd"
        GD_VERSION=`$LIBGDCONFIG --version`
        GD="yes"
  +		LIBGEDA_HASGD=yes
   
        # This is not really used to figure out paths, but just to make 
        # sure >= 2.0.15 is installed
        # PKG_CHECK_MODULES(libgd, libgd >= 2.0.15)
        AC_DEFINE(HAS_LIBGD, 1, [If gd has been installed, define this])
      fi
  +else
  +	GD_CFLAGS=
  +	GD_LIBS=
  +	GD_VERSION=
  +	GD="no"
   fi
   
   # 
  @@ -511,6 +516,7 @@
   AC_SUBST(NOWEAVE)
   AC_SUBST(TEXI2HTML)
   AC_SUBST(INDENT)
  +AC_SUBST(LIBGEDA_HASGD)
   
   # Create all the necessary derived files
   AC_CONFIG_FILES([Makefile
  
  
  
  1.5       +2 -0      eda/geda/gaf/libgeda/libgeda.pc.in
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: libgeda.pc.in
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/libgeda/libgeda.pc.in,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- libgeda.pc.in	14 Jul 2006 02:31:37 -0000	1.4
  +++ libgeda.pc.in	24 Sep 2006 03:57:58 -0000	1.5
  @@ -3,6 +3,8 @@
   libdir=@libdir@
   includedir=@includedir@
   
  +LIBGEDA_HASGD=@LIBGEDA_HASGD@
  +
   Name: libgeda
   Description: gEDA/gaf's core library 
   Requires: 
  
  
  


_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs