Trolltech Home | Qt-jambi-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 1

Qt-jambi-interest Archive, December 2006
Generator Issues


Message 1 in thread

I have just downloaded the QtJambi Tech Preview 3 and am having problems running the
generator example.  I am running on Windows 2000 with J2SE that was the most recent
release(I think its version 5), with QT 4.2.2 .  

When I run the Generator example, the following is displayed on screen:

C:\Qt\qtjambi-win-1.0.0-tp3\generator_example>generator_example.bat
Running generator
Compiling Native library

Microsoft (R) Program Maintenance Utility   Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.


Microsoft (R) Program Maintenance Utility   Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.

NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'C:\PROGRA~1\MICROS~3\VC98\BIN\NMAKE.EXE' : return co
de '0x2'
Stop.
        NMAKE -f Makefile.Release
        c:\Qt\4.2.2\bin\moc.exe -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_QTJAMBI_IM
PORT -DQT_DLL -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"C:
/Qt/4.2.2/include/QtCore" -I"C:/Qt/4.2.2/include/QtCore" -I"C:/Qt/4.2.2/include/
QtGui" -I"C:/Qt/4.2.2/include/QtGui" -I"C:/Qt/4.2.2/include" -I"..\qtjambi" -I".
.\common" -I"..\include" -I"C:\Program Files\Java\jdk1.5.0_10\include" -I"C:\Pro
gram Files\Java\jdk1.5.0_10\include\win32" -I"C:/Qt/4.2.2/include/ActiveQt" -I"r
elease" -I"." -I"..\..\4.2.2\mkspecs\win32-msvc" -D_MSC_VER=1200 -DWIN32 ..\cpp\
com_trolltech_examples_generator\qtjambishell_MyWidget.h -o release\moc_qtjambis
hell_MyWidget.cpp
        cl -c -nologo -Zm200 -O1 -MD -O1 -MD -GR -GX -W3 -DUNICODE -DQT_LARGEFIL
E_SUPPORT -DQT_QTJAMBI_IMPORT -DQT_DLL -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB
-DQT_THREAD_SUPPORT -I"C:/Qt/4.2.2/include/QtCore" -I"C:/Qt/4.2.2/include/QtCore
" -I"C:/Qt/4.2.2/include/QtGui" -I"C:/Qt/4.2.2/include/QtGui" -I"C:/Qt/4.2.2/inc
lude" -I"..\qtjambi" -I"..\common" -I"..\include" -I"C:\Program Files\Java\jdk1.
5.0_10\include" -I"C:\Program Files\Java\jdk1.5.0_10\include\win32" -I"C:/Qt/4.2
.2/include/ActiveQt" -I"release" -I"." -I"..\..\4.2.2\mkspecs\win32-msvc" -Forel
ease\ @C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\nma01668.
metainfo.cpp
..\cpp\com_trolltech_examples_generator\metainfo.cpp(29) : error C2665: 'delete'
 : none of the 2 overloads can convert parameter 1 from type 'const class QBool
*'
qtjambi_libraryinitializer.cpp
qtjambishell_MyWidget.cpp
Generating Code...
C:\Qt\qtjambi-win-1.0.0-tp3\generator_example>

I've looked in the metainfo.cpp file, and the error appears to be in this function

static void qbool_delete(const QBool *copy)
{
    
    delete copy;
    
}


Is there anything special I have to do to get this work correctly?


Doug

--
 [ signature omitted ] 

Message 2 in thread

Douglas Orttenburger wrote:

>I have just downloaded the QtJambi Tech Preview 3 and am having problems running the
>generator example.  I am running on Windows 2000 with J2SE that was the most recent
>release(I think its version 5), with QT 4.2.2 .  
>
>When I run the Generator example, the following is displayed on screen:
>[...]
>metainfo.cpp
>..\cpp\com_trolltech_examples_generator\metainfo.cpp(29) : error C2665: 'delete'
> : none of the 2 overloads can convert parameter 1 from type 'const class QBool
>*'
>qtjambi_libraryinitializer.cpp
>  
>

Hi, Douglas.

Are you using VC 6.0? It could be an issue with that compiler, because I 
haven't seen that error message with VC7. We will definitely fix this 
for the next release of Qt Jambi.

Meanwhile, you can try using a work around to make the generator example 
compile. Add the following to the typesystem_mywidget.txt file:

    <primitive-type name="QBool" java-name="boolean" 
preferred-conversion="no" jni-name="bool" />
   
You will get a warning from the generator now,  telling you that you 
have  a duplicate type entry, but this new entry should override the 
buggy one, so the resulting code will hopefully compile.

-- Eskil