can't build python part with C modules
Bug #1802345 reported by
Alberto Donato
This bug affects 3 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Snapcraft |
New
|
Undecided
|
Unassigned |
Bug Description
Building python packages that have C modules fails with snapcraft as C headers are not found.
This is a sample snap that fails building on Bionic:
name: test
version: '1.0'
summary: test
description: test
grade: stable
confinement: strict
base: core18
apps:
uwsgi:
command: uwsgi
parts:
uwsgi:
plugin: python
source: .
python-
- uWSGI
build-packages:
- python3-dev
stage-packages:
- libpython3.6
exporting C_INCLUDE_
Tested with both stable (2.43.1) and candidate (3.0) snaps.
Also, removing the core18 base and using libpython3.5 when building on xenial shows the same issue
This is a bigger issue when building with VMs in snapcraft 3, as there's no way to export C_INCLUDE_PATH.
FWIW I also tried
override-build: | PATH=/usr/ include/ python3. 6
export C_INCLUDE_
snapcraftctl build
but that didn't work for me either