Skip to content

install issues (Could not build wheels for pyobjc-core, pyobjc-framework-Cocoa) #7

@joeypiccola

Description

@joeypiccola

I am trying to install py3-tts on my mac via python3 -m pip install py3-tts. I am using venv fwiw. I am not sure how to debug the following install errors. I have run python3 -m pip install --upgrade wheel successfully. I am using Python 3.12.3.

Collecting py3-tts
  Using cached py3_tts-3.5-py3-none-any.whl.metadata (25 kB)
Collecting six (from py3-tts)
  Using cached six-1.16.0-py2.py3-none-any.whl.metadata (1.8 kB)
<
.
..
...
omitted
...
..
.
>
Using cached pyobjc_framework_Vision-9.0.1-cp36-abi3-macosx_11_0_universal2.whl (16 kB)
Using cached pyobjc_framework_WebKit-9.0.1-cp36-abi3-macosx_11_0_universal2.whl (39 kB)
Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Building wheels for collected packages: pyobjc-core, pyobjc-framework-Cocoa
  Building wheel for pyobjc-core (pyproject.toml): started
  Building wheel for pyobjc-core (pyproject.toml): finished with status 'error'
  error: subprocess-exited-with-error
  
  × Building wheel for pyobjc-core (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [209 lines of output]
      running bdist_wheel
      running build
      running build_py
      Overriding build_packages to copy PyObjCTest
      creating build
      creating build/lib.macosx-13.0-x86_64-cpython-312
      creating build/lib.macosx-13.0-x86_64-cpython-312/objc
<
.
..
...
omitted
...
..
.
>
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/OC_PythonNumber.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/OC_PythonNumber.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/OC_PythonObject.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/OC_PythonObject.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/OC_PythonSet.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/OC_PythonSet.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/OC_PythonUnicode.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/OC_PythonUnicode.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/ObjCPointer.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/ObjCPointer.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/block_support.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/block_support.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/bundle-variables.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/bundle-variables.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/objc/class-builder.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/objc/class-builder.o -g -fexceptions -fno-objc-arc -Wall -Wstrict-prototypes -Wmissing-prototypes -Wformat=2 -W -Wpointer-arith -Wmissing-declarations -Wnested-externs -W -Wno-import -Wno-unknown-pragmas -Wshorten-64-to-32 -Werror -I/usr/include/ffi -fvisibility=hidden -g -O3 -flto=thin -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -DPyObjC_BUILD_RELEASE=1402
      Modules/objc/class-builder.m:1999:17: error: code will never be executed [-Werror,-Wunreachable-code]
                      PyMem_Free(argbuf);
                      ^~~~~~~~~~
      Modules/objc/class-builder.m:1990:17: error: code will never be executed [-Werror,-Wunreachable-code]
                      PyMem_Free(argbuf);
                      ^~~~~~~~~~
      2 errors generated.
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pyobjc-core
  Building wheel for pyobjc-framework-Cocoa (pyproject.toml): started
  Building wheel for pyobjc-framework-Cocoa (pyproject.toml): finished with status 'error'
  error: subprocess-exited-with-error
  
  × Building wheel for pyobjc-framework-Cocoa (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [517 lines of output]
      running bdist_wheel
      running build
      running build_py
      overriding build_packages to copy PyObjCTest
      creating build
      creating build/lib.macosx-13.0-x86_64-cpython-312
<
.
..
...
omitted
...
..
.
>      
      copying PyObjCTest/test_nssimplehorizontaltypesetter.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_cfdata.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nsxmlelement.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nsclipview.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nspagecontroller.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nsimage.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nsscrubberlayout.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      copying PyObjCTest/test_nslog.py -> build/lib.macosx-13.0-x86_64-cpython-312/PyObjCTest
      running build_ext
      building 'CoreFoundation._inlines' extension
      creating build/temp.macosx-13.0-x86_64-cpython-312
      creating build/temp.macosx-13.0-x86_64-cpython-312/Modules
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/_CoreFoundation_inlines.o -Wno-deprecated-declarations -DPyObjC_BUILD_RELEASE=1303 -Werror
      clang -bundle -undefined dynamic_lookup -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk build/temp.macosx-13.0-x86_64-cpython-312/Modules/_CoreFoundation_inlines.o -o build/lib.macosx-13.0-x86_64-cpython-312/CoreFoundation/_inlines.cpython-312-darwin.so -framework CoreFoundation
      building 'CoreFoundation._CoreFoundation' extension
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/_CoreFoundation.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/_CoreFoundation.o -Wno-deprecated-declarations -DPyObjC_BUILD_RELEASE=1303 -Werror
      clang -bundle -undefined dynamic_lookup -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk build/temp.macosx-13.0-x86_64-cpython-312/Modules/_CoreFoundation.o -o build/lib.macosx-13.0-x86_64-cpython-312/CoreFoundation/_CoreFoundation.cpython-312-darwin.so -framework CoreFoundation
      building 'Foundation._inlines' extension
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/_Foundation_inlines.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/_Foundation_inlines.o -Wno-deprecated-declarations -DPyObjC_BUILD_RELEASE=1303 -Werror
      clang -bundle -undefined dynamic_lookup -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk build/temp.macosx-13.0-x86_64-cpython-312/Modules/_Foundation_inlines.o -o build/lib.macosx-13.0-x86_64-cpython-312/Foundation/_inlines.cpython-312-darwin.so -framework Foundation
      building 'Foundation._Foundation' extension
      clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -I/Users/user/Documents/python/python30/speak/include -I/usr/local/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c Modules/_Foundation.m -o build/temp.macosx-13.0-x86_64-cpython-312/Modules/_Foundation.o -Wno-deprecated-declarations -DPyObjC_BUILD_RELEASE=1303 -Werror
      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
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pyobjc-framework-Cocoa
Failed to build pyobjc-core pyobjc-framework-Cocoa
ERROR: Could not build wheels for pyobjc-core, pyobjc-framework-Cocoa, which is required to install pyproject.toml-based projects

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions