Installation of Python 2.6 error fixed

I wanted to install python2.6 in a virtual environment. The first step was to compile python 2.6 executable from the source code.

Once the source are extracted, just type:

./configure --prefix=<PATH_WHERE_TO_INSTALL>
make

If you are lucky, everything is smooth and you then just need to type

make install

In my case, under Linux Fedora, I got these error message:

gcc -pthread -c -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes  -I. -IInclude -I./Include   -DPy_BUILD_CORE -DSVNVERSION=\"`LC_ALL=C svnversion .`\" -o Modules/getbuildinfo.o ./Modules/getbuildinfo.c
gcc: error: directory": No such file or directory
make: *** [Modules/getbuildinfo.o] Error 1

Looking into the c source file, I figured out that the issue is related to a SVN problem. Indeed, the SVNVERSION variable needs to be defined in your environement.

Figure out what is the svn version first (svn –version) and type something like:

export SVNVERSION=1.7.8  # or whatever is your version
./configure
make

It worked for me.

Please follow and like us:
This entry was posted in Python and tagged , . Bookmark the permalink.

11 Responses to Installation of Python 2.6 error fixed

  1. Michael C says:

    Thanks for the tip! I was trying to install python 2.6 on centos 7 and had the same issue. Your instructions above fixed the problem.

  2. Jon E says:

    This worked for me!

    Thanks,
    Jon.

  3. Katharine says:

    Thank you SO much for this awesome help! This error had been really bumming me out, and this fixed it immediately! You dear. Thanks so much for sharing your expertise.

  4. Anonymous says:

    Wowee thanks a lot! First result in google too 🙂

  5. Rhys says:

    Had the same issue with Python 2.5. This also . fixes it.

  6. Anonymous says:

    Thanks! This worked also for me on Ubuntu 16.04

  7. Kani says:

    this worked. thanks for the information

  8. Anonymous says:

    thanks

  9. Anonymous says:

    it worked!thanks a lot!

  10. Anonymous says:

    This worked for me!

Leave a Reply

Your email address will not be published.