Python论坛  - 讨论区

标题:[python-chinese] 编译swig时候的一点问题

2006年04月29日 星期六 01:20

Jay wz12 at yeah.net
Sat Apr 29 01:20:53 HKT 2006

大家好。
我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
我没有VC,安装了Dev-C++,采用它的gcc

编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
一些函数的出处。

在次请教各位,该怎么办


E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC -shared e
xample.c example_wrap.c -o example.dll -Id:\p\python24\include -LD:\P\python24\l
ibs -lpython24 -lpyexpat -lselect
cc1.exe: warning: -fPIC ignored for target (all code is position independent)
cc1.exe: warning: -fPIC ignored for target (all code is position independent)
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c: undefined
reference to `_imp__PyExc_MemoryError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c: undefined
reference to `_imp__PyExc_IOError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c: undefined
reference to `_imp__PyExc_RuntimeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c: undefined
reference to `_imp__PyExc_IndexError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c: undefined
reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c: undefined
reference to `_imp__PyExc_ZeroDivisionError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c: undefined
reference to `_imp__PyExc_OverflowError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c: undefined
reference to `_imp__PyExc_SyntaxError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c: undefined
reference to `_imp__PyExc_ValueError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c: undefined
reference to `_imp__PyExc_SystemError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c: undefined
reference to `_imp__PyExc_AttributeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c: undefined
reference to `_imp__PyExc_RuntimeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c: undefined
reference to `_imp__PyExc_RuntimeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c: undefined
reference to `_imp___Py_NoneStruct'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c: undefined
reference to `_imp__PyList_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c: undefined
reference to `_imp__PyList_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c: undefined
reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c: undefined
reference to `_imp__PyTuple_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c: undefined
reference to `_imp__PyTuple_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c: undefined
reference to `_imp__PyExc_SystemError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c: undefined
reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c: undefined
reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c: undefined
reference to `_imp__PyClass_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c: undefined
 reference to `_imp__PyType_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c: undefined
 reference to `_imp__PyType_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c: undefined
 reference to `_imp__PyInstance_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c: undefined
 reference to `_imp___PyWeakref_ProxyType'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c: undefined
 reference to `_imp___PyWeakref_CallableProxyType'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c: undefined
 reference to `_imp__PyCFunction_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c: undefined
 reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c: undefined
 reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c: undefined
 reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c: undefined
 reference to `_imp__PyExc_TypeError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c: undefined
 reference to `_imp__PyFloat_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c: undefined
 reference to `_imp__PyFloat_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c: undefined
 reference to `_imp__PyInt_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c: undefined
 reference to `_imp__PyInt_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c: undefined
 reference to `_imp__PyLong_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c: undefined
 reference to `_imp__PyLong_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c: undefined
 reference to `_imp__PyInt_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c: undefined
 reference to `_imp__PyInt_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c: undefined
 reference to `_imp__PyLong_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c: undefined
 reference to `_imp__PyLong_Type'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c: undefined
 reference to `_imp__PyExc_NameError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c: undefined
 reference to `_imp__PyExc_NameError'
