-
Notifications
You must be signed in to change notification settings - Fork 77
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
Building for MacOS and iOS #14
Comments
I was curious about it too and saw #13, which motivated me to try and get it running. The following worked on my machine (Intel, Ventura, macports):
|
Thanks @nickolay for posting that you got it working and the steps you had to take I had prior to your post made further attempts but given up. Can you clarify a few points ? 1.The test binary mentioned in second step is the one you built in first step I presume and which resides in the folder you did the build eg downloads. 2.are the exports commands in step 2 exactly what I would need to run , or is there any alteration I need to make depending where I built the piper-phonemize
Thankyou |
Hey @williamcorney, I tested this specific sequence of commands from scratch before posting, but I can't guarantee it will work for everyone. (In addition to than what I have already mentioned, I was using Re your first point: I cloned this repository to a local folder named Yes, the Re your 2nd and 3rd questions: you should be able to re-use the commands with no modifications. You're right about the meaning of
Re 4th question: the step 3 continues the commands from steps 1 and 2, so is executed inside the same git checkout (named If you have trouble with the multiline-heredoc |
Thankyou @nickolay :) Great work I have been able to get through all the steps and replicate your success. Notes from my own experience
I wasn't familiar with the patch function you used to patch the setup.py file so confused at first. Handy little feature thanks for introducing me to that. |
Thank you @nickolay and @williamcorney. Following your responses I was able to build and install it on my M1 MacBook. |
Thank you @nickolay , your steps worked perfectly. |
another step I found to be necessary after reinstalling recently Error Cause Solution The solution to this issue is to run the following script (copied from Install Certificates.command) after brew install python3. I havent pasted here to not spam this post but you can see the full post here. |
I have created wheels for python 3.10 and 3.12 which makes this work much smoother now :) It was a sharp learning curve to understand what needed to be done as barely understood what a wheel was before let alone how to make one lol download and extract the whl file and install by running the command pip3 install -f /REPLACE/WITH/PATH/WHERE/YOU/DOWNLOADED/WHEEL/FILE piper-phonemize piper_phonemize-1.1.0-cp310-cp310-macosx_13_0_x86_64.whl.zip These of course are intended for Intel based Mac. |
Can these wheels be added to pypi for macos ? I haven't done before so not sure the process Thank you |
I've uploaded the wheels above to PyPI 👍 |
Thanks alot @nickolay & @williamcorney 💆🏼♂️ my head aches from trying to install this for weeks, but this fixed it. I don't know why espeak-ng is not available for mac or on brew and I honestly don't understand why some great py libraries installation process on mac is just horrific, it's like mac is an afterthought for some devs 😂 |
Can someone point me to the right direction of how to make this work on an ARM Mac please? |
Building piper-phonemize from source
Creating a wheelThese are optional but recommended steps.
|
Thank you so much for the detailed instruction, I finally got it working! A few things to note hope it helps others:
3, I'm attaching my wheel file here, don't know why it says osx11, I'm on 14.5. |
I'm glad you got it sorted and good to know same steps works for arm64 too. Great job :). Good to see the wheel there too. |
The solution given by @williamcorney does not work for me (macOS 14.6.1, Apple M1 Pro chip, Python 3.11.9, ZSH shell). First, I had to update .PHONY: all clean
all:
cmake -Bbuild -DCMAKE_INSTALL_PREFIX=install -DCMAKE_BUILD_TYPE=Release
cmake --build build
cd build && ctest
cmake --install build
clean:
rm -rf build install Then everything seemed to work, until I started building the wheel (step 3, 'List dependencies of piper-phonemize'): running delocate-listdeps /Users/clementverrier/repos/piper-phonemize/dist/piper_phonemize-1.1.0-cp311-cp311-macosx_14_0_arm64.whl led to the following output error:
I spent a consequent amount of time with an LLM trying to debug this stuff, but couldn't find a working solution so far. @bluevisor have you encountered other problems except those you mentioned? @synesthesiam could you provide more information regarding the installation of piper via pip, including all its dependencies? |
I'm looking for instructions on how to build this for use with Python on MacOS. The piper-tts pip package exists for MacOS, but this dependency does not. I assume it is possible because there is a MacOS build of the library.
I'd also like to build this for use with iOS. Has this been attempted?
The text was updated successfully, but these errors were encountered: