collect2.exe:错误:ld返回1退出状态错误:命令'C:\\ MinGW \\ bin \\ gcc.exe'失败,退出状态为1

时间:2018-03-20 20:05:19

标签: python-3.x window cython

安装WinGW后,我正在尝试实施用户this example实施的Slimane

每当我python setup.py build_ext --inplace时,都会产生以下错误:

running build_ext
building 'test' extension
C:\MinGW\bin\gcc.exe -mdll -O -Wall -IC:\Users\Orbit\RPOSS\include -
IC:\Users\Orbit\AppData\Local\Programs\Python\Python35-32\include -
IC:\Users\Orbit\AppData\Local\Programs\Python\Python35-32\include -c test.c 
-o build\temp.win32-3.5\Release\test.o -fopenmp
In file included from C:\Users\Orbit\AppData\Local\Programs\Python\Python35-
32\include/Python.h:65:0,
             from test.c:23:
C:\Users\Orbit\AppData\Local\Programs\Python\Python35-
32\include/pytime.h:112:12: warning: 'struct timeval' declared inside 
parameter list will not be visible outside of this definition or declaration
 struct timeval *tv,
        ^~~~~~~
C:\Users\Orbit\AppData\Local\Programs\Python\Python35-
32\include/pytime.h:117:12: warning: 'struct timeval' declared inside 
parameter list will not be visible outside of this definition or declaration
 struct timeval *tv,
        ^~~~~~~
writing build\temp.win32-3.5\Release\test.cp35-win32.def
C:\MinGW\bin\gcc.exe -shared -s build\temp.win32-3.5\Release\test.o 
build\temp.win32-3.5\Release\test.cp35-win32.def -LC:\Users\Orbit\RPOSS\libs 
-LC:\Users\Orbit\AppData\Local\Programs\Python\Python35-32\libs -
LC:\Users\Orbit\AppData\Local\Programs\Python\Python35-32 -
LC:\Users\Orbit\RPOSS\PCbuild\win32 -lpython35 -lvcruntime140 -o 
C:\Users\Orbit\RPOSS\pre-test\test.cp35-win32.pyd -fopenmp
c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot 
find -lpthread
collect2.exe: error: ld returned 1 exit status
error: command 'C:\\MinGW\\bin\\gcc.exe' failed with exit status 1 

我用相同的错误标题查了同样的问题,但没有帮助我,是否有人可以解决这个问题?

0 个答案:

没有答案