C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c: undefined
 reference to `_imp__PyType_Type'

E:\install\swigwin-1.3.29\Examples\python\simple>


Jay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/2fdcf444/attachment.html

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 07:42

大熊 bearsprite at gmail.com
Sat Apr 29 07:42:03 HKT 2006

没有include python.h?

在06-4-29,Jay <wz12 at yeah.net> 写道:
>
> 大家好。
> 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> 我没有VC,安装了Dev-C++,采用它的gcc
>
> 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> 一些函数的出处。
>
> 在次请教各位,该怎么办
>
>
> E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> -shared e
> xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> -LD:\P\python24\l
> ibs -lpython24 -lpyexpat -lselect
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> undefined
> reference to `_imp__PyExc_MemoryError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IOError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IndexError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ZeroDivisionError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_OverflowError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SyntaxError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ValueError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> undefined
> reference to `_imp__PyExc_AttributeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> undefined
> reference to `_imp___Py_NoneStruct'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> undefined
> reference to `_imp__PyClass_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> undefined
>  reference to `_imp__PyInstance_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_ProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_CallableProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> undefined
>  reference to `_imp__PyCFunction_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
>
> E:\install\swigwin-1.3.29\Examples\python\simple>
>
>
> Jay
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
茫茫人海,你是我的最爱
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/4facec48/attachment.html

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 09:45

River Yan riverfor at gmail.com
Sat Apr 29 09:45:51 HKT 2006

确认D:\P\python24\libs下有libpython24.a或者libpython24.so?

On 4/29/06, Jay <wz12 at yeah.net> wrote:
>
> 大家好。
> 我本来安装有bcb5,
> 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> 我没有VC,安装了Dev-C++,采用它的gcc
>
> 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> 一些函数的出处。
>
> 在次请教各位,该怎么办
>
>
> E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> -shared e
> xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> -LD:\P\python24\l
> ibs -lpython24 -lpyexpat -lselect
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> undefined
> reference to `_imp__PyExc_MemoryError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IOError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IndexError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ZeroDivisionError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_OverflowError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SyntaxError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ValueError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> undefined
> reference to `_imp__PyExc_AttributeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> undefined
> reference to `_imp___Py_NoneStruct'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> undefined
> reference to `_imp__PyClass_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> undefined
>  reference to `_imp__PyInstance_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_ProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_CallableProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> undefined
>  reference to `_imp__PyCFunction_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
>
> E:\install\swigwin-1.3.29\Examples\python\simple>
>
>
>
> Jay
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to
> python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to
> python-chinese-request at lists.python.cn
> Detail Info:
> http://python.cn/mailman/listinfo/python-chinese
>
>


--
riverfor's showtime.
riverfor's game

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 13:36

刘鑫 march.liu at gmail.com
Sat Apr 29 13:36:59 HKT 2006

Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib

在06-4-29,Jay <wz12 at yeah.net> 写道:
>
> 大家好。
> 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> 我没有VC,安装了Dev-C++,采用它的gcc
>
> 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> 一些函数的出处。
>
> 在次请教各位,该怎么办
>
>
> E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> -shared e
> xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> -LD:\P\python24\l
> ibs -lpython24 -lpyexpat -lselect
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> cc1.exe: warning: -fPIC ignored for target (all code is position
> independent)
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> undefined
> reference to `_imp__PyExc_MemoryError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IOError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> undefined
> reference to `_imp__PyExc_IndexError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ZeroDivisionError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> undefined
> reference to `_imp__PyExc_OverflowError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SyntaxError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> undefined
> reference to `_imp__PyExc_ValueError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> undefined
> reference to `_imp__PyExc_AttributeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> undefined
> reference to `_imp__PyExc_RuntimeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> undefined
> reference to `_imp___Py_NoneStruct'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> undefined
> reference to `_imp__PyList_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> undefined
> reference to `_imp__PyTuple_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> undefined
> reference to `_imp__PyExc_SystemError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> undefined
> reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> undefined
> reference to `_imp__PyClass_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> undefined
>  reference to `_imp__PyInstance_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_ProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> undefined
>  reference to `_imp___PyWeakref_CallableProxyType'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> undefined
>  reference to `_imp__PyCFunction_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_TypeError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> undefined
>  reference to `_imp__PyFloat_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> undefined
>  reference to `_imp__PyInt_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> undefined
>  reference to `_imp__PyLong_Type'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> undefined
>  reference to `_imp__PyExc_NameError'
> C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> undefined
>  reference to `_imp__PyType_Type'
>
> E:\install\swigwin-1.3.29\Examples\python\simple>
>
>
> Jay
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
欢迎访问:
http://blog.csdn.net/ccat

刘鑫
March.Liu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/a520e926/attachment-0001.html

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 14:19

imcs ee imcsee at gmail.com
Sat Apr 29 14:19:11 HKT 2006

