aerospike-client-python icon indicating copy to clipboard operation
aerospike-client-python copied to clipboard

pip install failed

Open betterltn opened this issue 9 years ago • 4 comments

src/include/serializer.h:55: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
src/include/serializer.h:65: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from src/main/aerospike.c:33:
src/include/module_functions.h:27: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from src/main/aerospike.c:34:
src/include/nullobject.h:22: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
src/include/nullobject.h:23: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
src/main/aerospike.c:36: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
src/main/aerospike.c:40: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Aerospike_Methods’
src/main/aerospike.c:82: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘initaerospike’
error: command 'gcc' failed with exit status 1

----------------------------------------

Command "/usr/bin/python -c "import setuptools, tokenize;file='/tmp/pip-build-nouMGx/aerospike/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/pip-UaNvaM-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-nouMGx/aerospike

centos 6.6 python 2.6.6

betterltn avatar Apr 27 '16 14:04 betterltn

Hi,

You missed to install the openssl-devel package. Please install the same and try pip install aerospike. This will resolve your issue.

vishnuraj555 avatar Apr 28 '16 01:04 vishnuraj555

Fails to install on Arch. Looks like it's searching for tools not specific to Arch distro: "lsb_release" and "rpm".

❯ pip install aerospike [16:57:15] Collecting aerospike Using cached aerospike-2.0.3.tar.gz Installing collected packages: aerospike Running setup.py install for aerospike ... error Complete output from command /home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/bin/python3.5 -u -c "import setuptools, tokenize;file='/tmp/foobar/pip-build-s3scvm10/aerospike/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/foobar/pip-t0g9e40p-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/include/site/python3.5/aerospike: info: Executing ./scripts/aerospike-client-c.sh which: no lsb_release in (/home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl) which: no rpm in (/home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl) error: is not supported. error: scripts/aerospike-client-c.sh 1

----------------------------------------

❯ Command "/home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/bin/python3.5 -u -c "import setuptools, tokenize;file='/tmp/foobar/pip-build-s3scvm10/aerospike/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/foobar/pip-t0g9e40p-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/foobar/dev/sedmi_odjel/python/project_boofoo/.venv/include/site/python3.5/aerospike" failed with error code 1 in /tmp/foobar/pip-build-s3scvm10/aerospike/

dakt avatar Apr 29 '16 15:04 dakt

I just viewed the build script...wow....can anyone explain why python client is firmly coupled to specific distros? Doesn't make much sense. I think this is the first package I ever witnessed to be distro specific. Well done!

dakt avatar Apr 29 '16 15:04 dakt

With pip (>=19.0) and latest python client (>=3.8.0), you should be able to install on linux without needing to download the c client or install any other dependencies anymore.

marknaero avatar Sep 03 '19 20:09 marknaero