Re: [gnet] Help with autoconf & gnet



That looks right.  I do something like this:

AM_PATH_GNET(1.1.0,
            [LIBS="$LIBS $GNET_LIBS" CFLAGS="$CFLAGS $GNET_CFLAGS"],
            AC_MSG_ERROR(Cannot find GNet: Is gnet-config in path?))

Is gnet.m4 in the right place?  It should be somewhere like
/usr/share/aclocal/gnet.m4 or in the macros directory of your project if
you have one.  I'm guess it's not finding that file.

David



On 4 Dec 2001, Juanan Pereira wrote:

> G'd day:
>
> 	i'm programming a simple network extension for a Gnome aplication
> (Goats) using Gnet Library. I've compiled and tested my program and
> (surprise!) it work's. Now, I want to create an apropiate configure
> script, but I can't manage to write it. I've read the "fine" manual
> (specially the section titled "Compiling programs with GNet") but after
> make what this section says*, run autoconf and then ./configure, it
> complains with this message:
>
> ./configure: line 4406: syntax error near unexpected
> token `AM_PATH_GNET(1.0.4,'
>
> ./configure: line 4406: `AM_PATH_GNET(1.0.4,'
>
>
> Can you help me please?
>
>
>
> TIA,
>
> 	Chessy
>
>
>
>
>
> * this is the configure.in. The conflicting lines are at near the end...
> starts with dnl Need Gnet
>
>
>
>
>
> dnl Process this file with autoconf to produce a configure script.
>
> AC_INIT(configure.in)
> AC_PREFIX_DEFAULT(/usr)
> AM_INIT_AUTOMAKE(goats, 0.5)
> AM_CONFIG_HEADER(config.h)
>
>   paneldefs="-DPANEL_SIZE -DPANEL"
>
> case "$ac_option" in
>
>   -disable-panel-size | --disable-panel-size | --disable-panel_size | -disable-panel_size)
>     paneldefs="-DPANEL" ;;
> esac
>
> case "$ac_option" in
>
>   -disable-panel | --disable-panel)
>     paneldefs="-DNOTHING" ;;
> esac
>
> dnl Pick up the Gnome macros.
> AM_ACLOCAL_INCLUDE(macros)
>
> GNOME_INIT
>
> echo $ac_n "checking applets library ... $ac_c" 1>&6
> echo "configure:1110: checking extra library \"$i\"" >&5
> GNOME_APPLETS_LIBS=`$GNOME_CONFIG --libs-only-l applets`
> if $GNOME_CONFIG --libs-only-l applets; then echo \
>                             $ac_n "found $ac_c" 1>&6;
> else echo \
>    "not found... guessing -lgnorba -lpanel_applet" 1>&6; \
>     GNOME_APPLETS_LIBS="-lgnorba -lpanel_applet";
> fi
>
> AC_ISC_POSIX
> AC_PROG_CC
> AM_PROG_CC_STDC
> AC_HEADER_STDC
>
> GNOME_COMPILE_WARNINGS
> GNOME_X_CHECKS
>
> dnl Add the languages which your application supports here.
> ALL_LINGUAS="ko ja"
> AM_GNU_GETTEXT
>
> dnl Set PACKAGE_LOCALE_DIR in config.h.
> if test "x${prefix}" = "xNONE"; then
>   AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "${ac_default_prefix}/${DATADIRNAME}/locale")
> else
>   AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "${prefix}/${DATADIRNAME}/locale")
> fi
>
>
> dnl Subst PACKAGE_PIXMAPS_DIR.
> PACKAGE_PIXMAPS_DIR="`gnome-config --datadir`/pixmaps/${PACKAGE}"
> AC_SUBST(PACKAGE_PIXMAPS_DIR)
>
> CFLAGS="$CFLAGS -DPACKAGE_PIXMAPS_DIR=\\\"$PACKAGE_PIXMAPS_DIR\\\" $paneldefs"
>
> dnl Need GNet
> AM_PATH_GNET(1.0.4,
>   [LIBS="$LIBS $GNET_LIBS" CFLAGS="$CFLAGS $GNET_CFLAGS"],
>   AC_MSG_ERROR(Cannot find GNet: Is gnet-config in path?))
>
> AC_OUTPUT([
> Makefile
> macros/Makefile
> src/Makefile
> intl/Makefile
> po/Makefile.in
> doc/Makefile
> ])
>
> _______________________________________________
> gnet mailing list
> gnet gnetlibrary org
> http://www.gnetlibrary.org/mailman/listinfo/gnet
>

-- 
      __          _    __ David Helder - dhelder umich edu
  ___/ /__ __  __(_)__/ / <http://www.eecs.umich.edu/~dhelder>
 / _  / _ `/ |/ / / _  /  Jungle Monkey: <http://www.junglemonkey.net>
 |_,_/|_,_/|___/_/|_,_/   Paper CD Case: <http://www.papercdcase.com>




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