请教个和这个相关的问题,一直不太明白。就是VC7.1和mingw之间"
混用"会带来什么问题呢,我安装的python上下载的二进制的,应该是VC7.1编译的,而自己也下载过一些包含c/cpp源文件的python模块,是用mingw+swig编译的,看了一些讨论,好像这样两者会有些问题,好像是两者用的msvcrt不是同一个文件,而且更糟糕的是,虽然vs2005出来,又是不同的文件了,而python2.4/2.5官方版本都用vs2003编译。
不太清楚具体的情况,可能上面好多自己理解错误,哪位给介绍下,一般情况下用mingw编译模块有什么问题么,(mingw主要是linux和win下面比较方便移植了吧)
另外,如果上面这个mingw有些缺陷的话,哪儿有些用Visual Studio .NET
2003来作模块的例子么,找了一下,都是提供用微软free的tookit来编译,连着还不太一样吧。


On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
>
> Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib
>
>  在06-4-29,Jay <wz12 at yeah.net> 写道:
>
> >  大家好。
> > 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> > 我没有VC,安装了Dev-C++,采用它的gcc
> >
> > 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> > 一些函数的出处。
> >
> > 在次请教各位,该怎么办
> >
> >
> > E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> > -shared e
> > xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> > -LD:\P\python24\l
> > ibs -lpython24 -lpyexpat -lselect
> > cc1.exe: warning: -fPIC ignored for target (all code is position
> > independent)
> > cc1.exe: warning: -fPIC ignored for target (all code is position
> > independent)
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_MemoryError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_IOError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_RuntimeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_IndexError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_ZeroDivisionError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_OverflowError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_SyntaxError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_ValueError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_SystemError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_AttributeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_RuntimeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_RuntimeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> > undefined
> > reference to `_imp___Py_NoneStruct'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> > undefined
> > reference to `_imp__PyList_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> > undefined
> > reference to `_imp__PyList_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> > undefined
> > reference to `_imp__PyTuple_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> > undefined
> > reference to `_imp__PyTuple_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_SystemError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> > undefined
> > reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> > undefined
> > reference to `_imp__PyClass_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> > undefined
> >  reference to `_imp__PyType_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> > undefined
> >  reference to `_imp__PyType_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> > undefined
> >  reference to `_imp__PyInstance_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> > undefined
> >  reference to `_imp___PyWeakref_ProxyType'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> > undefined
> >  reference to `_imp___PyWeakref_CallableProxyType'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> > undefined
> >  reference to `_imp__PyCFunction_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_TypeError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> > undefined
> >  reference to `_imp__PyFloat_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> > undefined
> >  reference to `_imp__PyFloat_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> > undefined
> >  reference to `_imp__PyInt_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> > undefined
> >  reference to `_imp__PyInt_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> > undefined
> >  reference to `_imp__PyLong_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> > undefined
> >  reference to `_imp__PyLong_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> > undefined
> >  reference to `_imp__PyInt_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> > undefined
> >  reference to `_imp__PyInt_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> > undefined
> >  reference to `_imp__PyLong_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> > undefined
> >  reference to `_imp__PyLong_Type'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_NameError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> > undefined
> >  reference to `_imp__PyExc_NameError'
> > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> > undefined
> >  reference to `_imp__PyType_Type'
> >
> > E:\install\swigwin-1.3.29\Examples\python\simple>
> >
> >
> > Jay
> >
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to   python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>
>
>
> --
> 欢迎访问:
> http://blog.csdn.net/ccat
>
> 刘鑫
> March.Liu
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/68ff35db/attachment-0001.htm

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 14:47

刘鑫 march.liu at gmail.com
Sat Apr 29 14:47:39 HKT 2006

主要是VC的静态链接库和GCC的不兼容,所以需要重编译相关的.lib

