]> git.0d.be Git - empathy.git/blob - configure.ac
local-xmpp-assistant-widget: increase row-spacing
[empathy.git] / configure.ac
1 dnl If not 1, append datestamp to the version number
2 m4_define(empathy_released, 0)
3
4 m4_define([empathy_major_version], [3])
5 m4_define([empathy_minor_version], [3])
6 m4_define([empathy_micro_version], [5])
7 m4_define([empathy_nano_version], [0])
8
9 dnl Display the nano_version only if it's not '0'
10 m4_define([empathy_base_version],
11           [empathy_major_version.empathy_minor_version.empathy_micro_version])
12 m4_define([empathy_full_version],
13           [m4_if(empathy_nano_version, 0, [empathy_base_version],
14               [empathy_base_version].[empathy_nano_version])])
15
16 m4_define(empathy_maybe_datestamp,
17           m4_esyscmd([if test x]empathy_released[ != x1; then date +.%Y%m%d | tr -d '\n\r'; fi]))
18
19 m4_define(empathy_version, empathy_full_version[]empathy_maybe_datestamp)
20
21
22 AC_INIT([Empathy],
23         [empathy_version],
24         [http://bugzilla.gnome.org/browse.cgi?product=empathy],
25         [empathy],
26         [https://live.gnome.org/Empathy])
27
28 AC_PREREQ([2.64])
29 AC_COPYRIGHT([
30   Copyright (C) 2003-2007 Imendio AB
31   Copyright (C) 2007-2010 Collabora Ltd.
32 ])
33
34 # Minimal version required
35
36 # Hardp deps
37 FOLKS_REQUIRED=0.6.6
38 GLIB_REQUIRED=2.30.0
39 GNUTLS_REQUIRED=2.8.5
40 GTK_REQUIRED=3.0.2
41 GSTREAMER_REQUIRED=0.10.32
42 KEYRING_REQUIRED=2.26.0
43 GCR_REQUIRED=2.91.4
44 LIBCANBERRA_GTK_REQUIRED=0.25
45 LIBNOTIFY_REQUIRED=0.7.0
46 TELEPATHY_FARSIGHT_REQUIRED=0.0.18
47 TELEPATHY_GLIB_REQUIRED=0.17.3
48 TELEPATHY_LOGGER=0.2.10
49 WEBKIT_REQUIRED=1.3.13
50 GOA_REQUIRED=3.3.0
51
52 # Optional deps
53 CLUTTER_REQUIRED=1.7.14
54 CLUTTER_GTK_REQUIRED=0.90.3
55 ENCHANT_REQUIRED=1.2.0
56 GEOCLUE_REQUIRED=0.11
57 ISO_CODES_REQUIRED=0.35
58 NAUTILUS_SENDTO_REQUIRED=2.90.0
59 NETWORK_MANAGER_REQUIRED=0.7.0
60 CHAMPLAIN_REQUIRED=0.12.1
61
62 # Use --enable-maintainer-mode to disable deprecated symbols,
63 # disable single include and enable GSEAL. If this is not a released empathy,
64 # maintainer mode is forced
65 # FIXME: don't disable deprecated symbols until bgo #636654 has been fixed
66 #ifelse(empathy_released, 1, [], [enable_maintainer_mode="yes"])
67 #GNOME_MAINTAINER_MODE_DEFINES
68
69 # Disable GLib deprecation warnings for now; we don't want to bump the GLib dep
70 # and make things harder for contributiors without good reason. We'll re-enable
71 # those warnings later during the cycle (bgo #662662)
72 AC_DEFINE(GLIB_DISABLE_DEPRECATION_WARNINGS, 1, [Build with GLib deprecated])
73
74 # FIXME: bgo #669673
75 AC_DEFINE(CLUTTER_DISABLE_DEPRECATION_WARNINGS, 1, [Build with Clutter deprecated])
76
77 # telepathy-yell
78 prev_top_build_prefix=$ac_top_build_prefix
79 prev_ac_configure_args=$ac_configure_args
80 ac_configure_args="$ac_configure_args --disable-shared-library"
81 AX_CONFIG_DIR([telepathy-yell])
82 ac_top_build_prefix=$prev_top_build_prefix
83 ac_configure_args=$prev_ac_configure_args
84 export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:"$ac_top_build_prefix"telepathy-yell/telepathy-yell
85
86 AC_CONFIG_MACRO_DIR([m4])
87 AC_CONFIG_HEADERS([config.h])
88 AC_CONFIG_SRCDIR([configure.ac])
89 AC_CONFIG_AUX_DIR(.)
90
91 AM_INIT_AUTOMAKE([1.11 no-define -Wno-portability tar-ustar no-dist-gzip dist-xz])
92
93 # Support silent build rules. Disable
94 # by either passing --disable-silent-rules to configure or passing V=1
95 # to make
96 AM_SILENT_RULES([yes])
97
98 # Check for programs
99 AC_PROG_CC
100 AC_HEADER_STDC
101 AM_PROG_MKDIR_P
102 AM_PATH_GLIB_2_0
103 AC_PATH_XTRA
104
105 # Initialize libtool
106 LT_PREREQ([2.2])
107 LT_INIT
108
109 GNOME_DOC_INIT([0.17.3])
110 AC_PATH_PROG(DBUS_BINDING_TOOL, dbus-binding-tool)
111 GLIB_GSETTINGS
112 GLIB_GENMARSHAL=`$PKG_CONFIG glib-2.0 --variable=glib_genmarshal`
113 AC_SUBST(GLIB_GENMARSHAL)
114
115 AC_CHECK_PROGS([XSLTPROC], [xsltproc])
116 if test -z "$XSLTPROC"; then
117   AC_MSG_ERROR([xsltproc (from libxslt) is required])
118 fi
119 AM_PATH_PYTHON([2.3])
120
121 EMPATHY_ARG_VALGRIND
122
123
124 # -----------------------------------------------------------
125 # Error flags
126 # -----------------------------------------------------------
127 AS_COMPILER_FLAG(-Wall, ERROR_CFLAGS="-Wall", ERROR_CFLAGS="")
128 AS_COMPILER_FLAG(-Werror, werror=yes, werror=no)
129
130 AC_ARG_ENABLE(Werror,
131   AS_HELP_STRING([--disable-Werror],
132                  [compile without -Werror (normally enabled in development builds)]),
133     werror=$enableval, :)
134
135 AS_COMPILER_FLAG(-Wextra, wextra=yes, wextra=no)
136 AS_COMPILER_FLAG(-Wno-missing-field-initializers,
137         wno_missing_field_initializers=yes,
138         wno_missing_field_initializers=no)
139 AS_COMPILER_FLAG(-Wno-unused-parameter,
140         wno_unused_parameter=yes,
141         wno_unused_parameter=no)
142
143 ifelse(empathy_released, 1, [],
144     [
145         if test x$werror = xyes; then
146             ERROR_CFLAGS="$ERROR_CFLAGS -Werror"
147         fi
148         if test x$wextra = xyes -a \
149             x$wno_missing_field_initializers = xyes -a \
150             x$wno_unused_parameter = xyes; then
151             ERROR_CFLAGS="$ERROR_CFLAGS -Wextra -Wno-missing-field-initializers -Wno-unused-parameter"
152         fi
153     ])
154
155 AS_COMPILER_FLAG(-Wdeclaration-after-statement, ERROR_CFLAGS="$ERROR_CFLAGS -Wdeclaration-after-statement")
156 AS_COMPILER_FLAG(-Wshadow, ERROR_CFLAGS="$ERROR_CFLAGS -Wshadow")
157 AS_COMPILER_FLAG(-Wmissing-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-prototypes")
158 AS_COMPILER_FLAG(-Wmissing-declarations, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-declarations")
159 AS_COMPILER_FLAG(-Wstrict-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wstrict-prototypes")
160
161 AC_SUBST(ERROR_CFLAGS)
162
163 AC_ARG_ENABLE(gprof,
164             AS_HELP_STRING([--enable-gprof=@<:@no/yes@:>@],
165             [build with support for gprof]),,
166             [enable_gprof=no])
167 if test "x$enable_gprof" != "xno" ; then
168     CFLAGS="$CFLAGS -pg"
169     LDFLAGS="$LDFLAGS -pg"
170 fi
171
172 AC_SUBST(LDFLAGS)
173
174 # -----------------------------------------------------------
175 # Pkg-Config dependency checks
176 # -----------------------------------------------------------
177
178 AC_CHECK_LIBM
179 AC_SUBST(LIBM)
180
181 PKG_CHECK_MODULES(EMPATHY,
182 [
183    dbus-glib-1
184    folks >= $FOLKS_REQUIRED
185    folks-telepathy >= $FOLKS_REQUIRED
186    glib-2.0 >= $GLIB_REQUIRED
187    gio-2.0 >= $GLIB_REQUIRED
188    gio-unix-2.0 >= $GLIB_REQUIRED
189    gnome-keyring-1 >= $KEYRING_REQUIRED
190    gnutls >= $GNUTLS_REQUIRED
191    gmodule-export-2.0
192    gobject-2.0
193    gsettings-desktop-schemas
194    gstreamer-0.10 >= $GSTREAMER_REQUIRED
195    gstreamer-interfaces-0.10
196    libxml-2.0
197    telepathy-glib >= $TELEPATHY_GLIB_REQUIRED
198    telepathy-logger-0.2 >= $TELEPATHY_LOGGER
199    x11
200    gtk+-3.0 >= $GTK_REQUIRED
201    libcanberra-gtk3 >= $LIBCANBERRA_GTK_REQUIRED
202    libnotify >= $LIBNOTIFY_REQUIRED
203    gcr-3 >= $GCR_REQUIRED
204    libpulse
205    libpulse-mainloop-glib
206    webkitgtk-3.0 >= $WEBKIT_REQUIRED
207    libsoup-2.4
208 ])
209
210 PKG_CHECK_MODULES(YELL, [telepathy-yell])
211
212 PKG_CHECK_MODULES(EMPATHY_AV,
213 [
214    farsight2-0.10
215    telepathy-farsight >= $TELEPATHY_FARSIGHT_REQUIRED
216 ])
217
218 AC_DEFINE(EMPATHY_GOA_PROVIDER, "org.gnome.OnlineAccounts",
219    [Name of provider for accounts imported from GOA])
220
221 # -----------------------------------------------------------
222 # Call interface
223 # -----------------------------------------------------------
224 AC_ARG_ENABLE(call,
225             AS_HELP_STRING([--enable-call=@<:@no/yes/auto@:>@],
226             [build with Call interface support]),,
227             [enable_call=auto])
228 if test "x$enable_call" != "xno" ; then
229    PKG_CHECK_MODULES(EMPATHY_CALL,
230    [
231       farsight2-0.10
232       telepathy-farstream >= 0.1.2
233       clutter-1.0 >= $CLUTTER_REQUIRED
234       clutter-gtk-1.0
235       clutter-gst-1.0
236    ], have_call="yes", have_call="no" )
237
238    if test "x$have_call" = "xyes"; then
239       AC_DEFINE(HAVE_CALL, 1, [Define if you have Call channel support])
240    fi
241 else
242   have_call=no
243 fi
244
245 if test "x$enable_call" = "xyes" -a "x$have_call" != "xyes"; then
246    AC_MSG_ERROR([Could not find Call handler dependencies:
247
248 $EMPATHY_CALL_PKG_ERRORS])
249 fi
250 AM_CONDITIONAL(HAVE_CALL, test "x$have_call" = "xyes")
251
252
253 # -----------------------------------------------------------
254 # Call support in tp-logger
255 # -----------------------------------------------------------
256 AC_ARG_ENABLE(call-logs,
257             AS_HELP_STRING([--enable-call-logs=@<:@no/yes/auto@:>@],
258             [build with call logs support]),,
259             [enable_call_logs=auto])
260 if test "x$enable_call_logs" != "xno" ; then
261    SAVE_CFLAGS=$CFLAGS
262    SAVE_CPPFLAGS=$CPPFLAGS
263    SAVE_LDFLAGS=$LDFLAGS
264    CFLAGS="$CFLAGS $EMPATHY_CFLAGS"
265    CPPFLAGS="$CPPFLAGS $EMPATHY_CFLAGS"
266    LDFLAGS="$LDFLAGS $EMPATHY_LDFLAGS"
267
268    AC_CHECK_HEADER(telepathy-logger/call-event.h,
269       have_call_logs="yes", have_call_logs="no")
270
271    CFLAGS=$SAVE_CFLAGS
272    CPPFLAGS=$SAVE_CPPFLAGS
273    LDFLAGS=$SAVE_LDFLAGS
274
275    if test "x$have_call_logs" = "xyes"; then
276       AC_DEFINE(HAVE_CALL_LOGS, 1, [Define if you have call log support])
277    fi
278 else
279   have_call_logs=no
280 fi
281
282 if test "x$enable_call_logs" = "xyes" -a "x$have_call_logs" != "xyes"; then
283    AC_MSG_ERROR([Call logs support requested but telepathy-logger wasn't
284                  built with --enable-call])
285 fi
286
287 # -----------------------------------------------------------
288 # evolution-data-server (about-me)
289 # -----------------------------------------------------------
290 AC_ARG_WITH(eds,
291             AS_HELP_STRING([--with-eds],
292                            [build with evolution-data-server support]),,
293             [with_eds=yes])
294 if test x"$with_eds" = x"yes" ; then
295    PKG_CHECK_MODULES(EDS, [libebook-1.2])
296    AC_DEFINE(HAVE_EDS, 1, [Define if we have libebook])
297 fi
298
299 # -----------------------------------------------------------
300 # Enable debug
301 # -----------------------------------------------------------
302
303 AC_ARG_ENABLE(debug,
304   AS_HELP_STRING([--disable-debug],
305                  [compile without debug code]),
306     enable_debug=$enableval, enable_debug=yes )
307
308 if test x$enable_debug = xyes; then
309   AC_DEFINE(ENABLE_DEBUG, [], [Enable debug code])
310 fi
311
312 # -----------------------------------------------------------
313 # Language Support
314 # -----------------------------------------------------------
315 IT_PROG_INTLTOOL([0.40.0])
316
317 AM_GNU_GETTEXT_VERSION([0.17])
318 AM_GNU_GETTEXT([external])
319
320 GETTEXT_PACKAGE=empathy
321 AC_SUBST(GETTEXT_PACKAGE)
322 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[Gettext package name])
323
324 # -----------------------------------------------------------
325 # Connectivity integration
326 # -----------------------------------------------------------
327 AC_ARG_WITH(connectivity,
328               AS_HELP_STRING([--with-connectivity=@<:@nm/connman/auto/no@:>@],
329                              [build with connectivity support]), ,
330                              with_connectivity=auto)
331
332 if test "x$with_connectivity" = "xno"; then
333    have_nm=no
334    have_connman=no
335
336 elif test "x$with_connectivity" = "xconnman"; then
337    have_nm=no
338
339    PKG_CHECK_MODULES(CONNMAN,
340    [
341       dbus-glib-1
342    ], have_connman="yes", have_connman="no")
343
344    if test "x$have_connman" = "xyes"; then
345       AC_DEFINE(HAVE_CONNMAN, 1, [Define if you have connman dependencies])
346    fi
347
348 else
349    have_connman=no
350
351    PKG_CHECK_MODULES(NETWORK_MANAGER,
352    [
353       libnm-glib >= $NETWORK_MANAGER_REQUIRED
354    ], have_nm="yes", have_nm="no")
355
356    if test "x$have_nm" = "xyes"; then
357       AC_DEFINE(HAVE_NM, 1, [Define if you have libnm-glib])
358    fi
359 fi
360
361 if test "x$with_connectivity" = "xconnman" -a "x$have_connman" != "xyes"; then
362    AC_MSG_ERROR([Couldn't find connman dependencies:
363
364 $CONNMAN_PKG_ERRORS])
365 fi
366
367 if test "x$with_connectivity" = "xnm" -a "x$have_nm" != "xyes"; then
368    AC_MSG_ERROR([Couldn't find Network Manager dependencies:
369
370 $NETWORK_MANAGER_PKG_ERRORS])
371 fi
372
373 AM_CONDITIONAL(HAVE_NM, test "x$have_nm" = "xyes")
374 AM_CONDITIONAL(HAVE_CONNMAN, test "x$have_connman" = "xyes")
375
376 # -----------------------------------------------------------
377 # gudev
378 # -----------------------------------------------------------
379 AC_ARG_ENABLE(gudev,
380               AS_HELP_STRING([--enable-gudev=@<:@no/yes/auto@:>@],
381                              [build with gudev support]), ,
382                              enable_gudev=auto)
383
384 if test "x$enable_gudev" != "xno"; then
385
386    PKG_CHECK_MODULES(UDEV, [gudev-1.0],
387         have_gudev="yes", have_gudev="no")
388
389    if test "x$have_gudev" = "xyes"; then
390       AC_DEFINE(HAVE_UDEV, 1, [Define if you have gudev])
391    fi
392 else
393    have_gudev=no
394 fi
395
396 if test "x$enable_gudev" = "xyes" -a "x$have_gudev" != "xyes"; then
397    AC_MSG_ERROR([Could not find gudev dependencies:
398
399 $UDEV_PKG_ERRORS])
400 fi
401 AM_CONDITIONAL(HAVE_UDEV, test "x$have_gudev" = "xyes")
402
403 # -----------------------------------------------------------
404 # spellchecking checks: enchant and iso-codes
405 # -----------------------------------------------------------
406 AC_ARG_ENABLE(spell,
407               AS_HELP_STRING([--enable-spell=@<:@no/yes/auto@:>@],
408                              [Enable spell checking]), ,
409                              enable_spell=auto)
410
411 if test "x$enable_spell" != "xno"; then
412    PKG_CHECK_MODULES(ENCHANT,
413    [
414       enchant >= $ENCHANT_REQUIRED,
415       iso-codes >= $ISO_CODES_REQUIRED
416    ], have_enchant="yes", have_enchant="no")
417
418    if test "x$have_enchant" = "xyes"; then
419       AC_MSG_CHECKING([whether iso-codes has iso-639 and iso-3166 domains])
420       if $PKG_CONFIG --variable=domains iso-codes | grep 639 > /dev/null && \
421          $PKG_CONFIG --variable=domains iso-codes | grep 3166 > /dev/null ; then
422             AC_DEFINE_UNQUOTED(ISO_CODES_PREFIX, ["`$PKG_CONFIG --variable=prefix iso-codes`"], [ISO codes prefix])
423             AC_DEFINE(HAVE_ENCHANT, [], [Define if you have libenchant])
424             result=yes
425       else
426             result=no
427             have_enchant="no"
428       fi
429       AC_MSG_RESULT([$result])
430    fi
431 else
432    have_enchant=no
433 fi
434
435 if test "x$enable_spell" = "xyes" -a "x$have_enchant" != "xyes"; then
436    AC_MSG_ERROR([Could not find spell-checking dependencies:
437
438 $ENCHANT_PKG_ERRORS])
439 fi
440
441 AM_CONDITIONAL(HAVE_ENCHANT, test "x$have_enchant" = "xyes")
442
443 # -----------------------------------------------------------
444 # Map view checks: libchamplain
445 # -----------------------------------------------------------
446 AC_ARG_ENABLE(map,
447               AS_HELP_STRING([--enable-map=@<:@no/yes/auto@:>@],
448                              [Enable map view]), ,
449                              enable_map=auto)
450
451 if test "x$enable_map" != "xno"; then
452
453    PKG_CHECK_MODULES(LIBCHAMPLAIN,
454     [
455        clutter-gtk-1.0
456        champlain-gtk-0.12
457        champlain-0.12 >= $CHAMPLAIN_REQUIRED
458     ], have_libchamplain="yes", have_libchamplain="no")
459
460    if test "x$have_libchamplain" = "xyes"; then
461       AC_DEFINE(HAVE_LIBCHAMPLAIN, 1, [Define if you have libchamplain])
462    fi
463 else
464    have_libchamplain=no
465 fi
466
467 if test "x$enable_map" = "xyes" -a "x$have_libchamplain" != "xyes"; then
468    AC_MSG_ERROR([Could not find map view dependencies:
469
470 $LIBCHAMPLAIN_PKG_ERRORS])
471 fi
472
473 AM_CONDITIONAL(HAVE_LIBCHAMPLAIN, test "x$have_libchamplain" = "xyes")
474
475 # -----------------------------------------------------------
476 # location checks: geoclue
477 # -----------------------------------------------------------
478 AC_ARG_ENABLE(location,
479               AS_HELP_STRING([--enable-location=@<:@no/yes/auto@:>@],
480                              [Enable location awareness]), ,
481                              enable_location=auto)
482
483 if test "x$enable_location" != "xno"; then
484    PKG_CHECK_MODULES(GEOCLUE,
485    [
486       geoclue >= $GEOCLUE_REQUIRED
487    ], have_geoclue="yes", have_geoclue="no")
488
489    if test "x$have_geoclue" = "xyes"; then
490       AC_DEFINE(HAVE_GEOCLUE, 1, [Define if you have geoclue])
491    fi
492 else
493    have_geoclue="no"
494 fi
495
496 if test "x$enable_location" = "xyes" -a "x$have_geoclue" != "xyes"; then
497    AC_MSG_ERROR([Could not find location dependencies:
498
499 $GEOCLUE_PKG_ERRORS])
500 fi
501
502 AM_CONDITIONAL(HAVE_GEOCLUE, test "x$have_geoclue" = "xyes")
503 AC_SUBST(GEOCLUE_CFLAGS)
504 AC_SUBST(GEOCLUE_LIBS)
505
506 # -----------------------------------------------------------
507 # location checks: geocode-glib
508 # -----------------------------------------------------------
509 AC_ARG_ENABLE(geocode,
510               AS_HELP_STRING([--enable-geocode=@<:@no/yes/auto@:>@],
511                              [Enable geocode support]), ,
512                              enable_geocode=auto)
513
514 if test "x$enable_geocode" != "xno"; then
515    PKG_CHECK_MODULES(GEOCODE,
516    [
517       geocode-glib
518    ], have_geocode="yes", have_geocode="no")
519
520    if test "x$have_geocode" = "xyes"; then
521       AC_DEFINE(HAVE_GEOCODE, 1, [Define if you have geocode])
522    fi
523 else
524    have_geocode="no"
525 fi
526
527 if test "x$enable_geocode" = "xyes" -a "x$have_geocode" != "xyes"; then
528    AC_MSG_ERROR([Could not find geocode dependencies:
529
530 $GEOCODE_PKG_ERRORS])
531 fi
532
533 AM_CONDITIONAL(HAVE_GEOCODE, test "x$have_geocode" = "xyes")
534 AC_SUBST(GEOCODE_CFLAGS)
535 AC_SUBST(GEOCODE_LIBS)
536
537 # -----------------------------------------------------------
538 # meego widgets support
539 # -----------------------------------------------------------
540 AC_ARG_ENABLE(meego,
541               AS_HELP_STRING([--enable-meego=@<:@no/yes@:>@],
542                              [Enable meego widgets]), ,
543                              enable_meego=no)
544
545 if test "x$enable_meego" != "xno"; then
546     PKG_CHECK_MODULES(MEEGO,
547     [
548        mx-gtk-1.0
549        gio-unix-2.0
550     ], have_meego="yes", have_meego="no")
551
552     if test "x$have_meego" = "xyes"; then
553        AC_DEFINE(HAVE_MEEGO, 1, [Define if you have meego])
554     fi
555 else
556    have_meego="no"
557 fi
558
559 if test "x$enable_meego" = "xyes" -a "x$have_meego" != "xyes"; then
560    AC_MSG_ERROR([Could not find meego dependencies:
561
562 $MEEGO_PKG_ERRORS])
563 fi
564
565 AM_CONDITIONAL(HAVE_MEEGO, test "x$have_meego" = "xyes")
566 AC_SUBST(MEEGO_CFLAGS)
567 AC_SUBST(MEEGO_LIBS)
568
569 # -----------------------------------------------------------
570 # nautilus-sendto
571 # -----------------------------------------------------------
572 AC_ARG_ENABLE(nautilus-sendto,
573               AS_HELP_STRING([--enable-nautilus-sendto=@<:@no/yes/auto@:>@],
574                              [build nautilus-sendto plugin]), ,
575                              enable_nautilus_sendto=auto)
576
577 if test "x$enable_nautilus_sendto" != "xno"; then
578    PKG_CHECK_MODULES(NST,
579     [
580        nautilus-sendto >= $NAUTILUS_SENDTO_REQUIRED
581     ], have_nst="yes", have_nst="no")
582 else
583    have_nst=no
584 fi
585
586 if test "x$enable_nautilus_sendto" = "xyes" -a "x$have_nst" != "xyes"; then
587    AC_MSG_ERROR([Could not find nautilus-sendto dependencies:
588
589 $NST_PKG_ERRORS])
590 fi
591
592 AM_CONDITIONAL(HAVE_NST, test "x$have_nst" = "xyes")
593
594 # -----------------------------------------------------------
595 # goa-mc-plugin
596 # -----------------------------------------------------------
597 AC_ARG_ENABLE(goa,
598               AS_HELP_STRING([--enable-goa=@<:@no/yes/auto@:>@],
599                              [build GOA MC plugin]), ,
600                              enable_goa=auto)
601
602 if test "x$enable_goa" != "xno"; then
603    PKG_CHECK_MODULES(GOA,
604     [
605        mission-control-plugins
606        goa-1.0 >= $GOA_REQUIRED
607     ], have_goa="yes", have_goa="no")
608
609    AC_MSG_CHECKING([Mission Control plugins dir])
610    MISSION_CONTROL_PLUGINS_DIR=`pkg-config --variable=plugindir mission-control-plugins`
611
612    AC_MSG_RESULT([$MISSION_CONTROL_PLUGINS_DIR])
613    AC_SUBST(MISSION_CONTROL_PLUGINS_DIR)
614 else
615    have_goa=no
616 fi
617
618 if test "x$enable_goa" = "xyes" -a "x$have_goa" != "xyes"; then
619    AC_MSG_ERROR([Could not find GOA dependencies.])
620 fi
621
622 if test "x$have_goa" = "xyes"; then
623    AC_DEFINE(HAVE_GOA, 1, [Define to 1 to enable GNOME Online Accounts])
624 fi
625
626 AM_CONDITIONAL(HAVE_GOA, test "x$have_goa" = "xyes")
627
628 # Optional dependency for avatar selection
629 AC_ARG_WITH([cheese],
630             AS_HELP_STRING([--with-cheese],
631                            [enable cheese webcam support]),,
632             with_cheese=auto)
633
634 if test x"$with_cheese" != x"no" ; then
635    PKG_CHECK_MODULES(CHEESE, gstreamer-0.10 cheese-gtk >= 2.91.91.1, [have_cheese=yes], [have_cheese=no])
636    if test x${have_cheese} = xyes; then
637      AC_DEFINE(HAVE_CHEESE, 1, [Define to 1 to enable cheese webcam support])
638    fi
639    if test x${with_cheese} = xyes && test x${have_cheese} = xno; then
640      AC_MSG_ERROR([Cheese configured but not found:
641
642 $CHEESE_PKG_ERRORS])
643    fi
644 else
645    have_cheese=no
646 fi
647 AM_CONDITIONAL(BUILD_CHEESE, test x${have_cheese} = xyes)
648
649
650 # -----------------------------------------------------------
651 # Coding style checks
652 # -----------------------------------------------------------
653 AC_ARG_ENABLE(coding-style-checks,
654   AS_HELP_STRING([--disable-coding-style-checks],
655                  [do not check coding style using grep]),
656     [ENABLE_CODING_STYLE_CHECKS=$enableval],
657     [ENABLE_CODING_STYLE_CHECKS=yes])
658
659 AC_SUBST([ENABLE_CODING_STYLE_CHECKS])
660 # -----------------------------------------------------------
661
662 AC_CONFIG_FILES([
663    Makefile
664    data/Makefile
665    data/empathy.desktop.in
666    data/empathy-accounts.desktop.in
667    data/icons/Makefile
668    extensions/Makefile
669    po/Makefile.in
670    libempathy/Makefile
671    libempathy-gtk/Makefile
672    src/Makefile
673    nautilus-sendto-plugin/Makefile
674    goa-mc-plugin/Makefile
675    help/Makefile
676    tests/Makefile
677    tests/interactive/Makefile
678    tests/xml/Makefile
679    tools/Makefile
680 ])
681 AC_OUTPUT
682
683 echo "
684 Configure summary:
685
686         Compiler....................:  ${CC}
687         Compiler Flags..............:  ${CFLAGS} ${ERROR_CFLAGS}
688         Linker Flags................:  ${LDFLAGS}
689         Prefix......................:  ${prefix}
690         Coding style checks.........:  ${ENABLE_CODING_STYLE_CHECKS}
691
692     Features:
693         Spell checking (enchant)....:  ${have_enchant}
694         Display maps (libchamplain).:  ${have_libchamplain}
695         Location awareness (Geoclue):  ${have_geoclue}
696         Geocode support (Geocode)...:  ${have_geocode}
697         Meego widgets...............:  ${have_meego}
698         Cheese webcam support ......:  ${have_cheese}
699         Camera monitoring...........:  ${have_gudev}
700
701     Connectivity:
702         NetworkManager integration..:  ${have_nm}
703         ConnMan integration.........:  ${have_connman}
704
705     Extras:
706         Nautilus-sendto plugin......:  ${have_nst}
707         GOA MC plugin...............:  ${have_goa}
708         Salut E-D-S support.........:  ${with_eds}
709         Exp. Call channel handler...:  ${have_call}
710         Exp. Call log support.......:  ${have_call_logs}
711 "