]> git.0d.be Git - empathy.git/blob - configure.ac
Fix crash when displaying google account vcard
[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], [8])
6 m4_define([empathy_micro_version], [1])
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.9.0
38 GNUTLS_REQUIRED=2.8.5
39
40 GLIB_REQUIRED=2.33.3
41 AC_DEFINE(GLIB_VERSION_MIN_REQUIRED, GLIB_VERSION_2_30, [Ignore post 2.30 deprecations])
42 AC_DEFINE(GLIB_VERSION_MAX_ALLOWED, GLIB_VERSION_2_34, [Prevent post 2.34 APIs])
43
44 GTK_REQUIRED=3.5.1
45 AC_DEFINE(GDK_VERSION_MIN_REQUIRED, GDK_VERSION_3_4, [Ignore post 3.4 deprecations])
46 AC_DEFINE(GDK_VERSION_MAX_ALLOWED, GDK_VERSION_3_4, [Prevent post 3.4 APIs])
47
48 CLUTTER_REQUIRED=1.10.0
49 AC_DEFINE(CLUTTER_VERSION_MIN_REQUIRED, CLUTTER_VERSION_1_8, [Ignore post 1.8 deprecations])
50 AC_DEFINE(CLUTTER_VERSION_MAX_ALLOWED, CLUTTER_VERSION_1_10, [Prevent post 1.10 APIs])
51
52 CLUTTER_GTK_REQUIRED=1.1.2
53
54 TELEPATHY_GLIB_REQUIRED=0.19.9
55 AC_DEFINE(TP_VERSION_MIN_REQUIRED, TP_VERSION_0_20, [Ignore post 0.20 deprecations])
56 AC_DEFINE(TP_VERSION_MAX_ALLOWED, TP_VERSION_0_20, [Prevent post 0.20 APIs])
57 AC_DEFINE(TP_SEAL_ENABLE, 1, [Prevent to use sealed variables])
58 AC_DEFINE(TP_DISABLE_SINGLE_INCLUDE, 1, [Disable single include header])
59
60 GSTREAMER_REQUIRED=0.10.32
61 TP_FS_REQUIRED=0.6.0
62 LIBSECRET_REQUIRED=0.5
63 GCR_REQUIRED=2.91.4
64 LIBCANBERRA_GTK_REQUIRED=0.25
65 LIBNOTIFY_REQUIRED=0.7.0
66 TELEPATHY_LOGGER=0.8.0
67 WEBKIT_REQUIRED=1.9.1
68 GOA_REQUIRED=3.5.1
69
70 # Optional deps
71 ENCHANT_REQUIRED=1.2.0
72 GEOCLUE_REQUIRED=0.12
73 GEOCODE_GLIB_REQUIRED=0.99.1
74 ISO_CODES_REQUIRED=0.35
75 NAUTILUS_SENDTO_REQUIRED=2.90.0
76 NETWORK_MANAGER_REQUIRED=0.7.0
77 CHAMPLAIN_REQUIRED=0.12.1
78 CHEESE_GTK_REQUIRED=3.4.0
79 LIBACCOUNTS_REQUIRED=1.4
80 LIBSIGNON_REQUIRED=1.1
81 MC_PLUGINS_REQUIRED=5.13.1
82
83 # Use --enable-maintainer-mode to disable deprecated symbols,
84 # disable single include and enable GSEAL. If this is not a released empathy,
85 # maintainer mode is forced
86 # FIXME: don't disable deprecated symbols until bgo #636654 has been fixed
87 #ifelse(empathy_released, 1, [], [enable_maintainer_mode="yes"])
88 #GNOME_MAINTAINER_MODE_DEFINES
89
90 # egg-list-box
91 prev_top_build_prefix=$ac_top_build_prefix
92 prev_ac_configure_args=$ac_configure_args
93 AX_CONFIG_DIR([libempathy-gtk/egg-list-box])
94 ac_top_build_prefix=$prev_top_build_prefix
95 ac_configure_args=$prev_ac_configure_args
96
97 export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:"$ac_top_build_prefix"libempathy-gtk/egg-list-box
98 PKG_CHECK_MODULES(EGGLISTBOX, egg-list-box)
99
100 AC_CONFIG_MACRO_DIR([m4])
101 AC_CONFIG_HEADERS([config.h])
102 AC_CONFIG_SRCDIR([configure.ac])
103 AC_CONFIG_AUX_DIR(.)
104
105 AM_INIT_AUTOMAKE([1.11 no-define -Wno-portability tar-ustar no-dist-gzip dist-xz])
106
107 # Support silent build rules. Disable
108 # by either passing --disable-silent-rules to configure or passing V=1
109 # to make
110 AM_SILENT_RULES([yes])
111
112 # Check for programs
113 AC_PROG_CC
114 AC_HEADER_STDC
115 AM_PROG_MKDIR_P
116 AM_PATH_GLIB_2_0
117 AC_PATH_XTRA
118
119 # Initialize libtool
120 LT_PREREQ([2.2])
121 LT_INIT
122
123 AC_PATH_PROG(DBUS_BINDING_TOOL, dbus-binding-tool)
124 GLIB_GSETTINGS
125
126 GLIB_COMPILE_RESOURCES=`$PKG_CONFIG gio-2.0 --variable=glib_compile_resources`
127 AC_SUBST(GLIB_COMPILE_RESOURCES)
128 GLIB_GENMARSHAL=`$PKG_CONFIG glib-2.0 --variable=glib_genmarshal`
129 AC_SUBST(GLIB_GENMARSHAL)
130
131 AC_CHECK_PROGS([XSLTPROC], [xsltproc])
132 if test -z "$XSLTPROC"; then
133   AC_MSG_ERROR([xsltproc (from libxslt) is required])
134 fi
135 AM_PATH_PYTHON([2.3])
136
137 EMPATHY_ARG_VALGRIND
138
139
140 # -----------------------------------------------------------
141 # Error flags
142 # -----------------------------------------------------------
143 AS_COMPILER_FLAG(-Wall, ERROR_CFLAGS="-Wall", ERROR_CFLAGS="")
144 AS_COMPILER_FLAG(-Werror, werror=yes, werror=no)
145
146 AC_ARG_ENABLE(Werror,
147   AS_HELP_STRING([--disable-Werror],
148                  [compile without -Werror (normally enabled in development builds)]),
149     werror=$enableval, :)
150
151 AS_COMPILER_FLAG(-Wextra, wextra=yes, wextra=no)
152 AS_COMPILER_FLAG(-Wno-missing-field-initializers,
153         wno_missing_field_initializers=yes,
154         wno_missing_field_initializers=no)
155 AS_COMPILER_FLAG(-Wno-unused-parameter,
156         wno_unused_parameter=yes,
157         wno_unused_parameter=no)
158
159 ifelse(empathy_released, 1, [],
160     [
161         if test x$werror = xyes; then
162             ERROR_CFLAGS="$ERROR_CFLAGS -Werror"
163         fi
164         if test x$wextra = xyes -a \
165             x$wno_missing_field_initializers = xyes -a \
166             x$wno_unused_parameter = xyes; then
167             ERROR_CFLAGS="$ERROR_CFLAGS -Wextra -Wno-missing-field-initializers -Wno-unused-parameter"
168         fi
169     ])
170
171 AS_COMPILER_FLAG(-Wdeclaration-after-statement, ERROR_CFLAGS="$ERROR_CFLAGS -Wdeclaration-after-statement")
172 AS_COMPILER_FLAG(-Wshadow, ERROR_CFLAGS="$ERROR_CFLAGS -Wshadow")
173 AS_COMPILER_FLAG(-Wmissing-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-prototypes")
174 AS_COMPILER_FLAG(-Wmissing-declarations, ERROR_CFLAGS="$ERROR_CFLAGS -Wmissing-declarations")
175 AS_COMPILER_FLAG(-Wstrict-prototypes, ERROR_CFLAGS="$ERROR_CFLAGS -Wstrict-prototypes")
176
177 AC_SUBST(ERROR_CFLAGS)
178
179 AC_ARG_ENABLE(gprof,
180             AS_HELP_STRING([--enable-gprof=@<:@no/yes@:>@],
181             [build with support for gprof]),,
182             [enable_gprof=no])
183 if test "x$enable_gprof" != "xno" ; then
184     CFLAGS="$CFLAGS -pg"
185     LDFLAGS="$LDFLAGS -pg"
186 fi
187
188 AC_SUBST(LDFLAGS)
189
190 # -----------------------------------------------------------
191 # Pkg-Config dependency checks
192 # -----------------------------------------------------------
193
194 AC_CHECK_LIBM
195 AC_SUBST(LIBM)
196
197 PKG_CHECK_MODULES(EMPATHY,
198 [
199    dbus-glib-1
200    folks >= $FOLKS_REQUIRED
201    folks-telepathy >= $FOLKS_REQUIRED
202    glib-2.0 >= $GLIB_REQUIRED
203    gio-2.0 >= $GLIB_REQUIRED
204    gio-unix-2.0 >= $GLIB_REQUIRED
205    libsecret-1 >= $LIBSECRET_REQUIRED
206    gnutls >= $GNUTLS_REQUIRED
207    gmodule-export-2.0
208    gobject-2.0
209    gsettings-desktop-schemas
210    libxml-2.0
211    telepathy-glib >= $TELEPATHY_GLIB_REQUIRED
212    telepathy-logger-0.2 >= $TELEPATHY_LOGGER
213    x11
214    gtk+-3.0 >= $GTK_REQUIRED
215    libcanberra-gtk3 >= $LIBCANBERRA_GTK_REQUIRED
216    libnotify >= $LIBNOTIFY_REQUIRED
217    gcr-3 >= $GCR_REQUIRED
218    libpulse
219    libpulse-mainloop-glib
220    webkitgtk-3.0 >= $WEBKIT_REQUIRED
221    libsoup-2.4
222    gee-0.8
223 ])
224
225 # -----------------------------------------------------------
226 # GStreamer
227 # -----------------------------------------------------------
228 AC_ARG_ENABLE(gst-1.0,
229               AS_HELP_STRING([--enable-gst-1.0=@<:@no/yes/auto@:>@],
230                              [build with GStreamer 1.0]),
231                              enable_gst1=$enableval,
232                              enable_gst1=auto)
233
234 # Try to use GStreamer 1.0 if available
235 have_gst1="no"
236 if test "x$enable_gst1" != "xno"; then
237   PKG_CHECK_MODULES(EMPATHY_CALL,
238   [
239      farstream-0.2
240      telepathy-farstream >= $TP_FS_REQUIRED
241      clutter-1.0 >= $CLUTTER_REQUIRED
242      clutter-gtk-1.0 >= $CLUTTER_GTK_REQUIRED
243      clutter-gst-2.0
244      gstreamer-1.0
245      gstreamer-audio-1.0
246      gstreamer-video-1.0
247      cogl-1.0
248   ], have_gst1="yes", have_gst1="no")
249
250   if test "x$have_gst1" = "xyes"; then
251     AC_DEFINE(HAVE_GST1, 1, [Build with GStreamer 1.0])
252   fi
253 fi
254
255 if test "x$enable_gst1" = "xyes" -a "x$have_gst1" != "xyes"; then
256    AC_MSG_ERROR([Could not find GStreamer 1.0 dependencies:
257
258 $EMPATHY_CALL_PKG_ERRORS])
259 fi
260
261 if test "x$have_gst1" != "xyes"; then
262   PKG_CHECK_MODULES(EMPATHY_CALL,
263   [
264      farstream-0.1
265      telepathy-farstream >= $TP_FS_REQUIRED
266      clutter-1.0 >= $CLUTTER_REQUIRED
267      clutter-gtk-1.0 >= $CLUTTER_GTK_REQUIRED
268      clutter-gst-1.0 >= 1.5.2
269      gstreamer-0.10 >= $GSTREAMER_REQUIRED
270      gstreamer-interfaces-0.10
271   ])
272 fi
273
274 AC_DEFINE(EMPATHY_GOA_PROVIDER, "org.gnome.OnlineAccounts",
275    [Name of provider for accounts imported from GOA])
276
277 AC_DEFINE(EMPATHY_UOA_PROVIDER,
278     "im.telepathy.Account.Storage.UOA",
279    [Name of provider for accounts imported from libaccounts])
280
281 # -----------------------------------------------------------
282 # Enable debug
283 # -----------------------------------------------------------
284
285 AC_ARG_ENABLE(debug,
286   AS_HELP_STRING([--disable-debug],
287                  [compile without debug code]),
288     enable_debug=$enableval, enable_debug=yes )
289
290 if test x$enable_debug = xyes; then
291   AC_DEFINE(ENABLE_DEBUG, [], [Enable debug code])
292 fi
293
294 # -----------------------------------------------------------
295 # Language Support
296 # -----------------------------------------------------------
297 IT_PROG_INTLTOOL([0.50.0])
298
299 GETTEXT_PACKAGE=empathy
300 AC_SUBST(GETTEXT_PACKAGE)
301 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[Gettext package name])
302
303 # -----------------------------------------------------------
304 # gudev
305 # -----------------------------------------------------------
306 AC_ARG_ENABLE(gudev,
307               AS_HELP_STRING([--enable-gudev=@<:@no/yes/auto@:>@],
308                              [build with gudev support]), ,
309                              enable_gudev=auto)
310
311 if test "x$enable_gudev" != "xno"; then
312
313    PKG_CHECK_MODULES(UDEV, [gudev-1.0],
314         have_gudev="yes", have_gudev="no")
315
316    if test "x$have_gudev" = "xyes"; then
317       AC_DEFINE(HAVE_UDEV, 1, [Define if you have gudev])
318    fi
319 else
320    have_gudev=no
321 fi
322
323 if test "x$enable_gudev" = "xyes" -a "x$have_gudev" != "xyes"; then
324    AC_MSG_ERROR([Could not find gudev dependencies:
325
326 $UDEV_PKG_ERRORS])
327 fi
328 AM_CONDITIONAL(HAVE_UDEV, test "x$have_gudev" = "xyes")
329
330 # -----------------------------------------------------------
331 # spellchecking checks: enchant and iso-codes
332 # -----------------------------------------------------------
333 AC_ARG_ENABLE(spell,
334               AS_HELP_STRING([--enable-spell=@<:@no/yes/auto@:>@],
335                              [Enable spell checking]), ,
336                              enable_spell=auto)
337
338 if test "x$enable_spell" != "xno"; then
339    PKG_CHECK_MODULES(ENCHANT,
340    [
341       enchant >= $ENCHANT_REQUIRED,
342       iso-codes >= $ISO_CODES_REQUIRED
343    ], have_enchant="yes", have_enchant="no")
344
345    if test "x$have_enchant" = "xyes"; then
346       AC_MSG_CHECKING([whether iso-codes has iso-639 and iso-3166 domains])
347       if $PKG_CONFIG --variable=domains iso-codes | grep 639 > /dev/null && \
348          $PKG_CONFIG --variable=domains iso-codes | grep 3166 > /dev/null ; then
349             AC_DEFINE_UNQUOTED(ISO_CODES_PREFIX, ["`$PKG_CONFIG --variable=prefix iso-codes`"], [ISO codes prefix])
350             AC_DEFINE(HAVE_ENCHANT, [], [Define if you have libenchant])
351             result=yes
352       else
353             result=no
354             have_enchant="no"
355       fi
356       AC_MSG_RESULT([$result])
357    fi
358 else
359    have_enchant=no
360 fi
361
362 if test "x$enable_spell" = "xyes" -a "x$have_enchant" != "xyes"; then
363    AC_MSG_ERROR([Could not find spell-checking dependencies:
364
365 $ENCHANT_PKG_ERRORS])
366 fi
367
368 AM_CONDITIONAL(HAVE_ENCHANT, test "x$have_enchant" = "xyes")
369
370 # -----------------------------------------------------------
371 # Map view checks: libchamplain
372 # -----------------------------------------------------------
373 AC_ARG_ENABLE(map,
374               AS_HELP_STRING([--enable-map=@<:@no/yes/auto@:>@],
375                              [Enable map view]), ,
376                              enable_map=auto)
377
378 if test "x$enable_map" != "xno"; then
379
380    PKG_CHECK_MODULES(LIBCHAMPLAIN,
381     [
382        clutter-gtk-1.0
383        champlain-gtk-0.12
384        champlain-0.12 >= $CHAMPLAIN_REQUIRED
385     ], have_libchamplain="yes", have_libchamplain="no")
386
387    if test "x$have_libchamplain" = "xyes"; then
388       AC_DEFINE(HAVE_LIBCHAMPLAIN, 1, [Define if you have libchamplain])
389    fi
390 else
391    have_libchamplain=no
392 fi
393
394 if test "x$enable_map" = "xyes" -a "x$have_libchamplain" != "xyes"; then
395    AC_MSG_ERROR([Could not find map view dependencies:
396
397 $LIBCHAMPLAIN_PKG_ERRORS])
398 fi
399
400 AM_CONDITIONAL(HAVE_LIBCHAMPLAIN, test "x$have_libchamplain" = "xyes")
401
402 # -----------------------------------------------------------
403 # location checks: geoclue
404 # -----------------------------------------------------------
405 AC_ARG_ENABLE(location,
406               AS_HELP_STRING([--enable-location=@<:@no/yes/auto@:>@],
407                              [Enable location awareness]), ,
408                              enable_location=auto)
409
410 if test "x$enable_location" != "xno"; then
411    PKG_CHECK_MODULES(GEOCLUE,
412    [
413       geoclue >= $GEOCLUE_REQUIRED
414    ], have_geoclue="yes", have_geoclue="no")
415
416    if test "x$have_geoclue" = "xyes"; then
417       AC_DEFINE(HAVE_GEOCLUE, 1, [Define if you have geoclue])
418    fi
419 else
420    have_geoclue="no"
421 fi
422
423 if test "x$enable_location" = "xyes" -a "x$have_geoclue" != "xyes"; then
424    AC_MSG_ERROR([Could not find location dependencies:
425
426 $GEOCLUE_PKG_ERRORS])
427 fi
428
429 AM_CONDITIONAL(HAVE_GEOCLUE, test "x$have_geoclue" = "xyes")
430 AC_SUBST(GEOCLUE_CFLAGS)
431 AC_SUBST(GEOCLUE_LIBS)
432
433 # -----------------------------------------------------------
434 # location checks: geocode-glib
435 # -----------------------------------------------------------
436 AC_ARG_ENABLE(geocode,
437               AS_HELP_STRING([--enable-geocode=@<:@no/yes/auto@:>@],
438                              [Enable geocode support]), ,
439                              enable_geocode=auto)
440
441 if test "x$enable_geocode" != "xno"; then
442    PKG_CHECK_MODULES(GEOCODE,
443    [
444       geocode-glib >= $GEOCODE_GLIB_REQUIRED
445    ], have_geocode="yes", have_geocode="no")
446
447    if test "x$have_geocode" = "xyes"; then
448       AC_DEFINE(HAVE_GEOCODE, 1, [Define if you have geocode])
449    fi
450 else
451    have_geocode="no"
452 fi
453
454 if test "x$enable_geocode" = "xyes" -a "x$have_geocode" != "xyes"; then
455    AC_MSG_ERROR([Could not find geocode dependencies:
456
457 $GEOCODE_PKG_ERRORS])
458 fi
459
460 AM_CONDITIONAL(HAVE_GEOCODE, test "x$have_geocode" = "xyes")
461 AC_SUBST(GEOCODE_CFLAGS)
462 AC_SUBST(GEOCODE_LIBS)
463
464 # -----------------------------------------------------------
465 # nautilus-sendto
466 # -----------------------------------------------------------
467 AC_ARG_ENABLE(nautilus-sendto,
468               AS_HELP_STRING([--enable-nautilus-sendto=@<:@no/yes/auto@:>@],
469                              [build nautilus-sendto plugin]), ,
470                              enable_nautilus_sendto=auto)
471
472 if test "x$enable_nautilus_sendto" != "xno"; then
473    PKG_CHECK_MODULES(NST,
474     [
475        nautilus-sendto >= $NAUTILUS_SENDTO_REQUIRED
476     ], have_nst="yes", have_nst="no")
477 else
478    have_nst=no
479 fi
480
481 if test "x$enable_nautilus_sendto" = "xyes" -a "x$have_nst" != "xyes"; then
482    AC_MSG_ERROR([Could not find nautilus-sendto dependencies:
483
484 $NST_PKG_ERRORS])
485 fi
486
487 AM_CONDITIONAL(HAVE_NST, test "x$have_nst" = "xyes")
488
489 # -----------------------------------------------------------
490 # goa-mc-plugin
491 # -----------------------------------------------------------
492 AC_ARG_ENABLE(goa,
493               AS_HELP_STRING([--enable-goa=@<:@no/yes/auto@:>@],
494                              [build GOA MC plugin]), ,
495                              enable_goa=auto)
496
497 if test "x$enable_goa" != "xno"; then
498    PKG_CHECK_MODULES(GOA,
499     [
500        mission-control-plugins
501        goa-1.0 >= $GOA_REQUIRED
502     ], have_goa="yes", have_goa="no")
503 else
504    have_goa=no
505 fi
506
507 if test "x$enable_goa" = "xyes" -a "x$have_goa" != "xyes"; then
508    AC_MSG_ERROR([Could not find GOA dependencies:
509
510 $GOA_PKG_ERRORS])
511 fi
512
513 if test "x$have_goa" = "xyes"; then
514    AC_DEFINE(HAVE_GOA, 1, [Define to 1 to enable GNOME Online Accounts])
515 fi
516
517 AM_CONDITIONAL(HAVE_GOA, test "x$have_goa" = "xyes")
518
519 # Optional dependency for avatar selection
520 AC_ARG_WITH([cheese],
521             AS_HELP_STRING([--with-cheese],
522                            [enable cheese webcam support]),,
523             with_cheese=auto)
524
525 if test x"$with_cheese" != x"no" ; then
526    PKG_CHECK_MODULES(CHEESE, cheese-gtk >= CHEESE_GTK_REQUIRED, [have_cheese=yes], [have_cheese=no])
527    if test x${have_cheese} = xyes; then
528      AC_DEFINE(HAVE_CHEESE, 1, [Define to 1 to enable cheese webcam support])
529    fi
530    if test x${with_cheese} = xyes && test x${have_cheese} = xno; then
531      AC_MSG_ERROR([Cheese configured but not found:
532
533 $CHEESE_PKG_ERRORS])
534    fi
535 else
536    have_cheese=no
537 fi
538 AM_CONDITIONAL(BUILD_CHEESE, test x${have_cheese} = xyes)
539
540 # -----------------------------------------------------------
541 # ubuntu-online-accounts support
542 # -----------------------------------------------------------
543 AC_ARG_ENABLE(ubuntu-online-accounts,
544               AS_HELP_STRING([--enable-ubuntu-online-accounts=@<:@no/yes/auto@:>@],
545                              [build Ubuntu Online Accounts plugins]), ,
546                              enable_ubuntu_online_accounts=auto)
547
548 if test "x$enable_ubuntu_online_accounts" != "xno"; then
549    PKG_CHECK_MODULES(UOA,
550     [
551        account-plugin
552        mission-control-plugins >= $MC_PLUGINS_REQUIRED
553        libaccounts-glib >= $LIBACCOUNTS_REQUIRED
554        libsignon-glib >= $LIBSIGNON_REQUIRED
555     ], have_uoa="yes", have_uoa="no")
556
557    # provider plugin dir
558    AC_MSG_CHECKING([Accounts provider plugin dir])
559    ACCOUNTS_PROVIDER_PLUGIN_DIR=`pkg-config --variable=provider_plugindir account-plugin`
560
561    AC_MSG_RESULT([$ACCOUNTS_PROVIDER_PLUGIN_DIR])
562    AC_SUBST(ACCOUNTS_PROVIDER_PLUGIN_DIR)
563
564    # app plugin dir
565    AC_MSG_CHECKING([Accounts provider app plugin dir])
566    ACCOUNTS_APP_PLUGIN_DIR=`pkg-config --variable=application_plugindir account-plugin`
567
568    AC_MSG_RESULT([$ACCOUNTS_APP_PLUGIN_DIR])
569    AC_SUBST(ACCOUNTS_APP_PLUGIN_DIR)
570
571    # provider files dir
572    AC_MSG_CHECKING([Accounts provider files dir])
573    ACCOUNTS_PROVIDER_FILES_DIR=`pkg-config --variable=providerfilesdir libaccounts-glib`
574
575    AC_MSG_RESULT([$ACCOUNTS_PROVIDER_FILES_DIR])
576    AC_SUBST(ACCOUNTS_PROVIDER_FILES_DIR)
577
578    # service files dir
579    AC_MSG_CHECKING([Accounts service files dir])
580    ACCOUNTS_SERVICE_FILES_DIR=`pkg-config --variable=servicefilesdir libaccounts-glib`
581
582    AC_MSG_RESULT([$ACCOUNTS_SERVICE_FILES_DIR])
583    AC_SUBST(ACCOUNTS_SERVICE_FILES_DIR)
584
585    # application files dir
586    AC_MSG_CHECKING([Accounts applications files dir])
587    ACCOUNTS_APPLICATION_FILES_DIR=`pkg-config --variable=applicationfilesdir libaccounts-glib`
588
589    AC_MSG_RESULT([$ACCOUNTS_APPLICATION_FILES_DIR])
590    AC_SUBST(ACCOUNTS_APPLICATION_FILES_DIR)
591
592 else
593    have_uoa=no
594 fi
595
596 if test "x$enable_ubuntu_online_accounts" = "xyes" -a "x$have_uoa" != "xyes"; then
597    AC_MSG_ERROR([Could not find Ubuntu Online Accounts dependencies:
598
599 $UOA_PKG_ERRORS])
600 fi
601
602 if test "x$have_uoa" = "xyes"; then
603    AC_DEFINE(HAVE_UOA, 1, [Define to 1 to build Ubuntu Online Accounts plugins])
604 fi
605
606 AM_CONDITIONAL(HAVE_UOA, test "x$have_uoa" = "xyes")
607
608 if test "x$have_uoa" = "xyes" -o "x$have_goa" = "xyes"; then
609    AC_MSG_CHECKING([Mission Control plugins dir])
610    MISSION_CONTROL_PLUGINS_DIR=${libdir}/mission-control-plugins.`pkg-config --variable=MCP_ABI_VERSION mission-control-plugins`
611
612    AC_MSG_RESULT([$MISSION_CONTROL_PLUGINS_DIR])
613    AC_SUBST(MISSION_CONTROL_PLUGINS_DIR)
614 fi
615
616
617 # Help documentation
618 YELP_HELP_INIT
619
620 # -----------------------------------------------------------
621 # Coding style checks
622 # -----------------------------------------------------------
623 AC_ARG_ENABLE(coding-style-checks,
624   AS_HELP_STRING([--disable-coding-style-checks],
625                  [do not check coding style using grep]),
626     [ENABLE_CODING_STYLE_CHECKS=$enableval],
627     [ENABLE_CODING_STYLE_CHECKS=yes])
628
629 AC_SUBST([ENABLE_CODING_STYLE_CHECKS])
630 # -----------------------------------------------------------
631
632 AC_CONFIG_FILES([
633    Makefile
634    data/Makefile
635    data/empathy.desktop.in
636    data/icons/Makefile
637    data/themes/Makefile
638    extensions/Makefile
639    po/Makefile.in
640    libempathy/Makefile
641    libempathy-gtk/Makefile
642    src/Makefile
643    nautilus-sendto-plugin/Makefile
644    goa-mc-plugin/Makefile
645    ubuntu-online-accounts/Makefile
646    ubuntu-online-accounts/mc-plugin/Makefile
647    ubuntu-online-accounts/cc-plugins/Makefile
648    ubuntu-online-accounts/cc-plugins/account-plugins/Makefile
649    ubuntu-online-accounts/cc-plugins/providers/Makefile
650    ubuntu-online-accounts/cc-plugins/services/Makefile
651    ubuntu-online-accounts/cc-plugins/app-plugin/Makefile
652    help/Makefile
653    tests/Makefile
654    tests/interactive/Makefile
655    tests/xml/Makefile
656    tests/certificates/Makefile
657    tools/Makefile
658 ])
659 AC_OUTPUT
660
661 echo "
662 Configure summary:
663
664         Compiler....................:  ${CC}
665         Compiler Flags..............:  ${CFLAGS} ${ERROR_CFLAGS}
666         Linker Flags................:  ${LDFLAGS}
667         Prefix......................:  ${prefix}
668         Coding style checks.........:  ${ENABLE_CODING_STYLE_CHECKS}
669         Use GStreamer 1.0...........:  ${have_gst1}
670
671     Features:
672         Spell checking (enchant)....:  ${have_enchant}
673         Display maps (libchamplain).:  ${have_libchamplain}
674         Location awareness (Geoclue):  ${have_geoclue}
675         Geocode support (Geocode)...:  ${have_geocode}
676         Cheese webcam support ......:  ${have_cheese}
677         Camera monitoring...........:  ${have_gudev}
678
679     Extras:
680         Nautilus-sendto plugin......:  ${have_nst}
681         GOA MC plugin...............:  ${have_goa}
682         Ubuntu Online plugins.......:  ${have_uoa}
683 "