在06-4-29,imcs ee <imcsee at gmail.com> 写道:
>
> 请教个和这个相关的问题,一直不太明白。就是VC7.1和mingw之间"混用"会带来什么问题呢,我安装的python上下载的二进制的,应该是VC7.1编译的,而自己也下载过一些包含c/cpp源文件的python模块,是用mingw+swig编译的,看了一些讨论,好像这样两者会有些问题,好像是两者用的msvcrt不是同一个文件,而且更糟糕的是,虽然vs2005出来,又是不同的文件了,而python2.4/2.5官方版本都用vs2003编译。
>
>
> 不太清楚具体的情况,可能上面好多自己理解错误,哪位给介绍下,一般情况下用mingw编译模块有什么问题么,(mingw主要是linux和win下面比较方便移植了吧)
> 另外,如果上面这个mingw有些缺陷的话,哪儿有些用Visual Studio .NET
> 2003来作模块的例子么,找了一下,都是提供用微软free的tookit来编译,连着还不太一样吧。
>
>
> On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
> >
> > Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib
> >
> >  在06-4-29,Jay < wz12 at yeah.net> 写道:
> >
> > >  大家好。
> > > 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> > > 我没有VC,安装了Dev-C++,采用它的gcc
> > >
> > > 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> > > 一些函数的出处。
> > >
> > > 在次请教各位,该怎么办
> > >
> > >
> > > E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> > > -shared e
> > > xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> > > -LD:\P\python24\l
> > > ibs -lpython24 -lpyexpat -lselect
> > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > independent)
> > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > independent)
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_MemoryError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_IOError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_IndexError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_ZeroDivisionError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_OverflowError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SyntaxError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_ValueError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SystemError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_AttributeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> > > undefined
> > > reference to `_imp___Py_NoneStruct'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyList_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyList_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyTuple_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyTuple_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SystemError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyClass_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInstance_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> > > undefined
> > >  reference to `_imp___PyWeakref_ProxyType'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> > > undefined
> > >  reference to `_imp___PyWeakref_CallableProxyType'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyCFunction_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyFloat_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyFloat_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_NameError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_NameError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > >
> > > E:\install\swigwin-1.3.29\Examples\python\simple>
> > >
> > >
> > > Jay
> > >
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to
> > python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
> >
> >
> > --
> > 欢迎访问:
> > http://blog.csdn.net/ccat
> >
> > 刘鑫
> > March.Liu
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
欢迎访问:
http://blog.csdn.net/ccat

刘鑫
March.Liu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/cb7ceb23/attachment-0001.htm

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 17:05

imcs ee imcsee at gmail.com
Sat Apr 29 17:05:47 HKT 2006

最近看到这个
http://groups.google.com/group/comp.lang.python/browse_frm/thread/17558adbc053f26d/d704fc0ec8414bcd?lnk=raot#d704fc0ec8414bcd

好多内容,没看明白,他们好像意见也不统一。

On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
>
> 主要是VC的静态链接库和GCC的不兼容,所以需要重编译相关的.lib
>
> 在06-4-29,imcs ee <imcsee at gmail.com> 写道:
>
> >  请教个和这个相关的问题,一直不太明白。就是VC7.1和mingw之间"混用"会带来什么问题呢,我安装的python上下载的二进制的,应该是VC7.1编译的,而自己也下载过一些包含c/cpp源文件的python模块,是用mingw+swig编译的,看了一些讨论,好像这样两者会有些问题,好像是两者用的msvcrt不是同一个文件,而且更糟糕的是,虽然vs2005出来,又是不同的文件了,而python2.4/2.5官方版本都用vs2003编译。
> >
> >
> > 不太清楚具体的情况,可能上面好多自己理解错误,哪位给介绍下,一般情况下用mingw编译模块有什么问题么,(mingw主要是linux和win下面比较方便移植了吧)
> > 另外,如果上面这个mingw有些缺陷的话,哪儿有些用Visual Studio .NET
> > 2003来作模块的例子么,找了一下,都是提供用微软free的tookit来编译,连着还不太一样吧。
> >
> >
> >  On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
> > >
> > > Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib
> > >
> > >  在06-4-29,Jay < wz12 at yeah.net> 写道:
> > >
> > > >  大家好。
> > > > 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> > > > 我没有VC,安装了Dev-C++,采用它的gcc
> > > >
> > > > 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> > > > 一些函数的出处。
> > > >
> > > > 在次请教各位,该怎么办
> > > >
> > > >
> > > > E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__
> > > > -fPIC -shared e
> > > > xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> > > > -LD:\P\python24\l
> > > > ibs -lpython24 -lpyexpat -lselect
> > > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > > independent)
> > > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > > independent)
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_MemoryError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_IOError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_RuntimeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_IndexError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_ZeroDivisionError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_OverflowError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_SyntaxError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_ValueError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_SystemError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_AttributeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_RuntimeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_RuntimeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> > > > undefined
> > > > reference to `_imp___Py_NoneStruct'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyList_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyList_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyTuple_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyTuple_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_SystemError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> > > > undefined
> > > > reference to `_imp__PyClass_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyType_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyType_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyInstance_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp___PyWeakref_ProxyType'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp___PyWeakref_CallableProxyType'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyCFunction_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_TypeError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyFloat_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyFloat_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyInt_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyInt_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyLong_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyLong_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyInt_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyInt_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyLong_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyLong_Type'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_NameError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyExc_NameError'
> > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> > > > undefined
> > > >  reference to `_imp__PyType_Type'
> > > >
> > > > E:\install\swigwin-1.3.29\Examples\python\simple>
> > > >
> > > >
> > > > Jay
> > > >
> > >
> > > _______________________________________________
> > > python-chinese
> > > Post: send python-chinese at lists.python.cn
> > > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > > Unsubscribe: send unsubscribe to
> > > python-chinese-request at lists.python.cn
> > > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> > >
> > >
> > >
> > >
> > > --
> > > 欢迎访问:
> > > http://blog.csdn.net/ccat
> > >
> > > 刘鑫
> > > March.Liu
> > >
> > > _______________________________________________
> > > python-chinese
> > > Post: send python-chinese at lists.python.cn
> > > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > > Unsubscribe: send unsubscribe to
> > > python-chinese-request at lists.python.cn
> > > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> > >
> > >
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to
> > python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
>
>
> --
> 欢迎访问:
> http://blog.csdn.net/ccat
>
> 刘鑫
> March.Liu
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/49ee0c73/attachment-0001.htm

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 17:27

