Build fails on msvc2005



  • Hi all,
    I've configured with
    @configure -debug-and-release -no-qt3support -no-webkit@
    i've tried various build options but even
    @nmake sub-src@
    gives me

    @
    cl -c -nologo -Zm200 -Zc:wchar_t- -Zi -MDd -GR -EHsc -W3 -w34100 -w34189 -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_PLUGIN -DQT_GU
    I_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"........\include\QtCore" -I"........\include\QtGui" -I"........\include" -I"......\gui\image" -I
    "........\include\ActiveQt" -I"tmp\moc\debug_shared" -I"........\mkspecs\win32-msvc2005" -Fotmp\obj\debug_shared\ @D:\Temp\nm7F5.tmp
    qtiffhandler.cpp
    ......\gui\image\qtiffhandler.cpp(55) : error C2440: 'static_cast' : cannot convert from 'thandle_t' to 'QTiffHandler *'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(55) : error C2227: left of '->device' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(61) : error C2440: 'static_cast' : cannot convert from 'thandle_t' to 'QTiffHandler *'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(61) : error C2227: left of '->device' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(61) : error C2227: left of '->write' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(66) : error C2440: 'static_cast' : cannot convert from 'thandle_t' to 'QTiffHandler *'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(66) : error C2227: left of '->device' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(89) : error C2440: 'static_cast' : cannot convert from 'thandle_t' to 'QTiffHandler *'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(89) : error C2227: left of '->device' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(89) : error C2227: left of '->size' must point to class/struct/union/generic type
    ......\gui\image\qtiffhandler.cpp(180) : error C2664: 'TIFFClientOpen' : cannot convert parameter 3 from 'QTiffHandler *const ' to 'thandle_t'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(409) : error C2664: 'TIFFClientOpen' : cannot convert parameter 3 from 'QTiffHandler *const ' to 'thandle_t'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    ......\gui\image\qtiffhandler.cpp(603) : error C2664: 'TIFFClientOpen' : cannot convert parameter 3 from 'QTiffHandler *' to 'thandle_t'
    Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
    NMAKE : fatal error U1077: '"D:\Program Files\Microsoft Visual Studio 8\VC\BIN\cl.EXE"' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: '"D:\Program Files\Microsoft Visual Studio 8\VC\BIN\nmake.exe"' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: 'cd' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: 'cd' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: 'cd' : return code '0x2'
    Stop.
    @
    (sorry code tags aren't working thanks to "at" symbol in output above)

    Any thoughts?

    [EDIT: code tags for output (escpape @-char with @, Volker]



  • Have you installed VS2005 SP1? Most of the issues will be resolved by using the latest updates.



  • Hi,

    Sorry for the delay. Just reinstalled sp1 to make sure, reconfigured again and rebuilt. Same problem. So yep, I have SP1 but still no dice.



  • Do you have your own copy of libtifff installed? Seems as if some of the headers leak in from outside Qt, where thandle_t is defined different.



  • it does look like that, doesn't it. I might try altering the Makefiles to output the include path and see how I get on. Thanks for the idea!



  • hmmm GTK 2.0 has a tiffio.h which could have been picked up.
    I've deleted this and am now rebuilding...
    ....now it can't find tiffio.h!
    I guess I have to reconfigure..in the meantime, any suggestions most welcome!



  • You will have to call configure again. Your build was configured to use the system libtiff, which now isn't available anymore.

    You should call

    @
    configure -qt-libtiff
    @

    to explicitly tell Qt to use its internal tiff library.



  • thanks, restarted configure with that option. i'll let you know how the build goes, but it sounds like this is the way forward



  • that was it, thanks! phew!



  • It must have been something like that since I never had problems building Qt itself with MSVS 2005 with and without SP1.

    And now have fun using Qt - the adventure starts right now :-)



  • [quote author="Volker" date="1295636423"]It must have been something like that since I never had problems building Qt itself with MSVS 2005 with and without SP1.

    And now have fun using Qt - the adventure starts right now :-)[/quote]

    I have built Qt once on msvc2005 and it was almost a mess (but was the old 4.2/3 which had to be patched). Then with 2008 everything went fine :-p. Still too long to build however



  • [quote author="Mattias Cibien" date="1295642172"]
    I have built Qt once on msvc2005 and it was almost a mess (but was the old 4.2/3 which had to be patched). Then with 2008 everything went fine :-p. Still too long to build however[/quote]

    I never had problems with this combination. No error, no patch. Strange. But fortunately I can use the prebuilt binaries nowadays. The most annoying thing was the compile time - no "make -j8" ... it took ages.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.