belangeo / pyo

Python DSP module
GNU Lesser General Public License v3.0
1.32k stars 132 forks source link

Dependencies and HomeBrew #257

Open FarmehrF opened 1 year ago

FarmehrF commented 1 year ago

Hi I wanted to play around with pyo but while installing using pip I got this error:

 include/ad_portaudio.h:25:10: fatal error: 'portaudio.h' file not found
      #include "portaudio.h"

But I've installed portaudio and other dependencies using brew, this is the output of brew install portaudio

Warning: portaudio 19.7.0 is already installed and up-to-date.
To reinstall 19.7.0, run:
  brew reinstall portaudio

Then I tried building it from the source but then I got this error:

include/servermodule.h:31:10: fatal error: 'sndfile.h' file not found
#include "sndfile.h"
         ^~~~~~~~~~~

But I've also installed this, this is the output of the command brew install libsndfile:

Warning: libsndfile 1.2.0 is already installed and up-to-date.
To reinstall 1.2.0, run:
  brew reinstall libsndfile
Python 3.10.9
macOS Monterey 12.6.1
Mac Mini M1
Bibiko commented 1 year ago

In such situations, consider setting the bash/zsh variables LIBRARY_PATH and CPATH explicitly.

On my Mac I have:

export LIBRARY_PATH="/opt/homebrew/lib:$LIBRARY_PATH" export CPATH="/opt/homebrew/include:$CPATH"

I'm on:

Python 3.10.9
macOS Ventura 13.2
MacBook Pro Apple M1 Max