1 dnl Process this file with autoconf to produce a configure script.
5 AC_INIT(memprof, 0.6.1)
6 AC_CONFIG_SRCDIR(memprof.glade)
8 dnl $Format: "AM_INIT_AUTOMAKE(MemProf, $ReleaseVersion$)" $
9 AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
11 dnl Specify a configuration file
12 AM_CONFIG_HEADER(config.h)
14 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
16 dnl Initialize libtool
19 dnl Initialize maintainer mode
29 if test "x$GCC" = "xyes"; then
31 *[\ \ ]-Wall[\ \ ]*) ;;
32 *) CFLAGS="$CFLAGS -Wall" ;;
37 debugdir=${libdir}/debug
39 AC_ARG_WITH(separate-debug-dir,
40 [ --with-separate-debug-dir=path Look for global separate debug info in this path [LIBDIR/debug]],
41 [debugdir="${withval}"])
43 AC_DEFINE_DIR(DEBUGDIR, debugdir,
44 [Look for global separate debug info in this path])
46 dnl GNOME checks (using pkg-config macros) and getting cflags and libs
48 LIBGLADE_REQUIRED=1.99.9
50 PKG_CHECK_MODULES(MEMPROF,
52 gtk+-2.0 >= $GTK_REQUIRED
53 libglade-2.0 >= $LIBGLADE_REQUIRED
56 AC_SUBST(MEMPROF_CFLAGS)
58 AC_CHECK_HEADER([bfd.h],[],
59 [AC_MSG_ERROR([Cannot continue: bfd.h not found. Do you have binutils-dev installed?])])
61 if ! uname | grep Linux > /dev/null ; then
62 AC_MSG_ERROR([*** MemProf only works on linux])
65 AC_SUBST(MEMPROF_LIBS)
67 dnl Initialize gettext
68 GETTEXT_PACKAGE=memprof
69 AC_SUBST(GETTEXT_PACKAGE)
70 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",
71 [Identifier for message catalog files])
73 ALL_LINGUAS="am ar az be ca cs da de dz el en_CA en_GB es et eu fi fr hr hu it ja ko lv mk ml ms nb ne nl oc pa pl pt pt_BR ru rw sk sl sr sr@Latn sv ta tr uk vi zh_CN zh_TW"
76 AC_HAVE_HEADERS(execinfo.h)
77 AC_CHECK_FUNCS(bind_textdomain_codeset backtrace)
80 dnl Remember ACLOCAL_FLAGS for automatic reautogen.
81 ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
83 dnl Output the Makefiles