Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No local packages or working download links found for python3-lxc #9

Open
rkkoszewski opened this issue Jan 4, 2019 · 6 comments
Open

Comments

@rkkoszewski
Copy link

Hi, I'm trying to install LXC-Web-Panel on a Raspberry Pi and I'm following the section "Installation from source code" and it fails in the "python setup.py install" (also python3 setup.py install) step. Any idea how to fix this? Is the PyPi package missing or is some dependency missing on my system?

The log I get before the exception is this one:

Installed /home/pi/gantry/gantryenv/lib/python3.5/site-packages/requests-2.21.0-py3.5.egg
Searching for python3-lxc
Reading https://pypi.python.org/simple/python3-lxc/
Couldn't find index page for 'python3-lxc' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading https://pypi.python.org/simple/
No local packages or working download links found for python3-lxc
@teotikalki
Copy link

I encountered the same error. I attempted to download what I hoped was an appropriate version here: https://packages.debian.org/stretch/amd64/python3-lxc/download and then install via dpkg -i but there was no change.

Debian Stretch, current update.

@n3storm
Copy link

n3storm commented Jan 28, 2019

My bad.
This is already in my requirements.txt but hadn't have time to update:

You should be able to install python3-xlc like this (remember to use the pip inside your environment):

pip install git+https://github.com/lxc/python3-lxc.git

@vgavgavga
Copy link

My bad.
This is already in my requirements.txt but hadn't have time to update:

You should be able to install python3-xlc like this (remember to use the pip inside your environment):

pip install git+https://github.com/lxc/python3-lxc.git

Collecting git+https://github.com/lxc/python3-lxc.git Cloning https://github.com/lxc/python3-lxc.git to /tmp/pip-req-build-oe6aoqfq Installing collected packages: python3-lxc Running setup.py install for python3-lxc ... error Complete output from command /root/gantry/gantryenv/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-req-build-oe6aoqfq/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-izi5fu20/install-record.txt --single-version-externally-managed --compile --install-headers /root/gantry/gantryenv/include/site/python3.5/python3-lxc: 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/lxc copying lxc/__init__.py -> build/lib.linux-x86_64-3.5/lxc running build_ext Package lxc was not found in the pkg-config search path. Perhaps you should add the directory containing lxc.pc'
to the PKG_CONFIG_PATH environment variable
No package 'lxc' found
building '_lxc' extension
creating build/temp.linux-x86_64-3.5
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/root/gantry/gantryenv/include -I/usr/include/python3.5m -c lxc.c -o build/temp.linux-x86_64-3.5/lxc.o
lxc.c:25:20: fatal error: Python.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

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

Command "/root/gantry/gantryenv/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-req-build-oe6aoqfq/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-izi5fu20/install-record.txt --single-version-externally-managed --compile --install-headers /root/gantry/gantryenv/include/site/python3.5/python3-lxc" failed with error code 1 in /tmp/pip-req-build-oe6aoqfq/
(gantryenv)
`

@teotikalki
Copy link

I had been eagerly awaiting the ability to use this fix (had just got a new 10Tb HDD in the server and was running badblocks for almost a week.
The command suggested by @n3storm produces the same error for me that it does for @vgavgavga.

@teotikalki
Copy link

I think I got it. You need to:
apt install python3-dev lxc-dev
After this the command:
pip install git+https://github.com/lxc/python3-lxc.git
Executes successfully. After THIS the step:
python setup.py install
now completes successfully.

@n3storm
Copy link

n3storm commented Feb 26, 2019

Great! I'm not dead. Just need to finish something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants