Install libffi headers

This is to resolve the following issue in CI:

    c/_cffi_backend.c:15:17: fatal error: ffi.h: No such file or directory
     #include <ffi.h>
                     ^
    compilation terminated.
    error: command 'gcc' failed with exit status 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/zuul/kayobe-venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-PV3WhJ/cffi/setup.py'"'"'; __file__='"'"'/tmp/pip-install-PV3WhJ/cffi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-ZvlZVY/install-record.txt --single-version-externally-managed --compile --install-headers /home/zuul/kayobe-venv/include/site/python2.7/cffi Check the logs for full command output.

Change-Id: I1bd724be7dc77058870f37cb1c9404472fa466ca
see: https://zuul.opendev.org/t/openstack/build/c20a316a699b4073abf75960634ebfcd
This commit is contained in:
Will Szumski 2019-10-15 13:35:15 +01:00
parent 6430ec5261
commit a3d3649c5e
2 changed files with 4 additions and 4 deletions

View File

@ -85,9 +85,9 @@ function config_init {
function install_dependencies { function install_dependencies {
echo "Installing package dependencies for kayobe" echo "Installing package dependencies for kayobe"
if [[ -e /etc/centos-release ]]; then if [[ -e /etc/centos-release ]]; then
sudo yum -y install gcc git vim python-virtualenv sudo yum -y install gcc git vim python-virtualenv libffi-devel
else else
sudo apt install -y python-dev python-virtualenv gcc git sudo apt install -y python-dev python-virtualenv gcc git libffi-dev
fi fi
} }

View File

@ -26,11 +26,11 @@ some of kayobe's python dependencies.
On CentOS:: On CentOS::
$ yum install -y python-devel python-virtualenv gcc $ yum install -y python-devel python-virtualenv gcc libffi-devel
On Ubuntu:: On Ubuntu::
$ apt install -y python-dev python-virtualenv gcc $ apt install -y python-dev python-virtualenv gcc libffi-dev
If installing Kayobe from source, then Git is required for cloning and working If installing Kayobe from source, then Git is required for cloning and working
with the source code repository. with the source code repository.