1 dnl Process this file with autoconf to produce a configure script.
3 # get rid of that stupid cache mechanism
7 AM_INIT_AUTOMAKE(emotion, 0.0.1.004)
8 AM_CONFIG_HEADER(config.h)
19 if test "x${bindir}" = 'x${exec_prefix}/bin'; then
20 if test "x${exec_prefix}" = "xNONE"; then
21 if test "x${prefix}" = "xNONE"; then
22 bindir="${ac_default_prefix}/bin";
24 bindir="${prefix}/bin";
27 if test "x${prefix}" = "xNONE"; then
28 bindir="${ac_default_prefix}/bin";
30 bindir="${prefix}/bin";
35 if test "x${libdir}" = 'x${exec_prefix}/lib'; then
36 if test "x${exec_prefix}" = "xNONE"; then
37 if test "x${prefix}" = "xNONE"; then
38 libdir="${ac_default_prefix}/lib";
40 libdir="${prefix}/lib";
43 if test "x${prefix}" = "xNONE"; then
44 libdir="${ac_default_prefix}/lib";
46 libdir="${prefix}/lib";
51 dnl Set PACKAGE_DATA_DIR in config.h.
52 if test "x${prefix}" = "xNONE"; then
53 AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${ac_default_prefix}/share/${PACKAGE}", [Shared Data Directory])
55 AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${prefix}/share/${PACKAGE}", [Shared Data Directory])
58 dnl Set PACKAGE_BIN_DIR in config.h.
59 if test "x${bindir}" = 'xNONE'; then
60 if test "x${prefix}" = "xNONE"; then
61 AC_DEFINE_UNQUOTED(PACKAGE_BIN_DIR, "${ac_default_prefix}/bin", [Install Location for Executables])
63 AC_DEFINE_UNQUOTED(PACKAGE_BIN_DIR, "${prefix}/bin", [Install Location for Executables])
66 AC_DEFINE_UNQUOTED(PACKAGE_BIN_DIR, "${bindir}", [Install Location for Executables])
69 dnl Set PACKAGE_LIB_DIR in config.h.
70 if test "x${libdir}" = 'xNONE'; then
71 if test "x${prefix}" = "xNONE"; then
72 AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${ac_default_prefix}/lib", [Install Location for Libraries])
74 AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${prefix}/lib", [Install Location for Libraries])
77 AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${libdir}", [Install Location for Libraries])
80 dnl Set PACKAGE_SOURCE_DIR in config.h.
81 packagesrcdir=`cd $srcdir && pwd`
82 AC_DEFINE_UNQUOTED(PACKAGE_SOURCE_DIR, "${packagesrcdir}", [Source Directory])
84 PKG_CHECK_MODULES(EET, [eet >= 0.9.10])
85 PKG_CHECK_MODULES(EVAS, [evas >= 0.9.9])
86 PKG_CHECK_MODULES(EDJE, [edje >= 0.5.0])
87 PKG_CHECK_MODULES(ECORE, [ecore >= 0.9.9 ecore-evas >= 0.9.9])
88 PKG_CHECK_MODULES(EMBRYO, [embryo >= 0.9.1])
90 save_CPPFLAGS=$CPPFLAGS
91 CPPFLAGS="$CPPFLAGS $ECORE_CFLAGS"
92 AC_CHECK_HEADERS(Ecore_X.h Ecore_Fb.h)
93 CPPFLAGS=$save_CPPFLAGS
96 AC_HELP_STRING([--disable-xine],[disable xine support @<:@default=auto@:>@]),
97 [enable_xine=$enableval],[enable_xine=auto])
99 if test "$enable_xine" != "no" ; then
100 PKG_CHECK_MODULES(XINE, [libxine >= 1.1.1], [HAVE_XINE="yes"])
102 if test "$enable_xine$HAVE_XINE" = "yesno" ; then
103 AC_MSG_RESULT(xine not found)
106 AC_ARG_ENABLE(gstreamer,
107 AC_HELP_STRING([--disable-gstreamer],[disable gstreamer support @<:@default=auto@:>@]),
108 [enable_gstreamer=$enableval],[enable_gstreamer=auto])
111 if test "$enable_gstreamer" != "no" ; then
113 dnl Gstreamer version requirement
118 PKG_CHECK_MODULES(GST, \
119 gstreamer-$GST_MAJORMINOR >= $GST_REQS,
120 HAVE_GSTREAMER="yes", AC_MSG_RESULT(no)
123 PKG_CHECK_MODULES(GSTPLUG, \
124 gstreamer-plugins-base-$GST_MAJORMINOR >= $GSTPLUG_REQS,
125 HAVE_GSTPLUG="yes", AC_MSG_RESULT(no)
128 AM_GST_ELEMENT_CHECK(
130 [HAVE_GSTFFMPEG="yes"],
131 [HAVE_GSTFFMPEG="no"])
133 AM_GST_ELEMENT_CHECK(
135 [HAVE_GSTCDIOCDDASRC="yes"],
136 [HAVE_GSTCDIOCDDASRC="no"])
138 if test "$enable_gstreamer$HAVE_GSTREAMER" = "yesno" ; then
139 AC_MSG_RESULT(gstreamer not found)
141 if test "$HAVE_GSTPLUG" = "no"; then
142 if test "$HAVE_GSTREAMER" = "no" ; then
145 AC_MSG_WARN([You should install gstreamer plugins and gst-ffmpeg to properly decode your video and audio files])
146 GSTPLUG_MSG="no (you should install gst-plugins-base and gst-ffmpeg)"
149 if test "$HAVE_GSTFFMPEG" = "no"; then
150 if test "$HAVE_GSTREAMER" = "no" ; then
153 AC_MSG_WARN([You should install gstreamer plugins and gst-ffmpeg to properly decode your video and audio files])
154 GSTPLUG_MSG="no (you should install gst-plugins-base and gst-ffmpeg)"
160 if test "$HAVE_GSTCDIOCDDASRC" = "no"; then
161 AC_MSG_WARN([You should install gstreamer-plugins-good and make sure that the cdiocddasrc element is installed])
162 GSTCDDA_MSG="no (you should install gst-plugins-good and the cdiocddasrc element)"
167 if test "$HAVE_XINE$HAVE_GSTREAMER" = "nono" ; then
168 AC_MSG_ERROR([Xine or Gstreamer must be installed to build emotion])
171 AM_CONDITIONAL([BUILD_XINE_MODULE], [test "$HAVE_XINE" = yes])
172 AM_CONDITIONAL([BUILD_GSTREAMER_MODULE], [test "$HAVE_GSTREAMER" = yes])
174 AC_CHECK_LIB(dl, dlopen, dlopen_libs=-ldl)
175 AC_SUBST(dlopen_libs)
189 chmod +x emotion-config
193 #####################################################################
199 echo "------------------------------------------------------------------------"
200 echo "$PACKAGE $VERSION"
201 echo "------------------------------------------------------------------------"
203 echo "Configuration Options Summary:"
206 echo " Xine...............: $HAVE_XINE"
207 echo " Gstreamer..........: $HAVE_GSTREAMER"
208 echo " Gstreamer plugins..: $GSTPLUG_MSG"
209 echo " Gstreamer FFmpeg...: $HAVE_GSTFFMPEG"
210 echo " Gstreamer CDDA.....: $GSTCDDA_MSG"
212 echo " Compilation..........: make"
214 echo " Installation.........: make install"
216 echo " prefix.........: $prefix"
217 echo " binaries.......: $bindir"
218 echo " libraries......: $libdir"
219 echo " headers........: $includedir"