-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to build and install on macOS? #37
Comments
I wasn't able to figure out how to build on macOS, but I instead found a way to build it in a debian docker image and play the audio using pulseaudio over the local network to my mac host. @hgneng, would you like me to create a PR with the Dockerfile and instructions? We could also publish the image on dockerhub for an easy cross-platform install. |
I have never built Ekho on Mac. Ekho use pulseaudio to run but pulseaudio is not running on Mac. I am not familiar with PR or Docker. If you think others will benefit from your work, go ahead. I will put your work on Ekho's page. Thank you! |
I tried building on macOS with libpulseaudio and libsndfile installed but I kept getting errors, so I gave up. PR means Pull Request. I have a Pull Request coming soon to be able to run ekho on macOS and Windows through a docker container. Docker is software that allows running containers through OS-level virtualization. You can think of a container as a lightweight VM. I got Linux:
Although macOS or Windows (PowerShell/WSL):
|
I have fixed build issues on MacOS. Please try following version: Thank you for opening this issue. I have never thought that Ekho can port to MacOS easily. You need to launch pulseaudio deamon first. In my environment, pulseaudio installed from HomeBrew is not able to launch. But I can run it by At least, you can out wave to a file with |
Hey @hgneng, thanks for the fix. I got it built and installed with macOS-provided You can start I wasn't able to get So here are my steps to get it working: $ brew install pulseaudio libsndfile
$ brew install llvm # optional if you want to build with homebrew clang
$ # Have to install libespeak-ng manually because it's not provided by homebrew.
$ # I built and installed espeak-ng by following instructions here
$ # https://github.com/espeak-ng/espeak-ng/blob/master/docs/building.md#linux-mac-bsd
$ cd espeak-ng
$ brew install libtool
$ # need to do this because `m4` has symlinks to /usr/share/aclocal
$ # whereas mac has it at /usr/local/share/aclocal, probably due to homebrew.
$ glibtoolize -c
$ ./autogen.sh
$ ./configure # default installed at /usr/local with --prefix=/usr/local
$ make
$ make install
$ espeak-ng # test this command to make sure no errors.
$ cd ekho-8.5
$ ./configure # this uses macOS clang
$ # alternatively use homebrew clang
$ ./configure CC=/usr/local/opt/llvm/bin/clang LDFLAGS=-L/usr/local/lib CPPFLAGS=-I/usr/local/include'CXX=/usr/local/opt/llvm/bin/clang++
$ make
$ make install
$ brew services restart pulseaudio # this ensures pulseaudio daemon is started
$ ekho 123 # should work now |
Thank you for the detail procedures. I have trouble with start pulseaudio service in brew. I think it's an issue of my Homebrew environment.
|
No problem. Hmm, those errors are within the homebrew ruby code. I wonder how that happened. I found these issues: They say to update or reinstall homebrew. |
@hgneng, you mentioned that your Here is the homebrew plist. plists are daemon configuration files for macOS launchd service. Here it is evaluated on my mac:
Notice the Perhaps |
Thank you! After running Running |
You're welcome! That's good that you got it working. I guess we can close this issue now that we have ekho working for macOS? |
@hgneng, I saw your blog post about building espeak-ng on macOS. I saw you mentioned there was no sound for the You typed: espeak-ng 'hello' # no sound
espeak-ng 'hello' -w demo.wav && play demo.wav # works There are actually a few ways to fix that instead of outputting to a First things first, Option 1 play from stdin: brew install sox
espeak-ng hello | play - If you want sound from pcaudiolib also isn't provided by The espeak-ng Option 2 Here is a quick guide for a fuller espeak-ng install on macOS: # https://github.com/espeak-ng/pcaudiolib#mac-os
cd pcaudiolib
./autogen.sh
./configure
make
make install
# Use https://github.com/waywardgeek/sonic instead of out-of-date https://github.com/espeak-ng/sonic
cd sonic
brew install fftw
make
make install PREFIX=/usr/local
cd espeak-ng
glibtoolize -c
./configure --with-extdict-zh --with-extdict-zhy
make
make install
# test audio:
espeak-ng -vyue '冚挷攔' |
Hello everyone:
Athoug I'm a programmer , but I'm not your workmater. That's a wrong email for me, Please check it !
[email protected]
From: Kevin Lau
Date: 2020-12-25 06:36
To: hgneng/ekho
CC: Subscribed
Subject: Re: [hgneng/ekho] How to build and install on macOS? (#37)
@hgneng, I saw your blog post about building espeak-ng on mac.
I saw you mentioned there was no sound for the espeak-ng CLI.
You typed:
espeak-ng 'hello' # no sound
espeak-ng 'hello' -w demo.wav && play demo.wav # works
There are actually a few ways to fix that instead of outputting to a .wav file.
First things first, play isn't included in macOS by default, you have to brew install sox
Option 1 play from stdin:
brew install sox
espeak-ng hello | play -
If you want sound from espeak-ng directly, you need to install pcaudiolib.
See:
https://github.com/espeak-ng/espeak-ng/blob/master/docs/guide.md#problems-with-pcaudiolib
https://github.com/espeak-ng/espeak-ng/blob/master/docs/building.md#linux-mac-bsd
pcaudiolib also isn't provided by brew so need to be built and installed manually. The guides list a bunch of other optional dependencies you can install such as sonic to speed up audio. If you install sonic, make sure to install from the source and not the espeak-ng fork, because it is out of date.
The espeak-ng ./configure command will tell you if you have dependencies installed correctly.
Here is a quick guide for a fuller espeak-ng install on macOS:
# https://github.com/espeak-ng/pcaudiolib#mac-os
cd pcaudiolib
./autogen.sh
./configure
make
make install
# Use https://github.com/waywardgeek/sonic instead of out-of-date https://github.com/espeak-ng/sonic
cd sonic
brew install fftw
make
make install PREFIX=/usr/local
cd espeak-ng
glibtoolize -c
./configure --with-extdict-zh --with-extdict-zhy
make
make install
# test audio:
espeak-ng -vyue '我'
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
@zhangtengyuan, I'm not sure what you are talking about. You might have subscribed to this issue accidentally. Click "Unsubscribe" on the top-right to unsubscribe from emails. |
@dosentmatter, Thank you for the details about espeak-ng. The original link of sonic and config command for extra dictionary is valuable to me. |
I am on macOS Mojave 10.14.6.
I looked at macOS install instructions in INSTALL. I can't get past the
./configure
ormake
steps. Do you have any suggestions? I'm not sure what version ofgcc
is required. I'm interested in trying out the toisanese TTS.Setup:
Configure:
I tried the following without success.
The text was updated successfully, but these errors were encountered: