cycfi / q

C++ Library for Audio Digital Signal Processing
MIT License
1.2k stars 151 forks source link

Additional macOS setup instructions #1

Closed logsol closed 5 years ago

logsol commented 5 years ago

Hey Joel,

thank you for this wonderful library, the pitch tracking results it produces are really impressive. I would like to share my experience in setting up the library and tests and the additional steps that I needed to go through in order to make it work on macOS:

djowel commented 5 years ago

Thanks! I'll look into these. It seems what I need is something like this: https://github.com/supercollider/portaudio/blob/master/CMakeLists.txt#L276

portmidi.h and libportaudio.a should've been taken cared of by portaudio's Cmake though.

And q::wav_reader should give an error. I'll fix it.

Thanks for kicking the tires :-)

djowel commented 5 years ago

OK:

Could you check if this fixes the build issues for you? The fixes are in the master branch. CMake should pick up the portaudio header and lib just fine. If it still fails, could you post your CMakeCache.txt file here?

bmm-brobbins commented 5 years ago

Hi Karl and Joel. I'm trying to make the Xcode build modifications per your Feb 11 post. When I build Q I have unresolved Pa linker symbols, so I think your second bullet about linking to libportaudio.a might be key to fixing that.

Unfortunately the selection to add a new "New Link Binary with Libraries Phase" is greyed out in my case.

I'm probably in the wrong place. Any chance you could provide a screenshot showing me where you are adding this? Which project, which target, what else shows up in the Build Phases pane?

Thank you very much

djowel commented 5 years ago

It seems there's some conflict with portaudio version 1 and version 2. I committed a fix that removes the dependency on package manager installations for portaudio and portmidi. We'll just use submodules for these libraries just like we did on windows.

Tested. See if this works for you so we can close this issue. I'll still need to update the instructions (less steps now because we use the portaudio and portmidi cmake submodules). I'll also need to test on windows and linux.