eSpeak NG is an open source speech synthesizer that supports more than hundred languages and accents.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

configure.ac 3.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. AC_PREREQ([2.63])
  2. AC_INIT([eSpeak], [1.46], [https://github.com/rhdunn/espeak/issues], [espeak], [https://github.com/rhdunn/espeak])
  3. AM_INIT_AUTOMAKE()
  4. m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES])
  5. AM_SILENT_RULES([yes])
  6. AC_CONFIG_SRCDIR([src])
  7. AC_CONFIG_MACRO_DIR([m4])
  8. AC_CONFIG_HEADERS([config.h])
  9. dnl ================================================================
  10. dnl Program checks.
  11. dnl ================================================================
  12. AC_PROG_CXX
  13. AC_PROG_MAKE_SET
  14. AC_PROG_LIBTOOL
  15. dnl ================================================================
  16. dnl getopt checks.
  17. dnl ================================================================
  18. AC_CHECK_HEADERS([getopt.h])
  19. AC_CHECK_FUNCS([getopt_long])
  20. dnl ================================================================
  21. dnl PulseAudio checks.
  22. dnl ================================================================
  23. AC_ARG_WITH([pulseaudio],
  24. [AS_HELP_STRING([--with-pulseaudio], [use the pulseaudio library for audio output @<:@default=yes@:>@])],
  25. [])
  26. if test "$with_pulseaudio" = "no"; then
  27. echo "Disabling pulseaudio output support via pulseaudio"
  28. have_pulseaudio=no
  29. else
  30. PKG_CHECK_MODULES(PULSEAUDIO, [libpulse >= 0.9],
  31. [
  32. have_pulseaudio=yes
  33. ],[
  34. have_pulseaudio=no
  35. ])
  36. fi
  37. dnl ================================================================
  38. dnl PortAudio checks.
  39. dnl ================================================================
  40. AC_ARG_WITH([portaudio],
  41. [AS_HELP_STRING([--with-portaudio], [use the portaudio library for audio output @<:@default=yes@:>@])],
  42. [])
  43. if test "$with_portaudio" = "no"; then
  44. echo "Disabling portaudio output support via portaudio"
  45. have_portaudio=no
  46. else
  47. AC_CHECK_HEADERS([portaudio.h],
  48. [
  49. have_portaudio=yes
  50. ],[
  51. have_portaudio=no
  52. ])
  53. fi
  54. dnl ================================================================
  55. dnl Audio checks.
  56. dnl ================================================================
  57. if test "$have_portaudio" = yes ; then
  58. if test "$have_pulseaudio" = yes ; then
  59. PKG_CHECK_MODULES(PULSEAUDIO_SIMPLE, [libpulse-simple >= 0.9],
  60. [
  61. have_pulseaudio=yes
  62. AUDIO=runtime
  63. ],[
  64. have_pulseaudio=no
  65. AUDIO=portaudio
  66. ])
  67. else
  68. AUDIO=portaudio
  69. fi
  70. elif test "$have_pulseaudio" = yes ; then
  71. AUDIO=pulseaudio
  72. else
  73. AUDIO=disabled
  74. fi
  75. AC_SUBST(AUDIO)
  76. AM_CONDITIONAL(AUDIO_RUNTIME, [test x"$AUDIO" = xruntime])
  77. AM_CONDITIONAL(AUDIO_PULSEAUDIO, [test x"$AUDIO" = xpulseaudio])
  78. AM_CONDITIONAL(AUDIO_PORTAUDIO, [test x"$AUDIO" = xportaudio])
  79. AM_CONDITIONAL(AUDIO_PORTAUDIO0, [test x"$AUDIO" = xportaudio0])
  80. AM_CONDITIONAL(AUDIO_PORTAUDIO2, [test x"$AUDIO" = xportaudio2])
  81. AM_CONDITIONAL(AUDIO_SADA, [test x"$AUDIO" = xsada])
  82. dnl ================================================================
  83. dnl wxWidgets checks.
  84. dnl ================================================================
  85. AC_CHECK_PROG(WXCONFIG_CHECK,wx-config,yes)
  86. if test x"$WXCONFIG_CHECK" != x"yes" ; then
  87. AC_MSG_ERROR([Please install wxWidgets which is needed for espeakedit.])
  88. fi
  89. WX_LIBS=`wx-config --libs`
  90. WX_CXXFLAGS=`wx-config --cxxflags`
  91. WX_VERSION=`wx-config --version`
  92. AC_SUBST(WX_LIBS)
  93. AC_SUBST(WX_CXXFLAGS)
  94. dnl ================================================================
  95. dnl Generate output.
  96. dnl ================================================================
  97. AC_CONFIG_FILES([Makefile src/Makefile])
  98. AC_OUTPUT
  99. AC_MSG_NOTICE([
  100. Configuration for eSpeak complete.
  101. Source code location: ${srcdir}
  102. Compiler: ${CXX}
  103. Compiler flags: ${CXXFLAGS}
  104. wxWidgets: ${WX_VERSION}
  105. pulseaudio: ${have_pulseaudio}
  106. portaudio: ${have_portaudio}
  107. audio configuration: ${AUDIO}
  108. ])