Python needs CLANG, fails to build wheel (even in distrobox)

Is there something special about compiling from source on Aurora-dx ?
I can’t build a wheel when I install a package with dependencies.
https://paste.pythondiscord.com/324A

It fails the same way using:
host
distrobox-python3.12
distrobox-arch

Curiously my friend’s Arch Linux laptop built the same project without a hitch

I think Aurora doesn’t include Clang. I tried to install netifaces in Bluefin and it built. Try to install Clang inside your distrobox.

1 Like

It is recommended to use distrobox for this. I suspect that you are sharing the host’s home and the distrobox home and that is causing the Python setup script for netifaces to become confused about what features are available on the platform. Notice how every check is listed as (cached), meaning it has probably cached some incorrect configuration between your various distroboxes and the host.

I recommend to create a distrobox with its own home directory. I just quickly tested installing netifaces and it worked fine using the following method

Create the distrobox on the host:

$ sudo mkdir -p /var/distrobox/fedora41
$ sudo chown $(id -u):$(id -g) /var/distrobox/fedora41
$ distrobox create --home /var/distrobox/fedora41 --name my-fedora41-box --image quay.io/fedora/fedora-toolbox:41

Inside the distrobox:

$ sudo dnf install python3-pip python3-devel gcc
$ sudo pip install netifaces
$ python3
Python 3.13.1 (main, Dec  9 2024, 00:00:00) [GCC 14.2.1 20240912 (Red Hat 14.2.1-3)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import netifaces
>>> netifaces.interfaces()
['lo', 'wlp1s0', 'tailscale0']
1 Like

Dude, this is solid. I owe you one.

1 Like