zeroc-ice / ice

All-in-one solution for creating networked applications with RPC, pub/sub, server deployment, and more.
https://zeroc.com
GNU General Public License v2.0
2k stars 592 forks source link

PyPI build failure on macOS Sonoma 14.2.1 #1734

Closed externl closed 1 week ago

externl commented 5 months ago

A user reported the following:

Hi,

I tried to install zeroc-ice by running python3 -m pip install zeroc-ice on MacOS Sonoma 14.2.1, and it stuck on "Building wheel for zero-ice (pyproject.toml) ... for a very long time, and then got the following error message.

src/ice/mcpp/system.c:1009:20: error: call to undeclared function 'readlink'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] if ((len = readlink( slbuf1, slbuf2, PATHMAX)) > 0) { ^ src/ice/mcpp/system.c:1184:20: error: call to undeclared function 'readlink'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] if ((len = readlink( slbuf1, slbuf2, PATHMAX)) > 0) { ^ 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 zeroc-ice Running setup.py clean for zeroc-ice Failed to build zeroc-ice ERROR: Could not build wheels for zeroc-ice, which is required to install pyproject.toml-based projects

externl commented 5 months ago

Temporary workaround

CFLAGS='-Wno-implicit-function-declaration' python3 -m pip install zeroc-ice
externl commented 5 months ago

We should also check the npm slice2js build.

pepone commented 1 week ago

This was fixed in 3.7.10.1 PyPI package https://pypi.org/project/zeroc-ice/3.7.10.1/