3 m4_esyscmd([GNOME_TAG_PATTERN=RYGEL build-aux/git-version-gen .tarball-version]),
4 [http://bugzilla.gnome.org/enter_bug.cgi?product=Rygel])
5 AC_CONFIG_AUX_DIR([build-aux])
7 # require automake-1.11 for vala support
8 AM_INIT_AUTOMAKE([1.11])
9 AC_CONFIG_SRCDIR([src/rygel/rygel-root-device.vala])
10 AM_CONFIG_HEADER([config.h])
11 AC_CONFIG_MACRO_DIR([m4])
14 # Disable generation of static libraries
25 GUPNP_AV_REQUIRED=0.5.7
26 GUPNP_VALA_REQUIRED=0.6.7
27 DBUS_GLIB_REQUIRED=0.74
28 GSTREAMER_REQUIRED=0.10.23
29 GST_CONVENIENCE_LIBS_REQUIRED=0.10.0.1
33 LIBSOUP_REQUIRED=2.26.0
35 LIBSQLITE3_REQUIRED=3.5
37 PKG_CHECK_MODULES(LIBGUPNP, gupnp-1.0 >= $GUPNP_REQUIRED)
38 PKG_CHECK_MODULES(LIBGUPNP_AV, gupnp-av-1.0 >= $GUPNP_AV_REQUIRED)
39 PKG_CHECK_MODULES(LIBDBUS_GLIB, dbus-glib-1 >= $DBUS_GLIB_REQUIRED)
40 PKG_CHECK_MODULES(LIBGSTREAMER, gstreamer-0.10 >= $GSTREAMER_REQUIRED)
41 PKG_CHECK_MODULES(GST_CONVENIENCE_LIBS, gstreamer-convenience-libs-0.10 >= $GST_CONVENIENCE_LIBS_REQUIRED)
42 PKG_CHECK_MODULES(LIBGIO, gio-2.0 >= $GIO_REQUIRED)
43 PKG_CHECK_MODULES(GEE, gee-1.0 >= $GEE_REQUIRED)
44 PKG_CHECK_MODULES(UUID, uuid >= $UUID_REQUIRED)
45 PKG_CHECK_MODULES(LIBSOUP, libsoup-2.4 >= $LIBSOUP_REQUIRED)
48 GLIB_GENMARSHAL=`pkg-config --variable=glib_genmarshal glib-2.0`
49 AC_SUBST(GLIB_GENMARSHAL)
52 [ --enable-vala enable checks for vala],,
54 AC_ARG_ENABLE(sql-debugging,
55 [ --enable-sql-debugging enable SQL statement debugging],,
56 enable_sql_debugging=no)
58 if test x$enable_sql_debugging = xyes ; then
59 VALAFLAGS="$VALAFLAGS -D RYGEL_DEBUG_SQL"
62 # Enable check for Vala even if not asked to do so if stamp files are absent.
63 if test ! -e src/rygel/rygel_vala.stamp -o \
64 ! -e src/rygel/librygel_configuration_a_vala.stamp -o \
65 ! -e src/ui/rygel_preferences_vala.stamp -o \
66 ! -e src/plugins/gst-renderer/librygel_gst_renderer_la_vala.stamp -o \
67 ! -e src/plugins/tracker/librygel_media_tracker_la_vala.stamp -o \
68 ! -e src/plugins/test/librygel_test_la_vala.stamp -o \
69 ! -e src/plugins/media-export/librygel_media_export_la_vala.stamp -o \
70 ! -e src/plugins/mediathek/librygel_mediathek_la_vala.stamp -o \
71 ! -e src/plugins/gst-launch/librygel_gst_launch_la_vala.stamp -o \
72 ! -e src/plugins/external/librygel_external_la_vala.stamp ; then
77 if test x$enable_vala = xyes ; then
79 AM_PROG_VALAC([$VALA_REQUIRED])
81 if test "x$VALAC" = "x"; then
82 AC_MSG_ERROR([Cannot find the "valac" compiler in your PATH])
85 PKG_CHECK_MODULES(GUPNP_VALA, gupnp-vala-1.0 >= $GUPNP_VALA_REQUIRED)
86 VAPIDIR=`pkg-config --variable=vapidir vala-1.0`
88 # FIXME: Whats the proper way for checking for particular Vala bindings
89 AC_CHECK_FILE("${VAPIDIR}/gupnp-1.0.vapi",
91 [AC_MSG_ERROR("Unable to find Vala bindings for gupnp-1.0")])
93 AC_CHECK_FILE("${VAPIDIR}/gupnp-av-1.0.vapi",
95 [AC_MSG_ERROR("Unable to find Vala bindings for gupnp-av-1.0")])
97 AC_CHECK_FILE("${VAPIDIR}/dbus-glib-1.vapi",
99 [AC_MSG_ERROR("Unable to find Vala bindings for dbus-glib-1")])
101 AC_CHECK_FILE("${VAPIDIR}/gstreamer-0.10.vapi",
103 [AC_MSG_ERROR("Unable to find Vala bindings for gstreamer-0.10")])
105 AC_CHECK_FILE("${VAPIDIR}/gstreamer-convenience-libs-0.10.vapi",
107 [AC_MSG_ERROR("Unable to find Vala bindings for gstreamer-convenience-libs-0.10")])
109 AC_CHECK_FILE("${VAPIDIR}/gio-2.0.vapi",
111 [AC_MSG_ERROR("Unable to find Vala bindings for gio-2.0")])
113 AC_CHECK_FILE("${VAPIDIR}/gee-1.0.vapi",
115 [AC_MSG_ERROR("Unable to find Vala bindings for gee-1.0")])
117 AC_CHECK_FILE("${VAPIDIR}/sqlite3.vapi",
119 [AC_MSG_ERROR("Unable to find Vala bindings for sqlite3")])
120 AC_CHECK_FILE("${VAPIDIR}/posix.vapi",
122 [AC_MSG_ERROR("Unable to find Vala bindings for POSIX")])
124 VAPIDIR=`echo ${datadir}/vala/vapi`
131 [ --enable-maemo enable maemo support],,
136 [ --enable-debug enable debugging],,
138 if test "x$enable_debug" = "xyes"; then
139 CFLAGS="$CFLAGS -O0 -g"
143 AC_ARG_ENABLE(strict-cc,
144 [ --enable-strict-cc enable strict C compiler],,
146 if test "x$enable_strict_cc" = "xyes"; then
147 CFLAGS="$CFLAGS -Wall -Werror"
153 AC_ARG_ENABLE(uninstalled,
154 [ --enable-uninstalled run uninstalled],,
155 enable_uninstalled=no)
156 if test "x$enable_uninstalled" = "xyes"; then
157 AC_MSG_WARN("You want to run the tools uninstalled only? Fine!")
160 # Check wether user wants to build UIs
162 AC_HELP_STRING([--without-ui],[Do not build UI applications]),
163 try_ui=$withval, try_ui=yes )
166 if test x$try_ui = xyes ; then
168 PKG_CHECK_MODULES(GTK, gtk+-3.0 >= $GTK_REQUIRED ,
172 if test x$enable_vala = xyes ; then
173 AC_CHECK_FILE("${VAPIDIR}/gtk+-3.0.vapi",
179 AC_MSG_ERROR("Unable to find Vala bindings for gtk+-3.0")
187 AC_MSG_WARN([gtk $GTK_REQUIRED or greater not found.])
188 AC_MSG_WARN([UI applications will not be built.])
191 AC_MSG_NOTICE([UI applications disabled.])
194 if test x$HAVE_GTK = xno; then
198 AC_DEFINE(HAVE_GTK, , [Build UI applications])
202 AM_CONDITIONAL(BUILD_UI, test x$BUILD_UI = xyes)
205 AC_ARG_ENABLE(test-plugin,
206 [ --enable-test-plugin build test plugin],,
207 enable_test_plugin=no)
209 # Build Tracker plugin
210 AC_ARG_ENABLE(tracker-plugin,
211 [ --enable-tracker-plugin build tracker plugin],,
212 enable_tracker_plugin=yes)
214 # Build MediaExport plugin
215 AC_ARG_ENABLE(media-export-plugin,
216 [ --enable-media-export-plugin build MediaExport plugin],,
217 enable_media_export_plugin=yes)
219 # Build External plugin
220 AC_ARG_ENABLE(external-plugin,
221 [ --enable-external-plugin build External plugin],,
222 enable_external_plugin=yes)
224 # Build GstRenderer plugin
225 AC_ARG_ENABLE(gst-renderer-plugin,
226 [ --enable-gst-renderer_plugin build Gstreamer Renderer plugin],,
227 enable_gst_renderer_plugin=yes)
229 # Build Mediathek plugin
230 AC_ARG_ENABLE(mediathek-plugin,
231 [ --enable-mediathek-plugin build Mediathek plugin],,
232 enable_mediathek_plugin=no)
234 # Build GstLaunch plugin
235 AC_ARG_ENABLE(gst-launch-plugin,
236 [ --enable-gst-launch-plugin build Gstreamer launchline plugin],,
237 enable_gst_launch_plugin=no)
240 AC_SUBST(abs_top_builddir)
242 AM_CONDITIONAL([UNINSTALLED], [test "x$enable_uninstalled" = "xyes"])
243 AM_CONDITIONAL([ENABLE_MAEMO], [test "x$enable_maemo" = "xyes"])
244 AM_CONDITIONAL([BUILD_TEST_PLUGIN], [test "x$enable_test_plugin" = "xyes"])
245 AM_CONDITIONAL([BUILD_TRACKER_PLUGIN],
246 [test "x$enable_tracker_plugin" = "xyes"])
247 AM_CONDITIONAL([BUILD_MEDIATHEK_PLUGIN], [test "x$enable_mediathek_plugin" = "xyes"])
248 AM_CONDITIONAL([BUILD_MEDIA_EXPORT_PLUGIN], [test "x$enable_media_export_plugin" = "xyes"])
249 AM_CONDITIONAL([BUILD_EXTERNAL_PLUGIN], [test "x$enable_external_plugin" = "xyes"])
250 AM_CONDITIONAL([BUILD_GST_RENDERER_PLUGIN], [test "x$enable_gst_renderer_plugin" = "xyes"])
251 AM_CONDITIONAL([BUILD_GST_LAUNCH_PLUGIN], [test "x$enable_gst_launch_plugin" = "xyes"])
253 if test "x$enable_media_export_plugin" = "xyes";
255 PKG_CHECK_MODULES(LIBSQLITE3, sqlite3 >= $LIBSQLITE3_REQUIRED)
259 GETTEXT_PACKAGE=AC_PACKAGE_NAME
260 AC_SUBST(GETTEXT_PACKAGE)
261 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, ["$GETTEXT_PACKAGE"],
262 [Define the gettext package to be used])
265 IT_PROG_INTLTOOL([0.35.0])
270 AM_SILENT_RULES([yes])
278 src/plugins/media-export/Makefile
279 src/plugins/external/Makefile
280 src/plugins/gst-launch/Makefile
281 src/plugins/mediathek/Makefile
282 src/plugins/tracker/Makefile
283 src/plugins/gst-renderer/Makefile
284 src/plugins/test/Makefile
288 data/icons/256x256/Makefile
289 data/icons/32x32/Makefile
290 data/icons/scalable/Makefile
298 ${PACKAGE} ${VERSION}
303 Source code location: ${srcdir}
306 uninstalled: ${enable_uninstalled}
307 maemo support: ${enable_maemo}
308 preferences ui ${BUILD_UI}
309 SQL debugging: ${enable_sql_debugging}
311 test: ${enable_test_plugin}
312 tracker: ${enable_tracker_plugin}
313 mediathek: ${enable_mediathek_plugin}
314 media-export ${enable_media_export_plugin}
315 external: ${enable_external_plugin}
316 gst-launch: ${enable_gst_launch_plugin}
317 gst-renderer: ${enable_gst_renderer_plugin}