2 # micro version (aka day) is 90+ means developers release
3 m4_define([package_major_version], [11])
4 m4_define([package_minor_version], [8])
5 m4_define([package_micro_version], [90])
6 m4_define([package_version], [package_major_version.package_minor_version.package_micro_version])
8 AC_INIT([gmpc],[11.8.90],[qball@gmpclient.org])
11 m4_define([package_tagline], "All hail the Greg")
12 m4_define([package_website], "http://gmpclient.org")
13 m4_define([package_copyright], "Copyright 2003-2012 Qball Cow")
14 m4_define([package_bugtracker], "http://gmpc.wikia.com/wiki/GMPC_HELP")
18 AC_CONFIG_HEADERS([config.h])
19 AC_CONFIG_MACRO_DIR([m4])
20 AM_INIT_AUTOMAKE([subdir-objects])
25 #Make version and variables available in config.h
26 #AC_DEFINE(GMPC_MAJOR_VERSION, package_major_version, ["Major version of gmpc"])
27 #AC_DEFINE(GMPC_MINOR_VERSION, package_minor_version, ["Minor version of gmpc"])
28 #AC_DEFINE(GMPC_MICRO_VERSION, package_micro_version, ["Micro version of gmpc"])
29 # This makes sure the right substitution is done
30 [GMPC_MAJOR_VERSION]=package_major_version
31 [GMPC_MINOR_VERSION]=package_minor_version
32 [GMPC_MICRO_VERSION]=package_micro_version
33 [GMPC_COPYRIGHT]=package_copyright
34 AC_SUBST([GMPC_MAJOR_VERSION])
35 AC_SUBST([GMPC_MINOR_VERSION])
36 AC_SUBST([GMPC_MICRO_VERSION])
37 AC_SUBST([GMPC_COPYRIGHT])
38 AC_DEFINE(GMPC_TAGLINE, package_tagline, ["Gmpc's tagline"])
39 AC_DEFINE(GMPC_WEBSITE, package_website, ["Gmpc's website"])
40 AC_DEFINE(GMPC_BUGTRACKER, package_bugtracker, ["Gmpc's bugtracker"])
41 AC_DEFINE(GMPC_COPYRIGHT, package_copyright, ["Gmpc's Copyright"])
45 # Remove the check for c++ and fortran compiler
47 LT_LANG([Windows Resource])
48 m4_defun([_LT_AC_LANG_CXX_CONFIG], [:])
49 m4_defun([_LT_AC_LANG_F77_CONFIG], [:])
50 AC_REPLACE_FUNCS(strndup)
53 #intltool, libtool. Check for CC compiler
54 IT_PROG_INTLTOOL([0.21])
56 # Check for intltool version, needed for make dist.
57 AM_CONDITIONAL([INTLTOOL_HIGHER_04000], [test ${INTLTOOL_APPLIED_VERSION_AS_INT} -ge 4000])
65 AC_CHECK_LIB([m],[floor])
69 AC_CHECK_LIB(z, inflate,zlib=1,zlib=0)
70 AM_CONDITIONAL(HAVE_ZLIB, test x$zlib = x1)
71 if test "x$zlib" != "x1"
73 AC_MSG_ERROR([GMPC plugin requires zlib])
81 PKG_CHECK_MODULES([libglyr], libglyr)
82 AC_SUBST(libglyr_LIBS)
83 AC_SUBST(libglyr_CFLAGS)
90 AC_ARG_ENABLE([libxspf],
91 [--enable-libxspf Use libxspf.],
92 [case "${enableval}" in
93 yes) enable_libxspf=true;;
94 no) enable_libxspf=false;;
95 *) AC_MSG_ERROR([bad value ${enableval} for --enable-libxspf]);;
97 [enable_libxspf=detect])
98 if test "x$enable_libxspf" = "xdetect"; then
99 PKG_CHECK_MODULES([libxspf], xspf, enable_libxspf=true, enable_libxspf=false)
101 if test "x$enable_libxspf" = "xtrue"; then
102 PKG_CHECK_MODULES([libxspf], xspf)
103 AC_SUBST(libxspf_LIBS)
104 AC_SUBST(libxspf_CFLAGS)
106 AC_DEFINE([XSPF], 1, [Use xspf])
109 AC_ARG_ENABLE(libspiff,
110 [ --enable-libspiff Use libspiff to parse spiff playlists.],
111 [ case "${enableval}" in
112 yes) enable_libspiff=yes;;
113 no) enable_libspiff=no;;
114 *) AC_MSG_ERROR([bad value ${enableval} for --enable-libspiff]);;
116 [enable_libspiff=auto])
118 if test "x${enable_libspiff}" != xno; then
119 AC_CHECK_HEADER(spiff/spiff_c.h, AC_CHECK_LIB(spiff, spiff_parse,libspiff=1,libspiff=0),libspiff=0)
120 if test "x${libspiff}" = "x1";
122 AC_DEFINE(SPIFF,1,["Use or don't use libspiff"])
126 if test "x${enable_libspiff}" = "xyes"; then
127 AC_MSG_ERROR([libspiff not found])
134 # Check for libnotify
136 AC_ARG_ENABLE(libnotify,
137 [ --enable-libnotify Use libnotify for user notifications.],
138 [ case "${enableval}" in
139 yes) enable_libnotify=yes;;
140 no) enable_libnotify=no;;
141 *) AC_MSG_ERROR([bad value ${enableval} for --enable-libnotify]);;
143 [enable_libnotify=auto])
145 if test "x${enable_libnotify}" != xno; then
146 PKG_CHECK_MODULES([libnotify], libnotify, enable_libnotify=true, enable_libnotify=false)
148 if test "x$enable_libnotify" = "xtrue"; then
149 PKG_CHECK_MODULES([libnotify], libnotify)
150 AC_SUBST(libnotify_LIBS)
151 AC_SUBST(libnotify_CFLAGS)
152 AC_DEFINE([HAVE_LIBNOTIFY], 1, [Use notify])
155 # Checks for header files.
157 AC_CHECK_HEADERS([stdlib.h string.h unistd.h])
159 # Checks for typedefs, structures, and compiler characteristics.
162 # Checks for libraries.
163 AC_SUBST(GLIB_REQUIRED)
164 AC_SUBST(GTK_REQUIRED)
172 AC_ARG_ENABLE([timing],
173 [--enable-timing Print timing debug output.],
174 [case "${enableval}" in
175 yes) enable_timing=true;;
176 no) enable_timing=false;;
177 *) AC_MSG_ERROR([bad value ${enableval} for --enable-timing]);;
179 [enable_timing=false])
181 if test x${enable_timing} = xtrue; then
182 # Add DEBUG_ENABLE define to config.h
183 AC_DEFINE(DEBUG_TIMING, 1, [Enable timing output])
187 AC_ARG_ENABLE([test],
188 [--enable-test Enable tests],
189 [case "${enableval}" in
190 yes) test_mode=true;;
191 no) test_mode=false;;
192 *) AC_MSG_ERROR([bad value ${enableval} for --enable-test]);;
196 AM_CONDITIONAL([ENABLE_TEST], [test x$test_mode = xtrue])
199 AC_ARG_WITH([extra-version],
200 [--with-extra-version=revision Specify extra version.],
201 with_extra_version=${withval})
202 if test x"${with_extra_version}" != x; then
203 AM_CONDITIONAL([EXTRA_VERSION], [true])
204 EXTRA_VERSION="${with_extra_version}";
205 AC_SUBST(EXTRA_VERSION)
207 AM_CONDITIONAL([EXTRA_VERSION], [false])
212 # Split this out, because pkgconfig macro doesn't return nicely what is missing
215 PKG_CHECK_MODULES([glib], glib-2.0 >= 2.16)
217 AC_SUBST(glib_CFLAGS)
220 PKG_CHECK_MODULES([gobject], gobject-2.0 >= 2.4)
221 AC_SUBST(gobject_LIBS)
222 AC_SUBST(gobject_CFLAGS)
225 PKG_CHECK_MODULES([gtk], gtk+-3.0 >= 3.0)
230 PKG_CHECK_MODULES([gmodule], gmodule-2.0 >= 2.4)
231 AC_SUBST(gmodule_LIBS)
232 AC_SUBST(gmodule_CFLAGS)
235 PKG_CHECK_MODULES([libmpd], libmpd >= 11.8.90)
236 AC_SUBST(libmpd_LIBS)
237 AC_SUBST(libmpd_CFLAGS)
241 PKG_CHECK_MODULES([gthread], gthread-2.0)
242 AC_SUBST(gthread_LIBS)
243 AC_SUBST(gthread_CFLAGS)
246 PKG_CHECK_MODULES([libsoup], libsoup-2.4)
247 AC_SUBST(libsoup_LIBS)
248 AC_SUBST(libsoup_CFLAGS)
251 PKG_CHECK_MODULES([libgio], gio-2.0)
252 AC_SUBST(libgio_LIBS)
253 AC_SUBST(libgio_CFLAGS)
257 PKG_CHECK_MODULES([sqlite3], sqlite3)
258 AC_SUBST(sqlite3_LIBS)
259 AC_SUBST(sqlite3_CFLAGS)
263 PKG_CHECK_MODULES([libxml2], libxml-2.0)
264 AC_SUBST(libxml2_LIBS)
265 AC_SUBST(libxml2_CFLAGS)
269 AC_MSG_CHECKING(prefix)
271 if test "x${prefix}" = "xNONE"; then
272 PACKAGE_PREFIX="${ac_default_prefix}"
274 PACKAGE_PREFIX="${prefix}"
276 AC_MSG_RESULT($PACKAGE_PREFIX)
279 dnl please keep them in alphabetical order
280 ALL_LINGUAS="ar bg bn bs ca cs da de el et en_CA en_GB es fi fr gl he hi hu hy id it ja jv lv ml ms nb ne nl oc pl pt pt_BR ro ru sq sv th tr zh_CN zh_TW"
285 AC_SUBST(GETTEXT_PACKAGE)
286 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",[GMPC gettext package])
288 if test x$gt_cv_have_gettext != "xyes"; then
290 echo "Translations support is required."
294 #AM_GNU_GETTEXT([external])
295 # setting correct paths
296 PACKAGE_LOCALE_DIR="${PACKAGE_PREFIX}/${DATADIRNAME}/locale"
297 AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR,"$PACKAGE_LOCALE_DIR",[The package's locale path for gettext])
300 AC_SUBST(PACKAGE_LOCALE_DIR)
301 AC_SUBST(PACKAGE_LIBS)
305 #Win32 compile support
311 EXTRA_CFLAGS="-Wmissing-prototypes -Wmissing-declarations"
318 *-*-mingw32* | *-*-windows)
320 EXTRA_CFLAGS="$EXTRA_CFLAGS -mwindows -mms-bitfields"
321 EXTRA_LDFLAGS="-export-all-symbols -mwindows -mms-bitfields" ;;
324 EXTRA_LDFLAGS="-export-all-symbols -mms-bitfields" ;;
326 EXTRA_LDFLAGS="-framework Carbon"
329 AM_CONDITIONAL(WIN32, test x$win32 = xyes)
330 AM_CONDITIONAL(OSX, test x$macosx = xyes)
332 AM_CONDITIONAL(PLATFORM_WIN32, test x$win32 = xyes)
333 AM_CONDITIONAL(PLATFORM_OSX, test x$macosx = xyes)
336 # These depend on if we are or are not on windows or osX
338 if test x$macosx = xno && test x$win32 = xno ; then
340 AC_ARG_ENABLE([mmkeys],
341 [ --disable-mmkeys Disable multimedia keys support.],
342 [ case "${enableval}" in
343 yes) enable_mmkeys=yes;;
344 no) enable_mmkeys=no;;
345 *) AC_MSG_ERROR([bad value ${enableval} for --disable--mmkeys]);;
348 if test x${enable_mmkeys} = xyes; then
350 PKG_CHECK_MODULES([libx11], [x11 gdk-x11-3.0 gtk+-x11-3.0])
351 AC_SUBST(libx11_LIBS)
352 AC_SUBST(libx11_CFLAGS)
354 AC_DEFINE(ENABLE_MMKEYS, 1, [Enable multimedia support])
361 AC_SUBST(EXTRA_CFLAGS)
362 AC_SUBST(EXTRA_LDFLAGS)
366 # Make the gob2 check fatal
367 if test x${GOB2} = x""; then
371 AM_PROG_VALAC([0.14.0])
373 if test x${VALAC} = x""; then
377 APPINDICATOR_REQUIRED=0.3
379 AC_ARG_ENABLE(appindicator,
380 AS_HELP_STRING([--enable-appindicator[=@<:@no/auto/yes@:>@]],[Build support for application indicators ]),
381 [enable_appindicator=$enableval],
382 [enable_appindicator="no"])
384 if test x$enable_appindicator = xauto ; then
385 PKG_CHECK_EXISTS([appindicator3-0.1 >= $APPINDICATOR_REQUIRED],
386 enable_appindicator="yes",
387 enable_appindicator="no")
390 if test x$enable_appindicator = xyes ; then
391 PKG_CHECK_EXISTS([appindicator3-0.1 >= $APPINDICATOR_REQUIRED],,
392 AC_MSG_ERROR([appindicator3-0.1 is not installed]))
393 PKG_CHECK_MODULES(APP_INDICATOR,
394 appindicator3-0.1 >= $APPINDICATOR_REQUIRED)
395 AC_SUBST(APP_INDICATOR_CFLAGS)
396 AC_SUBST(APP_INDICATOR_LIBS)
397 AC_DEFINE(HAVE_APP_INDICATOR, 1, [Have AppIndicator])
399 AM_CONDITIONAL(HAVE_APP_INDICATOR, test x"$enable_appindicator" = xyes)
401 AC_ARG_ENABLE([shave],
402 [ --disable-shave Use shave output cleaner when building.],
403 [ case "${enableval}" in
404 yes) enable_shave=yes;;
405 no) enable_shave=no;;
406 *) AC_MSG_ERROR([bad value ${enableval} for --disable-shave]);;
409 if test x$enable_shave = xyes; then
413 GNOME_DOC_INIT([0.18.0], [have_gdu=yes], [have_gdu=no])
430 pixmaps/icons/Makefile
431 pixmaps/icons/hicolor/Makefile
432 pixmaps/icons/hicolor/16x16/Makefile
433 pixmaps/icons/hicolor/16x16/actions/Makefile
434 pixmaps/icons/hicolor/16x16/status/Makefile
435 pixmaps/icons/hicolor/16x16/apps/Makefile
436 pixmaps/icons/hicolor/22x22/Makefile
437 pixmaps/icons/hicolor/22x22/actions/Makefile
438 pixmaps/icons/hicolor/22x22/status/Makefile
439 pixmaps/icons/hicolor/22x22/apps/Makefile
440 pixmaps/icons/hicolor/32x32/Makefile
441 pixmaps/icons/hicolor/32x32/actions/Makefile
442 pixmaps/icons/hicolor/32x32/status/Makefile
443 pixmaps/icons/hicolor/32x32/apps/Makefile
444 pixmaps/icons/hicolor/48x48/Makefile
445 pixmaps/icons/hicolor/48x48/actions/Makefile
446 pixmaps/icons/hicolor/48x48/apps/Makefile
447 pixmaps/icons/hicolor/48x48/status/Makefile
448 pixmaps/icons/hicolor/64x64/Makefile
449 pixmaps/icons/hicolor/64x64/apps/Makefile
450 pixmaps/icons/hicolor/64x64/status/Makefile
451 pixmaps/icons/hicolor/72x72/Makefile
452 pixmaps/icons/hicolor/72x72/apps/Makefile
453 pixmaps/icons/hicolor/72x72/status/Makefile
454 pixmaps/icons/hicolor/96x96/Makefile
455 pixmaps/icons/hicolor/96x96/apps/Makefile
456 pixmaps/icons/hicolor/96x96/status/Makefile
457 pixmaps/icons/hicolor/128x128/Makefile
458 pixmaps/icons/hicolor/128x128/apps/Makefile
459 pixmaps/icons/hicolor/128x128/status/Makefile
460 pixmaps/icons/hicolor/128x128/categories/Makefile
461 pixmaps/icons/hicolor/scalable/Makefile
462 pixmaps/icons/hicolor/scalable/actions/Makefile
463 pixmaps/icons/hicolor/scalable/status/Makefile
464 pixmaps/icons/hicolor/scalable/apps/Makefile
465 pixmaps/icons/hicolor/scalable/categories/Makefile
466 pixmaps/icons/Humanity/16x16/Makefile
467 pixmaps/icons/Humanity/16x16/actions/Makefile
468 pixmaps/icons/Humanity/16x16/status/Makefile
469 pixmaps/icons/Humanity/16x16/apps/Makefile
470 pixmaps/icons/Humanity/22x22/Makefile
471 pixmaps/icons/Humanity/22x22/actions/Makefile
472 pixmaps/icons/Humanity/22x22/status/Makefile
473 pixmaps/icons/Humanity/22x22/apps/Makefile
474 pixmaps/icons/Humanity/24x24/Makefile
475 pixmaps/icons/Humanity/24x24/actions/Makefile
476 pixmaps/icons/Humanity/24x24/status/Makefile
477 pixmaps/icons/Humanity/24x24/categories/Makefile
478 pixmaps/icons/Humanity/24x24/apps/Makefile
479 pixmaps/icons/Humanity/32x32/Makefile
480 pixmaps/icons/Humanity/32x32/actions/Makefile
481 pixmaps/icons/Humanity/32x32/status/Makefile
482 pixmaps/icons/Humanity/32x32/apps/Makefile
483 pixmaps/icons/Humanity/48x48/Makefile
484 pixmaps/icons/Humanity/48x48/actions/Makefile
485 pixmaps/icons/Humanity/48x48/apps/Makefile
486 pixmaps/icons/Humanity/48x48/status/Makefile
487 pixmaps/icons/Humanity/64x64/Makefile
488 pixmaps/icons/Humanity/64x64/apps/Makefile
489 pixmaps/icons/Humanity/64x64/status/Makefile
490 pixmaps/icons/Humanity/64x64/actions/Makefile
491 pixmaps/icons/Humanity/72x72/Makefile
492 pixmaps/icons/Humanity/72x72/apps/Makefile
493 pixmaps/icons/Humanity/72x72/status/Makefile
494 pixmaps/icons/Humanity/72x72/actions/Makefile
495 pixmaps/icons/Humanity/96x96/Makefile
496 pixmaps/icons/Humanity/96x96/apps/Makefile
497 pixmaps/icons/Humanity/96x96/status/Makefile
498 pixmaps/icons/Humanity/96x96/actions/Makefile
499 pixmaps/icons/Humanity/128x128/Makefile
500 pixmaps/icons/Humanity/128x128/apps/Makefile
501 pixmaps/icons/Humanity/128x128/status/Makefile
502 pixmaps/icons/Humanity/128x128/categories/Makefile
503 pixmaps/icons/Humanity/128x128/actions/Makefile
504 pixmaps/icons/Humanity/Makefile
505 pixmaps/icons/Humanity/scalable/Makefile
506 pixmaps/icons/Humanity/scalable/actions/Makefile
507 pixmaps/icons/Humanity/scalable/status/Makefile
508 pixmaps/icons/Humanity/scalable/apps/Makefile
509 pixmaps/icons/Humanity/scalable/categories/Makefile
512 test/MpdDataModel/Makefile
513 test/GmpcEasyDownload/Makefile
514 test/MetaDataCache/Makefile
515 test/PixbufCache/Makefile
516 test/AsyncImage/Makefile
518 test/DiscoGS/Makefile
524 echo "------------------ Status ------------------"
525 if test x$enable_timing = xtrue; then
526 echo "Debug timing output is: enabled"
528 echo "Debug timing output is: disabled"
530 if test x${enable_mmkeys} = xyes; then
531 echo "Multimedia keys support is: enabled"
533 echo "Multimedia keys support is: disabled"
535 if test x"$enable_appindicator" = xyes; then
536 echo "AppIndicator Support is: enabled"
538 echo "AppIndicator Support is: disabled"
540 if test "x$libspiff" = "x1"; then
541 echo "Use libspiff library: enabled"
543 echo "Use libspiff library: disabled"
545 if test "x$libxspf" = "x1"; then
546 echo "Use libxspf library: enabled"
548 echo "Use libxspf library: disabled"
550 if test "x$have_gdu" = "xyes"; then
551 echo "Use Gnome Documentation: enabled"
553 echo "Use Gnome Documentation: disabled"
555 if test x${enable_libnotify} = xtrue; then
556 echo "Use libnotify: enabled"
558 echo "Use libnotify: disabled"
561 echo "Now type make to build"
562 if test x$enable_shave = xyes; then
563 echo "Building is done with reduced output. (shave";
564 echo "use --disable-shave to get all (old) output back";