I do not understand what the problem is and how to solve it. When I execute
pip install --upgrade pip
And what I obtained is
Collecting pykerberos
Using cached pykerberos-1.1.14.tar.gz
Installing collected packages: pykerberos
Running setup.py install for pykerberos ... error
Complete output from command /usr/bin/python2 -u -c "import
setuptools, tokenize;__file__='/tmp/pip-build-
tlTKls/pykerberos/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-cFs8JW-record/install-record.txt --single-version-externally-
managed --compile:
running install
running build
running build_ext
building 'kerberos' extension
creating build
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/src
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-
D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-
buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE
-fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -
fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -
grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -
fPIC -I/usr/include/python2.7 -c src/kerberos.c -o build/temp.linux-
x86_64-2.7/src/kerberos.o -DGSSAPI_EXT
src/kerberos.c:17:20: error fatal: Python.h: No existe el fichero
o el directorio
#include <Python.h>
^
compilación terminada.
error: command 'gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python2 -u -c "import setuptools,
tokenize;__file__='/tmp/pip-build-
tlTKls/pykerberos/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-cFs8JW-record/install-record.txt --single-version-
externally-managed --compile" failed with error code 1 in /tmp/pip-
build-tlTKls/pykerberos/
I am installing this because I am trying to run kerberos to use it to authenticate when connecting through ansible. Request_kerberos is a dependency.
Any idea?
Thanks!!
Related
I am new to using Python packages, and I am trying to install a package called RSeQC into a Linux AWS instance.
I started by running:
sudo yum install python3-pip
then running:
sudo yum install python3-devel
and Finally:
sudo pip3 install RSeQC
However, I get the following long error:
compilation terminated.
In file included from libBigWig/bwWrite.c:6:0:
libBigWig/bigWig.h:4:10: fatal error: zlib.h: No such file or directory
#include <zlib.h>
^~~~~~~~
compilation terminated.
error: Command "gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -DNOCURL -DWITHNUMPY -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -IlibBigWig -I/usr/include/python3.7m -I/usr/local/lib64/python3.7/site-packages/numpy/core/include -I/usr/include/python3.7m -c pyBigWig.c -o build/temp.linux-x86_64-3.7/pyBigWig.o" failed with exit status 1
----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-
kv90ovvh/pyBigWig/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-smel45e_-record/install-record.txt --single-version-
externally-managed --compile" failed with error code 1 in /tmp/pip-build-kv90ovvh/pyBigWig/
Would greatly appreciate any advice in debugging this as I am stumped. Thanks in advance!
I have instaled basic version of Airflow which uses Sqlite as metastore. Now i am trying to install other Packages.
I tried the below Packages but failed with mysqlclient issue.
pip install apache-airflow[devel]
Error message with compile statement as below,
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall
-Wstrict-prototypes -fPIC -Dversion_info=(1,3,14,'final',0) -D__version__=1.3.14 -I/usr/include/mysql -I/opt/python-2.7.15/include/python2.7 -c _mysql.c -o build/temp.linux-x86_64-2.7/_mysql.o -g -pipe -Wp,-D_FORTIFY_SOURCE=2
-fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -fwrapv -fPIC -DUNIV_LINUX -DUNIV_LINUX
_mysql.c:29:19: error: mysql.h: No such file or directory
_mysql.c:30:26: error: mysqld_error.h: No such file or directory
_mysql.c:48:20: error: errmsg.h: No such file or directory
_mysql.c:67: error: expected specifier-qualifier-list before ‘MYSQL’
Final Failure Command in log:
Command "/home/usr/Airflow_Workspace/install/bin/python -u -c "import
setuptools,
tokenize;file='/tmp/pip-install-yeFo2f/mysqlclient/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-Bw_HED/install-record.txt --single-version-externally-managed --compile --install-headers /home/usr/Airflow_Workspace/install/include/site/python2.7/mysqlclient"
failed with error code 1 in /tmp/pip-install-yeFo2f/mysqlclient/
I tried installing many dependency for python but still not resolved. Could someone help me what exactly I am missing.
If you're on Ubuntu/Debian, you need the libmysqlclient-dev system package first.
sudo apt install libmysqlclient-dev
I have OS
Red Hat Enterprise Linux Server release 7.4 (Maipo)
and python
Python 2.7.13 :: Anaconda 4.4.0 (64-bit)
Tried to install lib sasl
sudo pip install sasl
Collecting sasl
Downloading http://repo.com/api/pypi/pypi/packages/8e/2c/45dae93d666aea8492678499e0999269b4e55f1829b1e4de5b8204706ad9/sasl-0.2.1.tar.gz
Collecting six (from sasl)
Downloading http://repo.com/api/pypi/pypi/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Installing collected packages: six, sasl
building 'sasl.saslwrapper' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/sasl
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -Isasl -I/usr/include/python2.7 -c sasl/saslwrapper.cpp -o build/temp.linux-x86_64-2.7/sasl/saslwrapper.o
In file included from sasl/saslwrapper.cpp:254:0:
sasl/saslwrapper.h:22:23: fatal error: sasl/sasl.h: No such file or directory
#include <sasl/sasl.h>
^
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python2 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-Ym7ZOA/sasl/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-_8ahws-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-Ym7ZOA/sasl/
How solve this problem?
if you are on AWS EC2/EMR or CentOS, sudo yum install cyrus-sasl-devel
From this issue, it seems that you need the libsasl2.
You can install libsasl2 by using the command :-
sudo apt-get install libsasl2-dev
I am using synology NAS and python(installed 2.7, 3.5)
when I try to install via PIP, I encounter this error message.
(the first time, I met curl-config not found error.
but now with several entware packages, I met with the message below)
----------
python3 -m pip install pycurl
Collecting pycurl
Using cached pycurl-7.43.0.tar.gz
Building wheels for collected packages: pycurl
Running setup.py bdist_wheel for pycurl ... error
Complete output from command /usr/local/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-79dqoc3v/pycurl/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpa8e0oiyqpip-wheel- --python-tag cp35:
Using curl-config (libcurl 7.55.0)
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.5
creating build/lib.linux-x86_64-3.5/curl
copying python/curl/__init__.py -> build/lib.linux-x86_64-3.5/curl
running build_ext
building 'pycurl' extension
creating build/temp.linux-x86_64-3.5
creating build/temp.linux-x86_64-3.5/src
/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -DSYNO_FIX_FLAG_BUG -DOPENSSL_NO_SSL3 -DOPENSSL_NO_SSL2 -DSYNOPLAT_F_X86_64 -O2 -include /usr/syno/include/platformconfig.h -DSYNO_ENVIRONMENT -DBUILD_ARCH=64 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -g -DSDK_VER_MIN_REQUIRED=600 -pipe -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -D_FORTIFY_SOURCE=2 -O2 -Wno-unused-result -fPIC -DPYCURL_VERSION="7.43.0" -DHAVE_CURL_SSL=1 -I/opt/include -I/volume1/#appstore/py3k/usr/local/include/python3.5m -c src/docstrings.c -o build/temp.linux-x86_64-3.5/src/docstrings.o
unable to execute '/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc': No such file or directory
error: command '/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc' failed with exit status 1
----------------------------------------
Failed building wheel for pycurl
Running setup.py clean for pycurl
Failed to build pycurl
Installing collected packages: pycurl
Running setup.py install for pycurl ... error
Complete output from command /usr/local/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-79dqoc3v/pycurl/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-q_rurvzr-record/install-record.txt --single-version-externally-managed --compile:
Using curl-config (libcurl 7.55.0)
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.5
creating build/lib.linux-x86_64-3.5/curl
copying python/curl/__init__.py -> build/lib.linux-x86_64-3.5/curl
running build_ext
building 'pycurl' extension
creating build/temp.linux-x86_64-3.5
creating build/temp.linux-x86_64-3.5/src
/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -DSYNO_FIX_FLAG_BUG -DOPENSSL_NO_SSL3 -DOPENSSL_NO_SSL2 -DSYNOPLAT_F_X86_64 -O2 -include /usr/syno/include/platformconfig.h -DSYNO_ENVIRONMENT -DBUILD_ARCH=64 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -g -DSDK_VER_MIN_REQUIRED=600 -pipe -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -D_FORTIFY_SOURCE=2 -O2 -Wno-unused-result -fPIC -DPYCURL_VERSION="7.43.0" -DHAVE_CURL_SSL=1 -I/opt/include -I/volume1/#appstore/py3k/usr/local/include/python3.5m -c src/docstrings.c -o build/temp.linux-x86_64-3.5/src/docstrings.o
unable to execute '/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc': No such file or directory
error: command '/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc' failed with exit status 1
----------------------------------------
Command "/usr/local/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-79dqoc3v/pycurl/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-q_rurvzr-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-79dqoc3v/pycurl/
I just had this problem too with by Synology DS415+. The only difference is that I tried to install netdisco.
I found that setting the CC environmental variable to the actual location of gcc compiler in advance helped
# export CC=/opt/bin/gcc
I am trying to build kerberos on opensuse 13.2 inside a docker container. I have already installed the required libraries:
bash-4.2# cat /etc/os-release
NAME=openSUSE
VERSION="13.2 (Harlequin)"
VERSION_ID="13.2"
PRETTY_NAME="openSUSE 13.2 (Harlequin) (x86_64)"
ID=opensuse
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:opensuse:13.2"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://opensuse.org/"
ID_LIKE="suse"
bash-4.2#
bash-4.2# zypper search --installed krb5
S | Name | Summary | Type
--+------------+---------------------------------------------+--------
i | krb5 | MIT Kerberos5 Implementation--Libraries | package
i | krb5-devel | MIT Kerberos5 - Include Files and Libraries | package
bash-4.2# pip install kerberos
Downloading/unpacking kerberos
Downloading kerberos-1.2.3.tar.gz
Running setup.py (path:/tmp/pip_build_root/kerberos/setup.py) egg_info for package kerberos
Installing collected packages: kerberos
Running setup.py install for kerberos
building 'kerberos' extension
gcc -pthread -fno-strict-aliasing -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -DNDEBUG -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -DOPENSSL_LOAD_CONF -fPIC -I/usr/include/python2.7 -c src/base64.c -o build/temp.linux-x86_64-2.7/src/base64.o sh: krb5-config: command not found
gcc: error: sh:: No such file or directory
gcc: error: krb5-config:: No such file or directory
gcc: error: command: No such file or directory
gcc: error: not: No such file or directory
gcc: error: found: No such file or directory
error: command 'gcc' failed with exit status 1
Complete output from command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/kerberos/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-8u80ki-record/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_ext
building 'kerberos' extension
creating build
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/src
gcc -pthread -fno-strict-aliasing -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -DNDEBUG -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -DOPENSSL_LOAD_CONF -fPIC -I/usr/include/python2.7 -c src/base64.c -o build/temp.linux-x86_64-2.7/src/base64.o sh: krb5-config: command not found
gcc: error: sh:: No such file or directory
gcc: error: krb5-config:: No such file or directory
gcc: error: command: No such file or directory
gcc: error: not: No such file or directory
gcc: error: found: No such file or directory
error: command 'gcc' failed with exit status 1
----------------------------------------
Cleaning up...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/kerberos/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-8u80ki-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_root/kerberos
Storing debug log for failure in /root/.pip/pip.log
I tried various things such as finding krb5-config or other krb5 libraries. But, on openSUSE everything is inside krb5-devel package. Do you have any pointers?
My core intention is to build Ansible Windows support on openSUSE
Python kerberos package seems to be difficult to compile, this could be at least a temporary workaround
pip install kerberos==1.1.1
Later versions seem to miss required header files, so there might be some packaging problem.
Try 1.2.4; not sure what went wrong with the headers in 1.2.3 but they are there in 1.2.4.