I want to build the python command line interface to globusconnectpersonal. The recommended way to do it is to use pip, so I tried that:
source ~/.venv/bin/activate
pip install -r ./requirements.txt
That fails:
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DUSE__THREAD -I/usr/include/ffi -I/usr/include/libffi -I/home/rmason/.venv/include -I/nix/store/yl3n75qzrfwdyv33n1vfhvk5bnv0mjpx-python3-3.10.0a5/include/python3.10 -c c/_cffi_backend.c -o build/temp.linux-x86_64-3.10/c/_cffi_backend.o
c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
15 | #include <ffi.h>
| ^~~~~~~
compilation terminated.
error: command ‘/home/rmason/.nix-profile/bin/gcc’ failed with exit code 1
----------------------------------------
ERROR: Command errored out with exit status 1: /home/rmason/.venv/bin/python -u -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘"’"’/tmp/pip-install-xad9gl76/cffi_87b7fb575aff4d0381d62bc292a1cf7e/setup.py’"’"’; file=’"’"’/tmp/pip-install-xad9gl76/cffi_87b7fb575aff4d0381d62bc292a1cf7e/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-uos5eris/install-record.txt --single-version-externally-managed --compile --install-headers /home/rmason/.venv/include/site/python3.10/cffi Check the logs for full command output.
Should I be using nix-shell? I have looked at Python - NixOS Wiki ’ Emulating virtualenv with nix-shell’ but the example is incomplete. What am I supposed to put in that example’s shell.nix where it has ‘= …build expression for this python library…;’?
I’m a newbie and I need a bit of hand-holding.
Thanks,
Roger