[Stackless] Error compiling PyQt

Carlos Eduardo de Paula carlosedp at gmail.com
Wed Oct 29 19:37:06 CET 2008


Hi Richard,

Thanks a lot for your help, I compiled PyQt successfully with the
change you suggested.

I don't understand the internals of Python very well but this types of
errors make me to study it deeper.

Carlos

On Mon, Oct 27, 2008 at 8:01 PM, Richard Tew <richard.m.tew at gmail.com> wrote:
> On Mon, Oct 27, 2008 at 2:25 PM, Carlos Eduardo de Paula
> <carlosedp at gmail.com> wrote:
>> Nope, same error... Stackless PyHeapTypeObject does not contain a
>> "type" slot because python standard PyTypeObject does not contain it
>> and stackless aliases one to another.
>
> Well, that snippet was obviously incorrect, I was hoping you would
> just follow the approach of adding a special case for Stackless to get
> something which works.
>
> Perhaps like:
>
> #if PY_VERSION_HEX >= 0x02050000 && !defined(STACKLESS)
>              int type = QMetaType::type(as->type.u.wt->super.ht_type.tp_name);
> #else
>              int type = QMetaType::type(as->type.u.wt->super.tp_name);
> #endif
>
> Cheers,
> Richard.
>
>>
>> Here is the error compiling it:
>>
>>        cl -c -nologo -Zm200 -Zc:wchar_t- -O2 -MD -W3 -w34100 -w34189
>> -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_NO_DEBUG
>> -DQT_CORE_LIB -I. -IC:\Carlos\Apps\Python26\include
>> -IC:\Qt\4.4.3\mkspecs\default -IC:\Qt\4.4.3\include\QtCore
>> -IC:\Qt\4.4.3\include -Fo @C:\DOCUME~1\cpaula\LOCALS~1\Temp\nm108.tmp
>> sipQtCorecmodule.cpp
>> sip/QtCore/qobject.sip(1318) : error C2039: 'type' : is not a member
>> of '_typeobject'
>>        c:\carlos\apps\python26\include\object.h(325) : see
>> declaration of '_typeobject'
>> sip/QtCore/qobject.sip(1318) : error C2228: left of '.tp_name' must
>> have class/struct/union
>> NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio
>> 9.0\VC\BIN\cl.EXE"' : return code '0x2'
>> Stop.
>> NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio
>> 9.0\VC\BIN\nmake.exe"' : return code '0x2'
>> Stop.
>>
>>
>> Carlos
>>
>>
>> On Fri, Oct 24, 2008 at 11:03 PM, Richard Tew <richard.m.tew at gmail.com> wrote:
>>> On Fri, Oct 24, 2008 at 8:30 PM, Carlos Eduardo <carlosedp at gmail.com> wrote:
>>>> Nope, this fix had already been made on SIP by its developer. Now PyQt has a problem similar to that but i dont know where the fix should be made.
>>>
>>> How about this?
>>>
>>> #if PY_VERSION_HEX >= 0x02050000 && !defined(STACKLESS)
>>>               int type = QMetaType::type(as->type.u.wt->super.ht_type.tp_name);
>>> #else
>>>               int type = QMetaType::type(as->type.u.wt->super.type.tp_name);
>>> #endif
>>>
>>> Cheers,
>>> Richard.
>>>
>>
>>
>>
>> --
>> -------------------------------------------------------------------
>> Visit Stackless Examples Project
>> http://code.google.com/p/stacklessexamples/
>> Stackless Python - www.stackless.com
>> -------------------------------------------------------------------
>>
>



-- 
-------------------------------------------------------------------
Visit Stackless Examples Project
http://code.google.com/p/stacklessexamples/
Stackless Python - www.stackless.com
-------------------------------------------------------------------




More information about the Stackless mailing list