Tôi đã quyết định chuyển từ Windows sang Linux, vì vậy tôi đã cài đặt bản beta cuối cùng của Ubuntu Rared.
Thật không may, tôi có một vấn đề Python.
Tôi đã cố gắng sử dụng pip
từ một virtualenv mà tôi đã tạo, để cài đặt các gói từ một requirements.txt
tệp như thế này:pip install -r requirements.txt
Tôi đã gặp lỗi sau khi cài đặt gói:
buildutils/initlibzmq.c:10:20: fatal error: Python.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
Tôi tìm thấy trên internet rằng để thoát khỏi điều này, tôi nên cài đặt python-dev
gói deb:
sudo apt-get install python-dev
Kể từ khi tôi cài đặt gói này, tôi gặp lỗi sau khi chạy python:
file: "ImportError: No module named _io".
I use this python from the virtualenv:
Python 2.7.4rc1 (default, Mar 30 2013, 15:39:28)
[GCC 4.7.2] on linux2
Có ai có ý tưởng gì không? Tôi không thể tìm thấy bất cứ điều gì trên Google và tôi thực sự cần phải giải quyết vấn đề này để sử dụng Ubuntu cho công việc của mình ...
Cảm ơn bạn đã giúp đỡ.
BIÊN TẬP:
Có vẻ như virtualenv của tôi đã bị hỏng vì một số lý do. Tôi gỡ cài đặt nó.
Tôi đã tạo lại một cái và thực hiện lại "pip install -r terms.txt" và bây giờ tôi gặp lỗi này:
Warning: failed to configure libzmq:
/bin/sh: 1: ./configure: not found
staging platform.hpp from: buildutils/include_linux
************************************************
Using bundled libzmq
************************************************
building 'zmq.libzmq' extension
creating build/temp.linux-x86_64-2.7/buildutils
creating build/temp.linux-x86_64-2.7/bundled
creating build/temp.linux-x86_64-2.7/bundled/zeromq
creating build/temp.linux-x86_64-2.7/bundled/zeromq/src
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -Ibundled/zeromq/include -Ibundled -I/usr/include/python2.7 -I/usr/include/x86_64-linux-gnu/python2.7 -c buildutils/initlibzmq.c -o build/temp.linux-x86_64-2.7/buildutils/initlibzmq.o
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -Ibundled/zeromq/include -Ibundled -I/usr/include/python2.7 -I/usr/include/x86_64-linux-gnu/python2.7 -c bundled/zeromq/src/ipc_address.cpp -o build/temp.linux-x86_64-2.7/bundled/zeromq/src/ipc_address.o
x86_64-linux-gnu-gcc: error trying to exec 'cc1plus': execvp: No such file or directory
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
EDIT2:
Các gcc
lỗi trên có thể được sửa chữa bằng cách cài đặt build-essential
gói.