I have an application which when I run it, it gives me the following error:

paraview: error while loading shared libraries: libpython2.6.so.1.0: cannot open shared object file: No such file or directory

I already have python 2.7 installed. When I type python, I can write codes. It seems it needs Python 2.6. I download and install the python 2.6 by downloading it and running:

make -j6
make checkinstall

But when I look for libpython2.6.so* in my computer, no files are found and still the application is crying for that. Can anyone please help me?


1 Answer 1


You are missing the shared Python2.6 library. It does not get build by default, that is why it's not there after you build and installed Python 2.6

Two options: Build new with shared library or install a pre-build package.

  1. To compile with the shared lib, do pretty much what you did in the first place, but configure with --enable-shared

    ./configure --enable-shared
    make -j6
    sudo checkinstall
    sudo ldconfig

    The library should be installed to /usr/lib/x86_64-linux-gnu or something similar like /usr/local/lib and thus be found by the loader. The last command makes the dynamic loader aware of the new library.

  2. Python2.6 is not in the Ubuntu repositories anymore, but you can install it from ppa:fkrull/deadsnakes.

    1. Remove your previous build. Since you installed with checkinstall, this is painless.
    2. Add the repo sudo add-apt-repository ppa:fkrull/deadsnakes
    3. Install sudo apt-get update && sudo apt-get install libpython2.6
    4. (Maybe) If libpython2.6 is not enough, install python2.6 and python2.6-dev
  • How should I install them in /usr/lib/x86_64-linux-gnu?
    – mmostajab
    Oct 18, 2015 at 8:18
  • @mmostajab You don't. They get installed automatically by make install or checkinstall.
    – Nephente
    Oct 18, 2015 at 9:12
  • but still after the checkinstall, I still have the same issue while the python2.6 is installed and the library is in /usr/local/lib/python2.6
    – mmostajab
    Oct 18, 2015 at 12:27
  • @mmostajab Sorry, after installing you probably have to do sudo ldconfig to make the loader aware of the new libraries. I have updated my answer.
    – Nephente
    Oct 19, 2015 at 6:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.