刘鑫 march.liu at gmail.com
Sat Apr 29 17:27:44 HKT 2006

这个问题我在几年前用Boost.Python的时候就遇到过,重编译PythonXX.lib之后解决。相关的文档在我的Blog上还能找到。

在06-4-29,imcs ee <imcsee at gmail.com> 写道:
>
> 最近看到这个
> http://groups.google.com/group/comp.lang.python/browse_frm/thread/17558adbc053f26d/d704fc0ec8414bcd?lnk=raot#d704fc0ec8414bcd
>
>
> 好多内容,没看明白,他们好像意见也不统一。
>
> On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
> >
> > 主要是VC的静态链接库和GCC的不兼容,所以需要重编译相关的.lib
> >
> > 在06-4-29,imcs ee <imcsee at gmail.com> 写道:
> >
> > >  请教个和这个相关的问题,一直不太明白。就是VC7.1和mingw之间"混用"会带来什么问题呢,我安装的python上下载的二进制的,应该是VC7.1编译的,而自己也下载过一些包含c/cpp源文件的python模块,是用mingw+swig编译的,看了一些讨论,好像这样两者会有些问题,好像是两者用的msvcrt不是同一个文件,而且更糟糕的是,虽然vs2005出来,又是不同的文件了,而python2.4/2.5官方版本都用vs2003编译。
> > >
> > >
> > > 不太清楚具体的情况,可能上面好多自己理解错误,哪位给介绍下,一般情况下用mingw编译模块有什么问题么,(mingw主要是linux和win下面比较方便移植了吧)
> > > 另外,如果上面这个mingw有些缺陷的话,哪儿有些用Visual Studio .NET
> > > 2003来作模块的例子么,找了一下,都是提供用微软free的tookit来编译,连着还不太一样吧。
> > >
> > >
> > >  On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
> > > >
> > > > Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib
> > > >
> > > >  在06-4-29,Jay < wz12 at yeah.net > 写道:
> > > >
> > > > >  大家好。
> > > > > 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> > > > > 我没有VC,安装了Dev-C++,采用它的gcc
> > > > >
> > > > > 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> > > > > 一些函数的出处。
> > > > >
> > > > > 在次请教各位,该怎么办
> > > > >
> > > > >
> > > > > E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__
> > > > > -fPIC -shared e
> > > > > xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> > > > > -LD:\P\python24\l
> > > > > ibs -lpython24 -lpyexpat -lselect
> > > > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > > > independent)
> > > > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > > > independent)
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_MemoryError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_IOError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_RuntimeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_IndexError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_ZeroDivisionError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_OverflowError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_SyntaxError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_ValueError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_SystemError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_AttributeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_RuntimeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_RuntimeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp___Py_NoneStruct'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyList_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyList_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyTuple_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyTuple_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_SystemError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> > > > > undefined
> > > > > reference to `_imp__PyClass_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyType_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyType_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyInstance_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp___PyWeakref_ProxyType'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp___PyWeakref_CallableProxyType'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyCFunction_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_TypeError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyFloat_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyFloat_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyInt_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyInt_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyLong_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyLong_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyInt_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyInt_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyLong_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyLong_Type'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_NameError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyExc_NameError'
> > > > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> > > > > undefined
> > > > >  reference to `_imp__PyType_Type'
> > > > >
> > > > > E:\install\swigwin-1.3.29\Examples\python\simple>
> > > > >
> > > > >
> > > > > Jay
> > > > >
> > > >
> > > > _______________________________________________
> > > > python-chinese
> > > > Post: send python-chinese at lists.python.cn
> > > > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > > > Unsubscribe: send unsubscribe to
> > > > python-chinese-request at lists.python.cn
> > > > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > 欢迎访问:
> > > > http://blog.csdn.net/ccat
> > > >
> > > > 刘鑫
> > > > March.Liu
> > > >
> > > > _______________________________________________
> > > > python-chinese
> > > > Post: send python-chinese at lists.python.cn
> > > > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > > > Unsubscribe: send unsubscribe to
> > > > python-chinese-request at lists.python.cn
> > > > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> > > >
> > > >
> > >
> > > _______________________________________________
> > > python-chinese
> > > Post: send python-chinese at lists.python.cn
> > > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > > Unsubscribe: send unsubscribe to
> > > python-chinese-request at lists.python.cn
> > > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> > >
> > >
> >
> >
> > --
> > 欢迎访问:
> > http://blog.csdn.net/ccat
> >
> > 刘鑫
> > March.Liu
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
欢迎访问:
http://blog.csdn.net/ccat

