Skip to content
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

M1 mac python3 build error #924

Closed
hiroalchem opened this issue May 11, 2024 · 1 comment
Closed

M1 mac python3 build error #924

hiroalchem opened this issue May 11, 2024 · 1 comment

Comments

@hiroalchem
Copy link

Versions

  • Python : 3.10.14
  • MacOS version : 13.3.1
  • XCode Version : 2397
  • Cython version : 0.29.36

Describe the bug

[DEBUG ] /usr/bin/install -c -m 644 ./Include/pyerrors.h /Users/hiroki/vscode/kivy-test/dist/root/python3/include/python3.11
[DEBUG ] Traceback (most recent call last):
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/./setup.py", line 1628, in
[DEBUG ] main()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/./setup.py", line 1598, in main
[DEBUG ] setup(# PyPI Metadata (PEP 301)
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/core.py", line 148, in setup
[DEBUG ] dist.run_commands()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/dist.py", line 966, in run_commands
[DEBUG ] self.run_command(cmd)
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/dist.py", line 985, in run_command
[DEBUG ] cmd_obj.run()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/command/build.py", line 135, in run
[DEBUG ] self.run_command(cmd_name)
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/cmd.py", line 313, in run_command
[DEBUG ] self.distribution.run_command(command)
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/dist.py", line 985, in run_command
[DEBUG ] cmd_obj.run()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/command/build_ext.py", line 340, in run
[DEBUG ] self.build_extensions()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/./setup.py", line 497, in build_extensions
[DEBUG ] self.detect_modules()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/./setup.py", line 1350, in detect_modules
[DEBUG ] self.detect_readline_curses()
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/./setup.py", line 1050, in detect_readline_curses
[DEBUG ] /usr/bin/install -c -m 644 ./Include/pyexpat.h /Users/hiroki/vscode/kivy-test/dist/root/python3/include/python3.11
[DEBUG ] do_readline = self.compiler.find_library_file(self.lib_dirs,
[DEBUG ] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/distutils/unixccompiler.py", line 294, in find_library_file
[DEBUG ] sysroot = _osx_support._default_sysroot(sysconfig.get_config_var('CC'))
[DEBUG ] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[DEBUG ] File "/Users/hiroki/vscode/kivy-test/build/python3/iphoneos-arm64/Python-3.11.6/Lib/_osx_support.py", line 162, in _default_sysroot
[DEBUG ] for line in contents.splitlines():
[DEBUG ] ^^^^^^^^^^^^^^^^^^^
[DEBUG ] AttributeError: 'NoneType' object has no attribute 'splitlines'
[DEBUG ] /usr/bin/install -c -m 644 ./Include/pyframe.h /Users/hiroki/vscode/kivy-test/dist/root/python3/include/python3.11
[DEBUG ] /usr/bin/install -c -m 644 ./Include/pyhash.h /Users/hiroki/vscode/kivy-test/dist/root/python3/include/python3.11
[DEBUG ] make: *** [sharedmods] Error 1

To Reproduce
toolchain build python3

@hiroalchem
Copy link
Author

Problem solved.
I reinstall xcode and delete .cache build dist directories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant