Use PLUGIN_SET_INFO instead of PLUGIN_INFO macros
[geanyprj.git] / configure.in
blob3ec732091e906eb7bf606176d5f0cafeaa93f35c
1 dnl Process this file with autoconf to produce a configure script.
3 AC_INIT([geanyprj], [0.4], [yurand2@gmail.com])
4 AM_INIT_AUTOMAKE([1.9 foreign])
6 AM_CONFIG_HEADER(config.h)
8 AC_PROG_CC
10 AC_DISABLE_STATIC
11 AM_PROG_LIBTOOL
12 LIBTOOL="$LIBTOOL --silent"
14 AC_PROG_INSTALL
15 AC_PROG_INTLTOOL
18 # checking for Geany
19 PKG_CHECK_MODULES(GEANY, [geany >= 0.15])
20 AC_SUBST(GTK_CFLAGS)
21 AC_SUBST(GTK_LIBS)
23 GEANY_VERSION=`$PKG_CONFIG --modversion geany`
24 GTK_VERSION=`$PKG_CONFIG --modversion gtk+-2.0`
27 # i18n
28 GETTEXT_PACKAGE=geanyprj
29 AC_SUBST(GETTEXT_PACKAGE)
30 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package.])
32 ALL_LINGUAS="`sed -e '/^#/d' $srcdir/po/LINGUAS`" # take all languages found in file po/LINGUAS
34 AM_GLIB_GNU_GETTEXT
35 # workaround for intltool bug (http://bugzilla.gnome.org/show_bug.cgi?id=490845)
36 if test "x$MSGFMT" = "xno"; then
37         AC_MSG_ERROR([msgfmt not found. Please install the gettext package.])
40 # intltool hack to define install_sh on Debian/Ubuntu systems
41 if test "x$install_sh" = "x"; then
42         install_sh="`pwd`/install-sh"
43         AC_SUBST(install_sh)
46 # get the plugin installed at the correct location for Geany
47 # TODO find a way to NOT override --libdir command line option if given
48 libdir="`$PKG_CONFIG --variable=libdir geany`/geany"
50 dnl unittests
51 PKG_CHECK_MODULES([CHECK], [check >= 0.9.4], [
52 AC_SUBST(CHECK_CFLAGS)
53 AC_SUBST(CHECK_LIBS)
54 AM_CONDITIONAL(UNITTESTS, true)
55 ], [
56 AM_CONDITIONAL(UNITTESTS, false)
60 AC_OUTPUT([
61 Makefile
62 src/Makefile
63 tests/Makefile
64 po/Makefile.in
67 echo "----------------------------------------"
68 echo "Install geanyprj in                : ${libdir}"
69 echo "Using Geany version                : ${GEANY_VERSION}"
70 echo "Using GTK version                  : ${GTK_VERSION}"
71 echo ""
72 echo "Configuration is done OK."
73 echo ""