2 # set the new version number:
3 # odd minor -> development series
4 # even minor -> stable series
5 # increment micro for each release within a series
6 # set empathy_nano_version to 0.
8 m4_define([empathy_major_version], [2])
9 m4_define([empathy_minor_version], [29])
10 m4_define([empathy_micro_version], [1])
11 m4_define([empathy_nano_version], [1])
13 m4_define([empathy_base_version],
14 [empathy_major_version.empathy_minor_version.empathy_micro_version])
15 m4_define([empathy_version],
16 [m4_if(empathy_nano_version, 0, [empathy_base_version],
17 [empathy_base_version].[empathy_nano_version])])
19 AC_INIT(Empathy, empathy_version, http://bugzilla.gnome.org/browse.cgi?product=empathy)
24 Copyright (C) 2003-2007 Imendio AB
25 Copyright (C) 2007-2008 Collabora Ltd.
28 # Minimal version required
32 LIBPANELAPPLET_REQUIRED=2.10.0
33 TELEPATHY_GLIB_REQUIRED=0.7.35
34 ENCHANT_REQUIRED=1.2.0
35 ISO_CODES_REQUIRED=0.35
36 LIBNOTIFY_REQUIRED=0.4.4
37 LIBCANBERRA_GTK_REQUIRED=0.4
38 LIBCHAMPLAIN_REQUIRED=0.4
39 LIBCHAMPLAIN_GTK_REQUIRED=0.4
40 CLUTTER_GTK_REQUIRED=0.10
42 WEBKIT_REQUIRED=1.1.15
44 NETWORK_MANAGER_REQUIRED=0.7.0
45 NAUTILUS_SENDTO_REQUIRED=2.28.0.1
47 # Use --enable-maintainer-mode to disabled deprecated symbols
48 GNOME_MAINTAINER_MODE_DEFINES
50 # Uncomment that to build with single include disabled
51 #AC_DEFINE(G_DISABLE_SINGLE_INCLUDES, [], [Disable single includes for GLib])
52 #AC_DEFINE(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES, [], [Disable single includes for GDK pixbuf])
53 #AC_DEFINE(GTK_DISABLE_SINGLE_INCLUDES, [], [Disable single includes for GTK])
55 AC_CONFIG_MACRO_DIR([m4])
56 AC_CONFIG_HEADERS([config.h])
57 AC_CONFIG_SRCDIR([configure.ac])
62 AM_INIT_AUTOMAKE(1.9 dist-bzip2 no-define -Wno-portability)
70 IT_PROG_INTLTOOL([0.35.0])
71 GNOME_DOC_INIT([0.17.3])
73 AC_PATH_PROG(DBUS_BINDING_TOOL, dbus-binding-tool)
74 AC_PATH_PROG(GCONFTOOL, gconftool-2)
76 GLIB_GENMARSHAL=`$PKG_CONFIG glib-2.0 --variable=glib_genmarshal`
77 AC_SUBST(GLIB_GENMARSHAL)
79 AC_CHECK_PROGS([XSLTPROC], [xsltproc])
80 if test -z "$XSLTPROC"; then
81 AC_MSG_ERROR([xsltproc (from libxslt) is required])
88 # -----------------------------------------------------------
90 # -----------------------------------------------------------
91 AS_COMPILER_FLAG(-Wall, ERROR_CFLAGS="-Wall", ERROR_CFLAGS="")
92 AS_COMPILER_FLAG(-Werror, werror=yes, werror=no)
95 AC_HELP_STRING([--disable-Werror],[compile without -Werror (normally enabled in development builds)]),
98 AS_COMPILER_FLAG(-Wextra, wextra=yes, wextra=no)
99 AS_COMPILER_FLAG(-Wno-missing-field-initializers,
100 wno_missing_field_initializers=yes,
101 wno_missing_field_initializers=no)
102 AS_COMPILER_FLAG(-Wno-unused-parameter,
103 wno_unused_parameter=yes,
104 wno_unused_parameter=no)
106 ifelse(empathy_nano_version, 0, [],
108 if test x$werror = xyes; then
109 ERROR_CFLAGS="$ERROR_CFLAGS -Werror"
111 if test x$wextra = xyes -a \
112 x$wno_missing_field_initializers = xyes -a \
113 x$wno_unused_parameter = xyes; then
114 ERROR_CFLAGS="$ERROR_CFLAGS -Wextra -Wno-missing-field-initializers -Wno-unused-parameter"
118 AS_COMPILER_FLAG(-Wdeclaration-after-statement, ERROR_CFLAGS="$ERROR_CFLAGS -Wdeclaration-after-statement")
119 AS_COMPILER_FLAG(-Wshadow, ERROR_CFLAGS="$ERROR_CFLAGS -Wshadow")
120 AS_COMPILER_FLAG(-Wmissing-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-prototypes")
121 AS_COMPILER_FLAG(-Wmissing-declarations, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-declarations")
122 # Disabled because some GTK+ headers (like gtkitemfactory.h) are bugged :(
123 #AS_COMPILER_FLAG(-Wstrict-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wstrict-prototypes")
125 AC_SUBST(ERROR_CFLAGS)
127 # -----------------------------------------------------------
128 # Pkg-Config dependency checks
129 # -----------------------------------------------------------
131 PKG_CHECK_MODULES(LIBEMPATHY,
133 glib-2.0 >= $GLIB_REQUIRED
135 gio-2.0 >= $GLIB_REQUIRED
136 gio-unix-2.0 >= $GLIB_REQUIRED
138 telepathy-glib >= $TELEPATHY_GLIB_REQUIRED
144 PKG_CHECK_MODULES(LIBEMPATHYGTK,
146 glib-2.0 >= $GLIB_REQUIRED
148 gio-2.0 >= $GLIB_REQUIRED
149 gconf-2.0 >= $GCONF_REQUIRED
151 gtk+-2.0 >= $GTK_REQUIRED
152 libcanberra-gtk >= $LIBCANBERRA_GTK_REQUIRED
153 telepathy-glib >= $TELEPATHY_GLIB_REQUIRED
156 gstreamer-interfaces-0.10
159 PKG_CHECK_MODULES(EMPATHY,
161 glib-2.0 >= $GLIB_REQUIRED
163 gio-2.0 >= $GLIB_REQUIRED
165 gtk+-2.0 >= $GTK_REQUIRED
168 telepathy-glib >= $TELEPATHY_GLIB_REQUIRED
172 gnome-keyring-1 >= $KEYRING_REQUIRED
175 PKG_CHECK_MODULES(LIBNOTIFY, libnotify >= $LIBNOTIFY_REQUIRED)
177 # -----------------------------------------------------------
179 # -----------------------------------------------------------
182 AC_HELP_STRING([--disable-debug],[compile without debug code]),
183 enable_debug=$enableval, enable_debug=yes )
185 if test x$enable_debug = xyes; then
186 AC_DEFINE(ENABLE_DEBUG, [], [Enable debug code])
189 # -----------------------------------------------------------
191 # -----------------------------------------------------------
193 GETTEXT_PACKAGE=empathy
194 AC_SUBST(GETTEXT_PACKAGE)
195 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[Gettext package name])
199 # -----------------------------------------------------------
200 # Connectivity integration
201 # -----------------------------------------------------------
202 AC_ARG_WITH(connectivity,
203 AS_HELP_STRING([--with-connectivity=@<:@nm/connman/auto/no@:>@],
204 [build with connectivity support]), ,
205 with_connectivity=auto)
207 if test "x$with_connectivity" = "xno"; then
211 elif test "x$with_connectivity" = "xconnman"; then
213 PKG_CHECK_MODULES(CONNMAN,
216 ], have_connman="yes", have_connman="no")
218 if test "x$have_connman" = "xyes"; then
219 AC_DEFINE(HAVE_CONNMAN, 1, [Define if you have connman dependencies])
225 PKG_CHECK_MODULES(NETWORK_MANAGER,
227 libnm_glib >= $NETWORK_MANAGER_REQUIRED
228 ], have_nm="yes", have_nm="no")
230 if test "x$have_nm" = "xyes"; then
231 AC_DEFINE(HAVE_NM, 1, [Define if you have libnm-glib])
236 if test "x$with_connectivity" = "xconnman" -a "x$have_connman" != "xyes"; then
237 AC_MSG_ERROR([Couldn't find connman dependencies.])
240 if test "x$with_connectivity" = "xnm" -a "x$have_nm" != "xyes"; then
241 AC_MSG_ERROR([Couldn't find libnm-glib dependencies.])
244 AM_CONDITIONAL(HAVE_NM, test "x$have_nm" = "xyes")
245 AM_CONDITIONAL(HAVE_CONNMAN, test "x$have_connman" = "xyes")
247 # -----------------------------------------------------------
249 # -----------------------------------------------------------
250 AC_ARG_ENABLE(webkit,
251 AS_HELP_STRING([--enable-webkit=@<:@no/yes/auto@:>@],
252 [build with webkit support]), ,
255 if test "x$enable_webkit" != "xno"; then
256 PKG_CHECK_MODULES(WEBKIT,
258 webkit-1.0 >= $WEBKIT_REQUIRED
259 ], have_webkit="yes", have_webkit="no")
261 if test "x$have_webkit" = "xyes"; then
262 AC_DEFINE(HAVE_WEBKIT, 1, [Define if you have libwebkitgtk])
268 if test "x$enable_webkit" = "xyes" -a "x$have_webkit" != "xyes"; then
269 AC_MSG_ERROR([Couldn't find webkit dependencies.])
271 AM_CONDITIONAL(HAVE_WEBKIT, test "x$have_webkit" = "xyes")
273 # -----------------------------------------------------------
274 # spellchecking checks: enchant and iso-codes
275 # -----------------------------------------------------------
277 AS_HELP_STRING([--enable-spell=@<:@no/yes/auto@:>@],
278 [Enable spell checking]), ,
281 if test "x$enable_spell" != "xno"; then
282 PKG_CHECK_MODULES(ENCHANT,
284 enchant >= $ENCHANT_REQUIRED,
285 iso-codes >= $ISO_CODES_REQUIRED
286 ], have_enchant="yes", have_enchant="no")
288 if test "x$have_enchant" = "xyes"; then
289 AC_MSG_CHECKING([whether iso-codes has iso-639 and iso-3166 domains])
290 if $PKG_CONFIG --variable=domains iso-codes | grep 639 > /dev/null && \
291 $PKG_CONFIG --variable=domains iso-codes | grep 3166 > /dev/null ; then
292 AC_DEFINE_UNQUOTED(ISO_CODES_PREFIX, ["`$PKG_CONFIG --variable=prefix iso-codes`"], [ISO codes prefix])
293 AC_DEFINE(HAVE_ENCHANT, [], [Define if you have libenchant])
299 AC_MSG_RESULT([$result])
305 if test "x$enable_spell" = "xyes" -a "x$have_enchant" != "xyes"; then
306 AC_MSG_ERROR([Couldn't find spell dependencies.])
309 AM_CONDITIONAL(HAVE_ENCHANT, test "x$have_enchant" = "xyes")
311 # -----------------------------------------------------------
312 # Map view checks: libchamplain
313 # -----------------------------------------------------------
315 AS_HELP_STRING([--enable-map=@<:@no/yes/auto@:>@],
316 [Enable map view]), ,
319 if test "x$enable_map" != "xno"; then
320 PKG_CHECK_MODULES(LIBCHAMPLAIN,
322 champlain-0.4 >= $LIBCHAMPLAIN_REQUIRED,
323 champlain-gtk-0.4 >= $LIBCHAMPLAIN_GTK_REQUIRED
324 clutter-gtk-0.10 >= $CLUTTER_GTK_REQUIRED
325 ], have_libchamplain="yes", have_libchamplain="no")
327 if test "x$have_libchamplain" = "xyes"; then
328 AC_DEFINE(HAVE_LIBCHAMPLAIN, 1, [Define if you have libchamplain])
334 if test "x$enable_map" = "xyes" -a "x$have_libchamplain" != "xyes"; then
335 AC_MSG_ERROR([Couldn't find map view dependencies.])
338 AM_CONDITIONAL(HAVE_LIBCHAMPLAIN, test "x$have_libchamplain" = "xyes")
340 # -----------------------------------------------------------
341 # location checks: geoclue
342 # -----------------------------------------------------------
343 AC_ARG_ENABLE(location,
344 AS_HELP_STRING([--enable-location=@<:@no/yes/auto@:>@],
345 [Enable location awareness]), ,
346 enable_location=auto)
348 if test "x$enable_location" != "xno"; then
349 PKG_CHECK_MODULES(GEOCLUE,
351 geoclue >= $GEOCLUE_REQUIRED
352 ], have_geoclue="yes", have_geoclue="no")
354 if test "x$have_geoclue" = "xyes"; then
355 AC_DEFINE(HAVE_GEOCLUE, 1, [Define if you have geoclue])
361 if test "x$enable_location" = "xyes" -a "x$have_geoclue" != "xyes"; then
362 AC_MSG_ERROR([Couldn't find location dependencies.])
365 AM_CONDITIONAL(HAVE_GEOCLUE, test "x$have_geoclue" = "xyes")
366 AC_SUBST(GEOCLUE_CFLAGS)
367 AC_SUBST(GEOCLUE_LIBS)
369 # -----------------------------------------------------------
370 # moblin widgets support
371 # -----------------------------------------------------------
372 AC_ARG_ENABLE(moblin,
373 AS_HELP_STRING([--enable-moblin=@<:no/yes@:>@],
374 [Enable moblin widgets]), ,
377 if test "x$enable_moblin" != "xno"; then
378 PKG_CHECK_MODULES(MOBLIN,
381 ], have_moblin="yes", have_moblin="no")
383 if test "x$have_moblin" = "xyes"; then
384 AC_DEFINE(HAVE_MOBLIN, 1, [Define if you have moblin])
390 if test "x$enable_moblin" = "xyes" -a "x$have_moblin" != "xyes"; then
391 AC_MSG_ERROR([Couldn't find moblin dependencies.])
394 AM_CONDITIONAL(HAVE_MOBLIN, test "x$have_moblin" = "xyes")
395 AC_SUBST(MOBLIN_CFLAGS)
396 AC_SUBST(MOBLIN_LIBS)
398 # -----------------------------------------------------------
400 # -----------------------------------------------------------
401 AC_ARG_ENABLE(nautilus-sendto,
402 AS_HELP_STRING([--enable-nautilus-sendto=@<:@no/yes/auto@:>@],
403 [build nautilus-sendto plugin]), ,
406 if test "x$enable_nst" != "xno"; then
407 PKG_CHECK_MODULES(NST,
409 nautilus-sendto >= $NAUTILUS_SENDTO_REQUIRED
410 ], have_nst="yes", have_nst="no")
415 if test "x$enable_nst" = "xyes" -a "x$have_nst" != "xyes"; then
416 AC_MSG_ERROR([Couldn't find nautilus-sendto dependencies.])
419 AM_CONDITIONAL(HAVE_NST, test "x$have_nst" = "xyes")
421 # -----------------------------------------------------------
423 # -----------------------------------------------------------
425 AS_HELP_STRING([--enable-tests=@<:@no/yes/auto@:>@],
429 if test "x$enable_tests" != "xno"; then
430 PKG_CHECK_MODULES(CHECK,
433 ], have_check="yes", have_check="no")
438 if test "x$enable_tests" = "xyes" -a "x$have_check" != "xyes"; then
439 AC_MSG_ERROR([Couldn't find check dependencies.])
442 AM_CONDITIONAL(HAVE_TESTS, test "x$have_check" = "xyes")
444 # -----------------------------------------------------------
445 # Coding style checks
446 # -----------------------------------------------------------
447 AC_ARG_ENABLE(coding-style-checks,
448 AC_HELP_STRING([--disable-coding-style-checks],
449 [don't check coding style using grep]),
450 [ENABLE_CODING_STYLE_CHECKS=$enableval], [ENABLE_CODING_STYLE_CHECKS=yes])
452 AC_SUBST([ENABLE_CODING_STYLE_CHECKS])
453 # -----------------------------------------------------------
460 data/empathy.desktop.in
465 libempathy-gtk/Makefile
467 nautilus-sendto-plugin/Makefile
479 Compiler....................: ${CC}
480 Compiler Flags..............: ${CFLAGS} ${ERROR_CFLAGS}
481 Prefix......................: ${prefix}
482 Shaved build................: ${enable_shave}
483 Tests.......................: ${have_check}
484 Coding style checks.........: ${ENABLE_CODING_STYLE_CHECKS}
487 Spell checking (enchant)....: ${have_enchant}
488 Display maps (libchamplain).: ${have_libchamplain}
489 Location awareness (Geoclue): ${have_geoclue}
490 Adium themes (Webkit).......: ${have_webkit}
491 Moblin widgets .............: ${have_moblin}
494 NetworkManager integration..: ${have_nm}
495 ConnMan integration.........: ${have_connman}
498 Nautilus-sendto plugin......: ${have_nst}