Bug 217285 - fails to build - multiple declarations
Summary: fails to build - multiple declarations
Status: RESOLVED FIXED
Alias: None
Product: kstars
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Solaris
: NOR normal
Target Milestone: ---
Assignee: Akarsh Simha
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-04 02:12 UTC by tropikhajma
Modified: 2010-04-24 17:12 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
patch (734 bytes, patch)
2010-04-18 01:10 UTC, tropikhajma
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tropikhajma 2009-12-04 02:12:32 UTC
Version:           4.3.77 (using Devel)
Compiler:          Sun Studio 12 U1 
OS:                Solaris
Installed from:    Compiled sources

building kdeedu fails with
...
cd /export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/build-kdeedu-4.3.77svn1053190/kstars/kstars && /home/hajma/Downloads/Su
nStudio12u1-SunOS-x86-tar-ML/sunstudio12.1/bin/CC  -library=no%Cstd -library=Crun -xannotate=no  -DQT_NO_STL -DQT_NO_CAST_TO_ASCII -D_REENTRA
NT -DKDE_DEPRECATED_WARNINGS -DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS -D__EXTENSIONS__ -DSOLARIS -D_REENTRANT -D__EXTENSIONS__ -D_LARGEFILE_SOURC
E -D_FILE_OFFSET_BITS=64 -D_POSIX_PTHREAD_SEMANTICS -DSOLARIS -DSOLARIS10 -DNDEBUG -DNO_DEBUG -D_UNICODE -DUNICODE -D_RWSTD_REENTRANT  -D_XOP
EN_SOURCE=500 -D_XPG5  -I/usr/include/stdcxx4/ansi -I/usr/include/stdcxx4 -I/opt/foss/include -I/usr/include/stdcxx4/ansi -I/usr/include/stdc
xx4 -library=no%Cstd -library=Crun -features=anachronisms,except,rtti,export,extensions,nestedaccess,tmplife,tmplrefstatic -instances=global
-template=geninlinefuncs -s -xlang=c99 -xalias_level=compatible -xustr=ascii_utf16_ushort -Qoption ccfe -features=gcc -Qoption ccfe -features
=zla -Qoption ccfe ++boolflag:sunwcch=false -mt -xF=%none -xbuiltin=%all -xinline=%auto -xprefetch=auto -xprefetch_auto_type=indirect_array_a
ccess -xprefetch_level=3 -xalias_level=compatible -KPIC -xipo=0 -xO3 -xregs=no%frameptr -xjobs=2 -xrestrict=%all -xthreadvar=%all -z combrelo
c -z redlocsym -z nodefaultlib -z ignore -z now -z rescan -z absexec -xldscope=symbolic -xlibmil -s -xtarget=pentium4 -m32 -xarch=sse2 -xchip
=pentium4 -xcache=8/64/4:256/128/8 -lc -lm -ldl -lpthread -lposix4 -lrt -mt -L/opt/foss/lib -R/opt/foss/lib -L/usr/lib -R/usr/lib -Y P,/opt/f
oss/lib -i -L/opt/foss/lib -R/opt/foss/lib -L/usr/lib -R/usr/lib -Bdynamic -lstdcxx4 -lCrun -lc -lm -xannotate=no -Usun   -DQT_NO_DEBUG -I/ex
port/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/build-kdeedu-4.3.77svn1053190/kstars/kstars -I/export/home/test/packages/BUILD/kdeedu-4
.3.77svn1053190/kstars/kstars -I/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190 -I/export/home/test/packages/BUILD/kdeedu-4.3.77svn1
053190/build-kdeedu-4.3.77svn1053190 -I/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/build-kdeedu-4.3.77svn1053190/kstars -I/expor
t/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/tools -I/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/ksta
rs/satlib -I/opt/kde4/include -I/opt/kde4/include/KDE -I/opt/foss/include/KDE -I/opt/foss/include -I/opt/foss/qt4/include/QtScriptTools -I/op
t/foss/qt4/include/phonon -I/opt/foss/qt4/include/QtXmlPatterns -I/opt/foss/qt4/include/QtWebKit -I/opt/foss/qt4/include/QtHelp -I/opt/foss/q
t4/include/QtAssistant -I/opt/foss/qt4/include/QtDBus -I/opt/foss/qt4/include/QtTest -I/opt/foss/qt4/include/QtUiTools -I/opt/foss/qt4/includ
e/QtScript -I/opt/foss/qt4/include/QtSvg -I/opt/foss/qt4/include/QtXml -I/opt/foss/qt4/include/QtSql -I/opt/foss/qt4/include/QtOpenGL -I/opt/
foss/qt4/include/QtNetwork -I/opt/foss/qt4/include/QtDesigner -I/opt/foss/qt4/include/Qt3Support -I/opt/foss/qt4/include/QtGui -I/opt/foss/qt
4/include/QtCore -I/opt/foss/qt4/include/Qt -I/opt/foss/qt4/share/mkspecs/default -I/opt/foss/qt4/include -I/usr/X11/include    -D_LARGEFILE6
4_SOURCE -o CMakeFiles/kstars.dir/dialogs/fovdialog.o -c /export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/dialogs/fovdi
alog.cpp
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 133: Warning: d hides KDateTime::d.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 134: Warning: d hides KDateTime::d.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 135: Warning: d hides KDateTime::d.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 136: Warning: d hides KDateTime::d.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 137: Warning: d hides KDateTime::d.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/kstarsdatetime.h", line 138: Warning: d hides KDateTime::d.
pkgbuild: "/opt/foss/qt4/include/QtCore/qmetatype.h", line 200: Error: qt_metatype_id is not a member of QMetaTypeId<FOV*>.
pkgbuild: "/opt/foss/qt4/include/QtCore/qmetatype.h", line 210:     Where: While instantiating "static QMetaTypeId2<FOV*>::qt_metatype_id()".
pkgbuild: "/opt/foss/qt4/include/QtCore/qmetatype.h", line 210:     Where: Instantiated from qMetaTypeId<FOV*>(FOV**).
pkgbuild: "/opt/foss/qt4/include/QtCore/qvariant.h", line 571:     Where: Instantiated from qvariant_cast<FOV*>(const QVariant&).
pkgbuild: "/opt/foss/qt4/include/QtCore/qvariant.h", line 592:     Where: Instantiated from qVariantValue<FOV*>(const QVariant&).
pkgbuild: "/opt/foss/qt4/include/QtCore/qvariant.h", line 328:     Where: Instantiated from QVariant::value<FOV*>() const.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/dialogs/fovdialog.cpp", line 51:     Where: Instantiated from non-template code.
pkgbuild: "/export/home/test/packages/BUILD/kdeedu-4.3.77svn1053190/kstars/kstars/dialogs/fovdialog.cpp", line 62: Error: Multiple declaration for QMetaTypeId<FOV*>.
pkgbuild: 2 Error(s) and 6 Warning(s) detected.

I think it worked around 4.3.73
Comment 1 tropikhajma 2009-12-18 03:12:17 UTC
still broken in 4.3.80
Comment 2 Alexey Khudiakov 2009-12-18 12:23:44 UTC
I'm not sure what to do in this case.

> "/opt/foss/qt4/include/QtCore/qmetatype.h", line 200: Error:
> qt_metatype_id is not a member of QMetaTypeId<FOV*>.

This suggest that this could be compiler problem. Did you tried to make clean build of KStars. Sometimes it cures bizarre errors.

If this won't help I roll out some simple test case to check whether Qt's meta object work on your box.
Comment 3 tropikhajma 2010-04-18 01:10:31 UTC
Created attachment 42862 [details]
patch
Comment 4 Alexey Khudiakov 2010-04-24 17:12:38 UTC
SVN commit 1118375 by khudyakov:

Fix compilation under Sun Studio 12 U1 on OpenSolaris

Thanks to tropikhajma for testing and patch

BUG: 217285

 M  +5 -5      fovdialog.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1118375