Re: [taskjuggler] Compile Error with 1.4.1

From: Chris Schlaeger (cs_at_suse.de)
Date: Thu Mar 06 2003 - 13:07:11 CET


From: Chris Schlaeger <cs@suse.de>
Date: Thu, 6 Mar 2003 13:07:11 +0100
Message-Id: <200303061307.11309.cs@suse.de>
Subject: Re: [taskjuggler] Compile Error with 1.4.1

Hi Ernst,

On Thursday 06 March 2003 12:14, Ernst Pfann wrote:
> Hello all.
>
> I have just downloaded and tried to compile taskjuggler-1.4.1 on a SuSE 7.3
> system with KDE 3.1 from SuSEs KDE-RPMs. It would be nice, if someone can
> help me.
>
> I've got a compile error i do not understand (i'm not really familiar with
> C). Configure works well and told me, that i should be able to compile all
> (except Postscript Manual). The errormessage was:
>
> source='ReportHtml.cpp' object='ReportHtml.lo' libtool=yes \
> depfile='.deps/ReportHtml.Plo' tmpdepfile='.deps/ReportHtml.TPlo' \
> depmode=gcc /bin/sh ../admin/depcomp \
> /bin/sh ../libtool --silent --mode=compile --tag=CXX g++ -DHAVE_CONFIG_H
> -I. -I. -I.. -I/opt/kde3/include -I/opt/kde3/include -I/usr/lib/qt3/include
> -I/usr/X11R6/include -DQT_THREAD_SUPPORT -D_REENTRANT
> -Wnon-virtual-dtor -Wno-long-long -Wundef -Wall -pedantic -W
> -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -ansi
> -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -O2
> -fno-exceptions -fno-check-new -c -o ReportHtml.lo `test -f
> 'ReportHtml.cpp' || echo './'`ReportHtml.cpp ReportHtml.cpp: In method
> `void ReportHtml::generatePlanTask(const Task *, const Resource *, unsigned
> int)':
> ReportHtml.cpp:90: ambiguous overload for `bool ? const char[7] : QString'
> ReportHtml.cpp:90: candidates are: operator ?:(bool, QString, QString)
> <builtin>
> ReportHtml.cpp:90: operator ?:(bool, const char *, const
> char *) <builtin>

looks like the gcc 2.95 from SL7.3 has a bug with implicit type conversions.
But you can workaround this problem with an explicit cast. Either make the
second argument of ?: a QString as well (QString("&nbsp;") or cast the 3rd
argument to a const char*. ((const char*) time2user...).

> ReportHtml.cpp:93: ambiguous overload for `bool ? const char[7] : QString'
> ReportHtml.cpp:93: candidates are: operator ?:(bool, QString, QString)
> <builtin>
> ReportHtml.cpp:93: operator ?:(bool, const char *, const
> char *) <builtin>
> ReportHtml.cpp:96: ambiguous overload for `bool ? const char[7] : QString'
> ReportHtml.cpp:96: candidates are: operator ?:(bool, QString, QString)
> <builtin>
> ReportHtml.cpp:96: operator ?:(bool, const char *, const
> char *) <builtin>
> ReportHtml.cpp:99: ambiguous overload for `bool ? const char[7] : QString'
> ReportHtml.cpp:99: candidates are: operator ?:(bool, QString, QString)
> <builtin>
> ReportHtml.cpp:99: operator ?:(bool, const char *, const
> char *) <builtin>
> make[2]: *** [ReportHtml.lo] Error 1
> make[2]: Leaving directory `/usr/local/src/taskjuggler-1.4.1/taskjuggler'
>

The other errors are of the same type.

Chris

-- 
KDE 3.1: Conquer your Enterprise Desktop!  See http://www.kde.org!
GPG Key: 1024D/0500838B  A5FE C051 2AFC 9A14 768A  5125 5829 5750 0500 838B
-- 
To unsubscribe, email the address listed in the List-Unsubscribe header
For additional commands, email: taskjuggler-help@suse.com


This archive was generated by hypermail 2.1.7 : Thu Mar 06 2003 - 13:07:20 CET