apeatling / ollama-voice-mac

Mac compatible Ollama Voice

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Compiler error on M3

Daniel-AT opened this issue · comments

Hi Andy, thanks for this exciting project! I am trying to run this on a MBP with M3. However, I get the following compiler error when executing pip3 install -r requirements.txt:

In file included from Modules/_Foundation.m:14:
Modules/_Foundation_string.m:36:9: error: variable 'buf2' is uninitialized when used here [-Werror,-Wuninitialized]
if (buf2 != Py_None && buf2 != PyObjC_NULL) {
^~~~
Modules/_Foundation_string.m:18:34: note: initialize the variable 'buf2' to silence this warning
PyObject * buf1, *buf2;
^
= NULL
1 error generated.
error: command '/usr/bin/clang' failed with exit code 1

Hope someone can help. Thanks in advance.

I think based on this issue (PyObjC - possibly needs updating to 9.1.1?), the issue is with PyObjC dependency being 9.0.1 in this project, while it must be 9.1.1:

ollama-voice-mac pip install pipdeptree
pipdeptree -p pyobjc

Collecting pipdeptree
  Downloading pipdeptree-2.13.1-py3-none-any.whl.metadata (15 kB)
Downloading pipdeptree-2.13.1-py3-none-any.whl (26 kB)
Installing collected packages: pipdeptree
Successfully installed pipdeptree-2.13.1
Warning!! Cyclic dependencies found:
* conda-libmamba-solver => conda => conda-libmamba-solver
* conda => conda-libmamba-solver => conda
------------------------------------------------------------------------
pyobjc==9.0.1
├── pyobjc-core [required: ==9.0.1, installed: 9.0.1]

Could you try setting PyObjC==9.1.1 in your requirements file so that that version overrides the indirect dependency fetch from other packages?

I don't have a M3 to test with, but could successfully build on a M2 Air.

Thanks! I edited requirements.txt and added the line pyobjc==9.1.1.
Not it executes without errors!