bobfang1992 / pytomlpp

A python wrapper for tomlplusplus
https://bobfang1992.github.io/pytomlpp/pytomlpp.html
MIT License
86 stars 10 forks source link

No aarch64 linux wheels #74

Open fluxth opened 1 year ago

fluxth commented 1 year ago

I was trying to build pytomlpp on arm64 AWS Lambda docker (https://gallery.ecr.aws/lambda/python) and failed because it doesn't have wheels for aarch64.

#0 4.692   × Running setup.py install for pytomlpp did not run successfully.
#0 4.692   │ exit code: 1
#0 4.692   ╰─> [23 lines of output]
#0 4.692       /var/lang/lib/python3.10/site-packages/setuptools/config/setupcfg.py:508: SetuptoolsDeprecationWarning: The license_file parameter is deprecated, use license_files instead.
#0 4.692         warnings.warn(msg, warning_class)
#0 4.692       /var/lang/lib/python3.10/site-packages/setuptools/installer.py:27: SetuptoolsDeprecationWarning: setuptools.installer is deprecated. Requirements should be satisfied by a PEP 517 installer.
#0 4.692         warnings.warn(
#0 4.692       WARNING: The wheel package is not available.
#0 4.692       running install
#0 4.692       /var/lang/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
#0 4.692         warnings.warn(
#0 4.692       running build
#0 4.692       running build_py
#0 4.692       creating build
#0 4.692       creating build/lib.linux-aarch64-cpython-310
#0 4.692       creating build/lib.linux-aarch64-cpython-310/pytomlpp
#0 4.692       copying src/pytomlpp/_io.py -> build/lib.linux-aarch64-cpython-310/pytomlpp
#0 4.692       copying src/pytomlpp/__init__.py -> build/lib.linux-aarch64-cpython-310/pytomlpp
#0 4.692       copying src/pytomlpp/_impl.pyi -> build/lib.linux-aarch64-cpython-310/pytomlpp
#0 4.692       copying src/pytomlpp/py.typed -> build/lib.linux-aarch64-cpython-310/pytomlpp
#0 4.692       running build_ext
#0 4.692       building 'pytomlpp._impl' extension
#0 4.692       creating build/temp.linux-aarch64-cpython-310
#0 4.692       creating build/temp.linux-aarch64-cpython-310/src
#0 4.692       gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/tmp/pip-install-r6isratu/pytomlpp_7502938c16934c79935cdb7e5ce23bc7/include -I/tmp/pip-install-r6isratu/pytomlpp_7502938c16934c79935cdb7e5ce23bc7/third_party -I/tmp/pip-install-r6isratu/pytomlpp_7502938c16934c79935cdb7e5ce23bc7/.eggs/pybind11-2.10.4-py3.10.egg/pybind11/include -I/var/lang/include/python3.10 -c src/encoding_decoding.cpp -o build/temp.linux-aarch64-cpython-310/src/encoding_decoding.o -std=c++17
#0 4.692       error: command 'gcc' failed: No such file or directory
#0 4.692       [end of output]
#0 4.692
#0 4.692   note: This error originates from a subprocess, and is likely not a problem with pip.
#0 4.693 error: legacy-install-failure
#0 4.693
#0 4.693 × Encountered error while trying to install package.
#0 4.693 ╰─> pytomlpp
jngarber-st commented 10 months ago

A bit of a bummer not to see any response to this in 5 months. I may be having a similar issue, or maybe I'm just not waiting long enough for the build process to finish. I'm trying to build a Docker image with pytomlpp as a dependency. The log output stops at:

gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O3 -Wall -fPIC -I/tmp/pip-install-yc13jwfn/pytomlpp_31b6568a481d4ed3ab => => # 48d8efcf123dcd/include -I/tmp/pip-install-yc13jwfn/pytomlpp_31b6568a481d4ed3ab48d8efcf123dcd/third_party -I/tmp/pip-install-y => => # c13jwfn/pytomlpp_31b6568a481d4ed3ab48d8efcf123dcd/.eggs/pybind11-2.11.1-py3.12.egg/pybind11/include -I/usr/local/include/pyth => => # on3.12 -c src/encoding_decoding.cpp -o build/temp.linux-aarch64-cpython-312/src/encoding_decoding.o -std=c++17

I'm using the python:3.12 base image and this is on an Apple M2 based machine. I had no issue installing pytomlpp on this machine into virtual environments with Python versions 3.10, 3.11, and 3.12.

jngarber-st commented 10 months ago

I left the image build run for a little over 1.5 hrs then finally called it quits. I tried installing pytomlpp from the bash prompt within the container and had the same issue. However, of importance this issue happens when I use Colima. If I use the standard Docker CLI, the build process completes and pytomlpp works as expected. I'm not sure why there is a difference. This is the only Python library I've had this issue with so far, and there are several others in this particular image build.

bobfang1992 commented 10 months ago

Sorry for late response! I will take a look at this issue.