12

Before asking my question, let me introduce my computing environment first.

  • OS: Red Hat Enterprise Linux Server 6.5.
  • Python: Python 2.6 (by rpm install), Python 2.7 (based on virtualenv)

Question:

I want to install a library that requires python-devel. However, when using

    yum install python-devel

The system installs python-devel-2.6.*, because the installed (yum-packaged) python is version 2.6. My question is , how to install python-devel that matches the version of the python in virtualenv (which is version 2.7 in my case).

Thanks!

1 Answer 1

6

This question has nothing to do with pip or virtualenv. python-dev is a Linux system package, not something you install with pip. You just need to explicitly install python-devel-2.7 - you can search your distribution's package repository for the exact package name.

Sign up to request clarification or add additional context in comments.

1 Comment

The (yum-packaged) python-devel-2.7 depends on (yum-packaged) python-2.7, which is not installed in my system. I guess I can always install python-devel-2.7 from source, but I want to know if there are any other ways. Thanks!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.