termux-packages
termux-packages copied to clipboard
[Bug]: pygame setup
Problem description
Can't setup pygame
Steps to reproduce the behavior.
~/.../!/!DEV $ python -m pip install -U pygame==2.5.2 --user
Collecting pygame==2.5.2
Using cached pygame-2.5.2.tar.gz (15.8 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [51 lines of output]
Skipping Cython compilation
WARNING, No "Setup" File Exists, Running "buildconfig/config.py"
Using UNIX configuration...
/data/data/com.termux/files/usr/bin/sh: 1: dpkg-architecture: not found
gcc: error: unsupported option '-print-multiarch'
gcc: error: no input files
/data/data/com.termux/files/usr/bin/sh: 1: sdl2-config: not found
/data/data/com.termux/files/usr/bin/sh: 1: sdl2-config: not found
/data/data/com.termux/files/usr/bin/sh: 1: sdl2-config: not found
Hunting dependencies...
---
For help with compilation see:
https://www.pygame.org/wiki/Compilation
To contribute to pygame development see:
https://www.pygame.org/contribute.html
---
Traceback (most recent call last):
File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
return hook(config_settings)
^^^^^^^^^^^^^^^^^^^^^
File "/data/data/com.termux/files/usr/tmp/pip-build-env-_gta9r4x/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 325, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=['wheel'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/data/data/com.termux/files/usr/tmp/pip-build-env-_gta9r4x/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 295, in _get_build_requires
self.run_setup()
File "/data/data/com.termux/files/usr/tmp/pip-build-env-_gta9r4x/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 487, in run_setup
super().run_setup(setup_script=setup_script)
File "/data/data/com.termux/files/usr/tmp/pip-build-env-_gta9r4x/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
exec(code, locals())
File "<string>", line 409, in <module>
File "/data/data/com.termux/files/usr/tmp/pip-install-669gjj74/pygame_7202b61eda5a4876a7705f5efcf05509/buildconfig/config.py", line 231, in main
deps = CFG.main(**kwds, auto_config=auto)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/data/data/com.termux/files/usr/tmp/pip-install-669gjj74/pygame_7202b61eda5a4876a7705f5efcf05509/buildconfig/config_unix.py", line 218, in main
DependencyProg('SDL', 'SDL_CONFIG', 'sdl2-config', '2.0', ['sdl']),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/data/data/com.termux/files/usr/tmp/pip-install-669gjj74/pygame_7202b61eda5a4876a7705f5efcf05509/buildconfig/config_unix.py", line 43, in __init__
self.ver = config[0].strip()
~~~~~~^^^
IndexError: list index out of range
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
~/.../!/!DEV $
What is the expected behavior?
No response
System information
- Termux application version: 118
- Android OS version: 12
- Device model: xiaomi 12
$ pkg i xorgproto
Checking availability of current mirror:
[*] https://mirrors.ustc.edu.cn/termux/termux-main:
ok
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
xorg-util-macros
The following NEW packages will be installed:
xorg-util-macros xorgproto
0 upgraded, 2 newly installed, 0 to remove and 5 not upgraded.
Need to get 271 kB of archives.
After this operation, 2482 kB of additional disk space will be used.
0% [Working]to continue? [Y/n]
Get:1 https://mirrors.ustc.edu.cn/termux/termux-main stable/main aarch64 xorg-util-macros all 1.20.1 [21.9 kB]
Get:2 https://mirrors.ustc.edu.cn/termux/termux-main stable/main aarch64 xorgproto all 2024.1 [250 kB]
Fetched 271 kB in 1s (282 kB/s)
E: Can not write log (Is /dev/pts mounted?) - open (13: Permission denied)
Selecting previously unselected package xorg-util-macros.
(Reading database ... 70106 files and directories currently installed.)
Preparing to unpack .../xorg-util-macros_1.20.1_all.deb ...
Unpacking xorg-util-macros (1.20.1) ...
Selecting previously unselected package xorgproto.
Preparing to unpack .../xorgproto_2024.1_all.deb ...
Unpacking xorgproto (2024.1) ...
E: Can not write log (Is /dev/pts mounted?) - open (13: Permission denied)
Setting up xorg-util-macros (1.20.1) ...
Setting up xorgproto (2024.1) ...
~ $ pip3 install pygame==2.5.2
Collecting pygame==2.5.2
Using cached pygame-2.5.2.tar.gz (15.8 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: pygame
Building wheel for pygame (pyproject.toml) ... done
Created wheel for pygame: filename=pygame-2.5.2-cp311-cp311-linux_aarch64.whl size=9379990 sha256=48f76a3f949c82ce9be13e70b8b828c533c65a5adb3d0c7b5cb00f606de00802
Stored in directory: /data/data/com.termux/files/home/.cache/pip/wheels/f2/ae/5e/4f0fcdf8db7c79c9b41f648c20d4ce74647b83124fe34827f8
Successfully built pygame
Installing collected packages: pygame
Successfully installed pygame-2.5.2
~ $
I can't reproduce this issue on my device.
I think I shoud test again with your steps.Thanks