1 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
2 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
3 m4_define([v_maj], [1])
4 m4_define([v_min], [2])
5 m4_define([v_mic], [0])
6 m4_define([v_rev], m4_esyscmd([(svnversion "${SVN_REPO_PATH:-.}" | grep -v '\(export\|Unversioned directory\)' || echo 0) | awk -F : '{printf("%s\n", $1);}' | tr -d ' :MSP\n']))
7 m4_if(v_rev, [0], [m4_define([v_rev], m4_esyscmd([git log 2> /dev/null | (grep -m1 git-svn-id || echo 0) | sed -e 's/.*@\([0-9]*\).*/\1/' | tr -d '\n']))])
8 ##-- When released, remove the dnl on the below line
10 ##-- When doing snapshots - change soname. remove dnl on below line
11 dnl m4_define([relname], [ver-pre-svn-07])
12 dnl m4_define([v_rel], [-release relname])
13 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
14 m4_ifdef([v_rev], [m4_define([v_ver], [v_maj.v_min.v_mic.v_rev])],
15 [m4_define([v_ver], [v_maj.v_min.v_mic])])
16 m4_define([lt_cur], m4_eval(v_maj + v_min))
17 m4_define([lt_rev], v_mic)
18 m4_define([lt_age], v_min)
19 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
20 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
22 AC_INIT([e_dbus], [v_ver], [enlightenment-devel@lists.sourceforge.net])
24 AC_CONFIG_SRCDIR([configure.ac])
25 AC_CONFIG_MACRO_DIR([m4])
27 AC_CONFIG_HEADERS([config.h])
29 #ifndef EFL_CONFIG_H__
30 #define EFL_CONFIG_H__
33 #endif /* EFL_CONFIG_H__ */
36 AM_INIT_AUTOMAKE([1.6 dist-bzip2])
37 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
40 define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl
41 define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl
44 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
45 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
46 m4_ifdef([v_rev], , [m4_define([v_rev], [0])])
47 m4_ifdef([v_rel], , [m4_define([v_rel], [])])
48 AC_DEFINE_UNQUOTED(VMAJ, [v_maj], [Major version])
49 AC_DEFINE_UNQUOTED(VMIN, [v_min], [Minor version])
50 AC_DEFINE_UNQUOTED(VMIC, [v_mic], [Micro version])
51 AC_DEFINE_UNQUOTED(VREV, [v_rev], [Revison])
52 version_info="lt_cur:lt_rev:lt_age"
54 AC_SUBST(version_info)
55 AC_SUBST(release_info)
56 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
57 ##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##
61 ### Needed information
67 want_econnman0_7x="yes"
76 want_econnman0_7x="no"
84 requirement_ebluez="edbus >= 1.2.0"
85 requirement_econnman0_7x="edbus >= 1.2.0"
86 requirement_edbus="ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62"
87 requirement_ehal="edbus >= 1.2.0"
88 requirement_enotify="edbus >= 1.2.0"
89 requirement_eofono="edbus >= 1.2.0"
90 requirement_eukit="edbus >= 1.2.0"
91 requirement_dbus="dbus-1 >= 0.62"
93 ### Additional options to configure
95 dnl Check enabled modules to build
97 AC_ARG_ENABLE([ebluez],
98 [AC_HELP_STRING([--enable-ebluez], [Enable ebluez build])],
99 [enable_ebluez=$enableval],
100 [enable_ebluez="${want_ebluez}"])
102 AC_ARG_ENABLE([econnman0_7x],
103 [AC_HELP_STRING([--enable-econnman0_7x], [Enable econnman 0.7x build])],
104 [enable_econnman0_7x=$enableval],
105 [enable_econnman0_7x="${want_econnman0_7x}"])
107 AC_ARG_ENABLE([ehal],
108 [AC_HELP_STRING([--disable-ehal], [Disable ehal build])],
109 [enable_ehal=$enableval],
110 [enable_ehal="${want_ehal}"])
112 AC_ARG_ENABLE([enotify],
113 [AC_HELP_STRING([--disable-enotify], [Disable enotify build])],
114 [enable_enotify=$enableval],
115 [enable_enotify="${want_enotify}"])
117 AC_ARG_ENABLE([eofono],
118 [AC_HELP_STRING([--enable-eofono], [Enable eofono build])],
119 [enable_eofono=$enableval],
120 [enable_eofono="${want_eofono}"])
122 AC_ARG_ENABLE([eukit],
123 [AC_HELP_STRING([--disable-eukit], [Disable eukit build])],
124 [enable_eukit=$enableval],
125 [enable_eukit="${want_eukit}"])
128 ### Checks for programs
136 # Check whether pkg-config supports Requires.private
137 if $PKG_CONFIG --atleast-pkgconfig-version 0.22 ; then
138 pkgconfig_requires_private="Requires.private"
140 pkgconfig_requires_private="Requires"
142 AC_SUBST(pkgconfig_requires_private)
144 # doxygen program for documentation building
145 EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"])
148 ### Checks for libraries
150 PKG_CHECK_MODULES([DBUS], [dbus-1 >= 0.62])
151 dbus_libs="$DBUS_LIBS"
152 dbus_cflags="$DBUS_CFLAGS"
154 AC_SUBST(dbus_cflags)
155 PKG_CHECK_MODULES([EDBUS], [ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62])
157 # Find out the version of DBUS we're using
158 dbus_version=`pkg-config --modversion dbus-1`
159 DBUS_VERSION_MAJOR=`echo $dbus_version | awk -F. '{print $1}'`
160 DBUS_VERSION_MINOR=`echo $dbus_version | awk -F. '{print $2}'`
161 DBUS_VERSION_MICRO=`echo $dbus_version | awk -F. '{print $3}'`
163 if test "z$DBUS_VERSION_MAJOR" = "z" ; then
164 DBUS_VERSION_MAJOR="0"
167 if test "z$DBUS_VERSION_MINOR" = "z" ; then
168 DBUS_VERSION_MINOR="0"
171 if test "z$DBUS_VERSION_MICRO" = "z" ; then
172 DBUS_VERSION_MICRO="0"
175 DBUS_VERSION_CFLAGS="$DBUS_VERSION_CFLAGS -DDBUS_VERSION_MAJOR=$DBUS_VERSION_MAJOR"
176 DBUS_VERSION_CFLAGS="$DBUS_VERSION_CFLAGS -DDBUS_VERSION_MINOR=$DBUS_VERSION_MINOR"
177 DBUS_VERSION_CFLAGS="$DBUS_VERSION_CFLAGS -DDBUS_VERSION_MICRO=$DBUS_VERSION_MICRO"
178 AC_SUBST(DBUS_VERSION_CFLAGS)
180 # Dependencies for the libraries
181 if test "x${enable_enotify}" = "xyes" ; then
182 PKG_CHECK_MODULES([EVAS],
184 [requirement_enotify="evas >= 1.2.0 ${requirement_enotify}"],
185 [enable_enotify="no"])
188 AM_CONDITIONAL([BUILD_EBLUEZ], [test "x${enable_ebluez}" = "xyes"])
189 AM_CONDITIONAL([BUILD_ECONNMAN0_7X], [test "x${enable_econnman0_7x}" = "xyes"])
190 AM_CONDITIONAL([BUILD_EHAL], [test "x${enable_ehal}" = "xyes"])
191 AM_CONDITIONAL([BUILD_ENOTIFY], [test "x${enable_enotify}" = "xyes"])
192 AM_CONDITIONAL([BUILD_EOFONO], [test "x${enable_eofono}" = "xyes"])
193 AM_CONDITIONAL([BUILD_EUKIT], [test "x${enable_eukit}" = "xyes"])
195 # Dependencies for the binaries
197 EFL_ENABLE_BIN([edbus-test], ["yes"])
198 EFL_ENABLE_BIN([edbus-test-client], ["yes"])
199 EFL_ENABLE_BIN([edbus-bluez-test], [${enable_ebluez}])
200 EFL_ENABLE_BIN([edbus-connman0_7x-test], [${enable_econnman0_7x}])
201 EFL_ENABLE_BIN([edbus-notification-daemon-test], [${enable_enotify}])
202 EFL_ENABLE_BIN([edbus-notify-send], [${enable_enotify}])
203 EFL_ENABLE_BIN([edbus-notify-test], [${enable_enotify}])
204 EFL_ENABLE_BIN([edbus-ofono-test], [${enable_eofono}])
205 EFL_ENABLE_BIN([edbus-ukit-test], [${enable_eukit}])
207 if test "x${have_edbus_test}" = "xyes" ; then
208 PKG_CHECK_MODULES([EDBUS_TEST],
209 [ecore >= 1.2.0 dbus-1 >= 0.62],
210 [have_edbus_test="yes"],
211 [have_edbus_test="no"])
214 if test "x${have_edbus_test_client}" = "xyes" ; then
215 PKG_CHECK_MODULES([EDBUS_TEST_CLIENT],
216 [ecore >= 1.2.0 dbus-1 >= 0.62],
217 [have_edbus_test_client="yes"],
218 [have_edbus_test_client="no"])
221 if test "x${have_edbus_bluez_test}" = "xyes" ; then
222 PKG_CHECK_MODULES([EDBUS_BLUEZ_TEST],
223 [ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
224 [have_edbus_bluez_test="yes"],
225 [have_edbus_bluez_test="no"])
228 if test "x${have_edbus_connman0_7x_test}" = "xyes" ; then
229 PKG_CHECK_MODULES([EDBUS_CONNMAN0_7X_TEST],
230 [ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
231 [have_edbus_connman0_7x_test="yes"],
232 [have_edbus_connman0_7x_test="no"])
235 if test "x${have_edbus_notification_daemon_test}" = "xyes" ; then
236 PKG_CHECK_MODULES([EDBUS_NOTIFICATION_DAEMON_TEST],
237 [ecore >= 1.2.0 evas >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
238 [have_edbus_notification_daemon_test="yes"],
239 [have_edbus_notification_daemon_test="no"])
242 if test "x${have_edbus_notify_send}" = "xyes" ; then
243 PKG_CHECK_MODULES([EDBUS_NOTIFY_SEND],
244 [ecore >= 1.2.0 evas >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
245 [have_edbus_notify_send="yes"],
246 [have_edbus_notify_send="no"])
249 if test "x${have_edbus_notify_test}" = "xyes" ; then
250 PKG_CHECK_MODULES([EDBUS_NOTIFY_TEST],
251 [ecore >= 1.2.0 ecore-evas >= 1.2.0 evas >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
252 [have_edbus_notify_test="yes"],
253 [have_edbus_notify_test="no"])
256 if test "x${have_edbus_ofono_test}" = "xyes" ; then
257 PKG_CHECK_MODULES([EDBUS_OFONO_TEST],
258 [ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
259 [have_edbus_ofono_test="yes"],
260 [have_edbus_ofono_test="no"])
263 if test "x${have_edbus_ukit_test}" = "xyes" ; then
264 PKG_CHECK_MODULES([EDBUS_UKIT_TEST],
265 [ecore >= 1.2.0 eina >= 1.2.0 dbus-1 >= 0.62],
266 [have_edbus_ukit_test="yes"],
267 [have_edbus_ukit_test="no"])
271 ### Checks for header files
277 ### Checks for structures
280 ### Checks for compiler characteristics
285 EFL_EDBUS_BUILD="-DEFL_EDBUS_BUILD"
288 AC_SUBST(EFL_EDBUS_BUILD)
293 if ! test "x${VMIC}" = "x" ; then
294 EFL_COMPILER_FLAG([-Wall])
295 EFL_COMPILER_FLAG([-W])
298 EFL_COMPILER_FLAG([-Wshadow])
301 ### Checks for linker characteristics
303 lt_enable_auto_import=""
306 lt_enable_auto_import="-Wl,--enable-auto-import"
309 AC_SUBST(lt_enable_auto_import)
312 ### Checks for library functions
317 AC_SUBST(requirement_ebluez)
318 AC_SUBST(requirement_econnman0_7x)
319 AC_SUBST(requirement_edbus)
320 AC_SUBST(requirement_ehal)
321 AC_SUBST(requirement_enotify)
322 AC_SUBST(requirement_eofono)
323 AC_SUBST(requirement_eukit)
324 AC_SUBST(requirement_dbus)
333 src/lib/bluez/Makefile
334 src/lib/connman0_7x/Makefile
335 src/lib/dbus/Makefile
337 src/lib/notification/Makefile
338 src/lib/ofono/Makefile
339 src/lib/ukit/Makefile
351 #####################################################################
357 echo "------------------------------------------------------------------------"
358 echo "$PACKAGE $VERSION"
359 echo "------------------------------------------------------------------------"
361 echo "Configuration Options Summary:"
365 echo " EBluez.............: $enable_ebluez"
366 echo " EConnman (0.7x)....: $enable_econnman0_7x"
367 echo " EHal...............: $enable_ehal"
368 echo " ENotify............: $enable_enotify"
369 echo " EOfono.............: $enable_eofono"
370 echo " EUkit..............: $enable_eukit"
374 echo " EDbus test.........: $have_edbus_test"
375 echo " EDbus client test..: $have_edbus_test_client"
376 echo " EBluez test........: $have_edbus_bluez_test"
377 echo " EConnman (0.7x)test: $have_edbus_connman0_7x_test"
378 echo " ENotify Daemon test: $have_edbus_notification_daemon_test"
379 echo " ENotify send.......: $have_edbus_notify_send"
380 echo " ENotify test.......: $have_edbus_notify_test"
381 echo " EOfono test........: $have_edbus_ofono_test"
382 echo " EUkit test.........: $have_edbus_ukit_test"
384 echo "Documentation..........: ${build_doc}"
386 echo "Compilation............: make (or gmake)"
387 echo " CPPFLAGS.............: $CPPFLAGS"
388 echo " CFLAGS...............: $CFLAGS"
389 echo " LDFLAGS..............: $LDFLAGS"
391 echo "Installation...........: make install (as root if needed, with 'su' or 'sudo')"
392 echo " prefix...............: $prefix"