刘鑫
March.Liu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/82d04afc/attachment-0001.html

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年04月29日 星期六 17:46

Gerald Lee leejd80 at gmail.com
Sat Apr 29 17:46:12 HKT 2006

VC的lib是COFF的,其它是标准的OMF的。

在06-4-29,imcs ee <imcsee at gmail.com> 写道:
>
> 请教个和这个相关的问题,一直不太明白。就是VC7.1和mingw之间"混用"会带来什么问题呢,我安装的python上下载的二进制的,应该是VC7.1编译的,而自己也下载过一些包含c/cpp源文件的python模块,是用mingw+swig编译的,看了一些讨论,好像这样两者会有些问题,好像是两者用的msvcrt不是同一个文件,而且更糟糕的是,虽然vs2005出来,又是不同的文件了,而python2.4/2.5官方版本都用vs2003编译。
>
>
> 不太清楚具体的情况,可能上面好多自己理解错误,哪位给介绍下,一般情况下用mingw编译模块有什么问题么,(mingw主要是linux和win下面比较方便移植了吧)
> 另外,如果上面这个mingw有些缺陷的话,哪儿有些用Visual Studio .NET
> 2003来作模块的例子么,找了一下,都是提供用微软free的tookit来编译,连着还不太一样吧。
>
>
> On 4/29/06, 刘鑫 <march.liu at gmail.com> wrote:
> >
> > Window平台的Python2.4是用VC7.1编译的,想要用MinGW来调用,必须自己编译一份Python24.lib
> >
> >  在06-4-29,Jay < wz12 at yeah.net> 写道:
> >
> > >  大家好。
> > > 我本来安装有bcb5, 编译的时候感觉问题很多;知道borland的二进制格式和MS的不同,可能麻烦很多;于是放弃理想:-)
> > > 我没有VC,安装了Dev-C++,采用它的gcc
> > >
> > > 编译的时候有下面的的错误; 从错误情况看,编译是没有问题的;问题是链接的时候找不到
> > > 一些函数的出处。
> > >
> > > 在次请教各位,该怎么办
> > >
> > >
> > > E:\install\swigwin-1.3.29\Examples\python\simple>gcc -D__WIN32__ -fPIC
> > > -shared e
> > > xample.c example_wrap.c -o example.dll -Id:\p\python24\include
> > > -LD:\P\python24\l
> > > ibs -lpython24 -lpyexpat -lselect
> > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > independent)
> > > cc1.exe: warning: -fPIC ignored for target (all code is position
> > > independent)
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9a9):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_MemoryError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9b8):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_IOError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9c4):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9d0):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_IndexError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9dc):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9e8):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_ZeroDivisionError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x9f4):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_OverflowError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa00):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SyntaxError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa0c):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_ValueError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa18):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SystemError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa24):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_AttributeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xa30):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xb23):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_RuntimeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xbe8):example_wrap.c:
> > > undefined
> > > reference to `_imp___Py_NoneStruct'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc21):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyList_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xc2c):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyList_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdbb):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xddf):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyTuple_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xdea):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyTuple_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe0b):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_SystemError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xe65):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xeb6):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0xfac):example_wrap.c:
> > > undefined
> > > reference to `_imp__PyClass_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1aa9):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x1ea5):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2020):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInstance_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ac):example_wrap.c:
> > > undefined
> > >  reference to `_imp___PyWeakref_ProxyType'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x20ba):example_wrap.c:
> > > undefined
> > >  reference to `_imp___PyWeakref_CallableProxyType'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2446):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyCFunction_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e02):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e20):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e66):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2e81):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_TypeError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2edc):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyFloat_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2ee7):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyFloat_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f30):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f3b):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f89):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x2f94):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x300c):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3017):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyInt_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x305f):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x306a):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyLong_Type'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x38dd):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_NameError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3962):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyExc_NameError'
> > > C:\DOCUME~1\Jay\LOCALS~1\Temp/ccgxcaaa.o(.text+0x3a2a):example_wrap.c:
> > > undefined
> > >  reference to `_imp__PyType_Type'
> > >
> > > E:\install\swigwin-1.3.29\Examples\python\simple>
> > >
> > >
> > > Jay
> > >
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to
> > python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
> >
> >
> > --
> > 欢迎访问:
> > http://blog.csdn.net/ccat
> >
> > 刘鑫
> > March.Liu
> >
> > _______________________________________________
> > python-chinese
> > Post: send python-chinese at lists.python.cn
> > Subscribe: send subscribe to python-chinese-request at lists.python.cn
> > Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> > Detail Info: http://python.cn/mailman/listinfo/python-chinese
> >
> >
>
> _______________________________________________
> python-chinese
> Post: send python-chinese at lists.python.cn
> Subscribe: send subscribe to python-chinese-request at lists.python.cn
> Unsubscribe: send unsubscribe to  python-chinese-request at lists.python.cn
> Detail Info: http://python.cn/mailman/listinfo/python-chinese
>
>


--
My Blog >> http://leejd.cndev.org
My QQ >> 9847243
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.exoweb.net/pipermail/python-chinese/attachments/20060429/ec2fe842/attachment-0001.htm

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

如下红色区域有误,请重新填写。

    你的回复:

    请 登录 后回复。还没有在Zeuux哲思注册吗?现在 注册 !

    Zeuux © 2025

    京ICP备05028076号