]> git.0d.be Git - empathy.git/blob - configure.ac
Updated Polish translation (Tomasz Dominikowski).
[empathy.git] / configure.ac
1 AC_INIT(Empathy, 0.8, http://bugzilla.gnome.org/browse.cgi?product=empathy)
2 AC_PREREQ(2.59)
3 AC_COPYRIGHT([Copyright (C) 2003-2007 Imendio AB])
4
5 AM_CONFIG_HEADER(config.h)
6 AM_INIT_AUTOMAKE(1.9 dist-bzip2 no-define)
7
8 AM_MAINTAINER_MODE
9
10 AC_ISC_POSIX
11 AC_PROG_CC
12 AC_HEADER_STDC
13
14 AM_PROG_LIBTOOL
15 AM_PATH_GLIB_2_0
16 AC_PATH_XTRA
17
18 AC_PATH_PROG(DBUS_BINDING_TOOL, dbus-binding-tool)
19 AC_PATH_PROG(GCONFTOOL, gconftool-2)
20 AM_GCONF_SOURCE_2
21
22 IT_PROG_INTLTOOL([0.35.0])
23
24 GLIB_REQUIRED=2.12.0
25 GTK_REQUIRED=2.10.0
26 GCONF_REQUIRED=1.2.0
27 LIBGLADE_REQUIRED=2.0.0
28 TELEPATHY_REQUIRED=0.0.51
29 MISSION_CONTROL_REQUIRED=4.22
30
31 IDT_COMPILE_WARNINGS
32
33 GLIB_GENMARSHAL=`$PKG_CONFIG glib-2.0 --variable=glib_genmarshal`
34 AC_SUBST(GLIB_GENMARSHAL)
35
36 pluginlibdir=`$PKG_CONFIG mission-control --variable=pluginlibdir`
37 AC_SUBST(pluginlibdir)
38
39 dnl -----------------------------------------------------------
40 dnl Language Support
41 dnl -----------------------------------------------------------
42
43 GETTEXT_PACKAGE=empathy
44 AC_SUBST(GETTEXT_PACKAGE)
45 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[Gettext package name])
46
47 AM_GLIB_GNU_GETTEXT
48
49 dnl -----------------------------------------------------------
50 dnl Pkg-Config dependency checks
51 dnl -----------------------------------------------------------
52
53 PKG_CHECK_MODULES(LIBEMPATHY,
54 [
55    glib-2.0 >= $GLIB_REQUIRED
56    gobject-2.0
57    gconf-2.0 >= $GCONF_REQUIRED
58    libxml-2.0
59    gnome-vfs-2.0
60    libtelepathy >= $TELEPATHY_REQUIRED
61    libmissioncontrol >= $MISSION_CONTROL_REQUIRED
62 ])
63
64 PKG_CHECK_MODULES(EMPATHY,
65 [
66    glib-2.0 >= $GLIB_REQUIRED
67    gobject-2.0
68    gconf-2.0 >= $GCONF_REQUIRED
69    libxml-2.0
70    gnome-vfs-2.0
71    libtelepathy >= $TELEPATHY_REQUIRED
72    libmissioncontrol >= $MISSION_CONTROL_REQUIRED
73    gtk+-2.0 >= $GTK_REQUIRED
74    libglade-2.0 >= $LIBGLADE_REQUIRED
75    libgnomeui-2.0
76 ])
77
78 dnl -----------------------------------------------------------
79 dnl ISO codes, used for aspell support
80 dnl -----------------------------------------------------------
81 AC_MSG_CHECKING([whether iso-codes exists and has iso-639 domain])
82 if $PKG_CONFIG --variable=domains iso-codes | grep -q 639 ; then
83    AC_MSG_RESULT([yes])
84    iso_codes_prefix=`$PKG_CONFIG --variable=prefix iso-codes`
85    iso_codes_pkgconfig=iso-codes
86    have_iso_codes=yes
87 else
88    AC_MSG_RESULT([no])
89    iso_codes_prefix=
90    iso_codes_pkgconfig=
91    have_iso_codes=no
92 fi
93
94 AC_DEFINE_UNQUOTED([ISO_CODES_PREFIX],["$iso_codes_prefix"],[ISO codes prefix])
95
96 dnl -----------------------------------------------------------
97 dnl ASpell
98 dnl -----------------------------------------------------------
99 AC_ARG_ENABLE(aspell,
100               AS_HELP_STRING([--enable-aspell=@<:@no/yes/auto@:>@],
101                              [compile with aspell support]), ,
102                              enable_aspell=auto)
103
104 if test "x$enable_aspell" = "xyes" -a "x$have_iso_codes" != "xyes"; then
105    AC_MSG_ERROR([You must have iso-codes with the iso-639 domain to use aspell.])
106 fi
107
108 if test "x$enable_aspell" != "xno" -a "x$have_iso_codes" = "xyes"; then
109    AC_CHECK_LIB(aspell, aspell_speller_check,have_aspell=yes,have_aspell=no,)
110
111    if test "x$have_aspell" = "xyes"; then
112       AC_DEFINE(HAVE_ASPELL, 1, [Define if we have aspell])
113       EMPATHY_LIBS="$EMPATHY_LIBS -laspell"
114    else
115       have_aspell=no
116    fi
117 else
118    have_aspell=no
119 fi
120
121 if test "x$enable_aspell" = "xyes" -a "x$have_aspell" != "xyes"; then
122    AC_MSG_ERROR([Couldn't find aspell.])
123 fi
124
125 dnl -----------------------------------------------------------
126 AC_OUTPUT([
127   Makefile
128   data/Makefile
129   data/empathy.desktop.in
130   data/16x16/Makefile
131   data/22x22/Makefile
132   data/32x32/Makefile
133   data/48x48/Makefile
134   data/scalable/Makefile
135   po/Makefile.in
136   libempathy/Makefile
137   libempathy-gtk/Makefile
138   src/Makefile
139 ])
140