Skip to content

BoniLindsley/espeak-ng-cmake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 

Repository files navigation

eSpeak NG - CMake script

A CMake script to build eSpeak NG targetting the MSYS2 MinGW64 subsystem.

Build instructions

Building eSpeak NG using this CMake script can be done as follows, roughly:

  • Start MSYS2 MinGW64 with GCC, SDL2 and CMake installed.
  • Compile in debug build from source and install (into the same install root) each of the following libraries (before compiling the next):

Known issues:

  • Packaging eSpeak NG requires copying espeak-ng-data and SDL2.dll to the same directory as the binary.
  • There are stutters in audio output, probably due to buffering issues.
  • Extra build options enabling Klatt, MBROLA support, SONIC and asynchronous commands produce unusable binaries.
    • Disabling pcaudiolib seems to be fine.

Purpose

Windows support in eSpeak NG is given by providing a Visual Studio solution. This is not usable for targetting MSYS2 MinGW64. It might be possible to tweak Autotools to make it work (but I have little experience in using it).

A bigger issue is that building eSpeak NG with audio output uses the Portable C Audio Library. (I was not able to make it behave as expected without audio output. It compiles, but it gets stuck in an infinite loop.) The library in turn depends on XAudio2 in Windows. This cannot be easily made to target MSYS2 MinGW64. Alternative dependencies include ALSA, OSS and PulseAudio, but none of them are available in MSYS2 MinGW64 at the time of writing.

The solution chosen is to replace XAudio2 by FAudio -- an open-source reimplmentation of XAudio2 that depends only on SDL2 -- that uses CMake for its build by default and has a binary package provided in the default MSYS2 package repository. The Portable C Audio Library is made to link to FAudio by slightly its source and adding CMake support to it. The CMake build script in this repository adds CMake support for eSpeak NG as well, and to use the modified pcaudiolib library.

About

A CMake script to build eSpeak NG targetting the MSYS2 MinGW64 subsystem.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages