asachet
asachet

Reputation: 6921

pip install gives: skipping incompatible python libs and gcc failed with exit status 1

I am trying to install cytoolz on windows 8 and running "pip install cytoolz" gives me:

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs/libpython34.a when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs/python34.lib when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs\libpython34.a when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs/libpython34.a when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs/python34.lib when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
skipping incompatible C:\Python34\libs\python34.lib when searching for -lpython34

    c:/program files/mingw-builds/x64-4.8.1-posix-seh-rev5/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.1/../../../../x86_64-w64-mingw32/bin/ld.exe: 
cannot find -lpython34

    collect2.exe: error: ld returned 1 exit status

    error: command 'C:\\Program Files\\mingw-builds\\x64-4.8.1-posix-seh-rev5\\mingw64\\bin\\gcc.exe' failed with exit status 1

Yet the .lib and .a are in C:\Python34\libs. Most of the solutions I found were about installing python-dev, but I am on windows... From what I've read I believe this is a linkage problem between mingw and the python lib (not sure what this means), but then the path C:\Python34 is correct so I don't understand why the libraries aren't found or are incompatible.

My previous problem was that I vsvarsall.bat could not be found, I used this solution.

I don't know the first thing about compiling C code for python, please don't assume prior knowledge.

Upvotes: 1

Views: 803

Answers (1)

Rodrigo
Rodrigo

Reputation: 400

I know that this question is old, but I had a similar problem recently. The issue was that my gcc compiler were 64bit and my python instalation were 32bit. I reinstalled the python interpreter using the 64bit version and it stopped popping the "skipping incompatible C:\Python34\libs\python34.lib" message.

Upvotes: 4

Related Questions