Bug 194926

Summary: undefined symbol GlobalShortcut::setDefaultKeys when linking kglobaaccel
Product: [I don't know] kde Reporter: tropikhajma <tropikhajma>
Component: generalAssignee: Alexander Neundorf <neundorf>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Solaris   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description tropikhajma 2009-06-01 23:13:33 UTC
Version:           4.2.88 (using Devel)
Compiler:          Sun Studio 12 Update 1(beta) 
OS:                Solaris
Installed from:    Compiled sources

When building kdebase-runtime, it fails saying:
/usr/bin/gmake -f kglobalaccel/CMakeFiles/kglobalaccel.dir/build.make kglobalaccel/CMakeFiles/kglobalaccel.dir/build
gmake[3]: Entering directory `/export/home/test/packages/BUILD/kdebase-runtime-4.2.88svn973768/build-kdebase-runtime-4.2.88svn973768'
Linking CXX executable kglobalaccel
cd /export/home/test/packages/BUILD/kdebase-runtime-4.2.88svn973768/build-kdebase-runtime-4.2.88svn973768/kglobalaccel && /opt/dtbld/bin/cmake -E cmake_link_script CMakeFiles/kglobalaccel.dir/link.txt --verbose=1
pkgbuild: /usr/bin/CC  -library=no%Cstd  -D__EXTENSIONS__ -DSOLARIS -D_REENTRANT -D__EXTENSIONS__ -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_POSIX_PTHREAD_SEMANTICS -DSOLARIS -DSOLARIS10 -DNDEBUG -DNO_DEBUG -D_UNICODE -DUNICODE -D_RWSTD_REENTRANT  -D_XOPEN_SOURCE=500 -D_XPG5  -I/opt/foss/include/stdcxx/ansi -I/opt/foss/include/stdcxx -I/opt/foss/include -I/opt/foss/include/stdcxx/ansi -I/opt/foss/include/stdcxx -library=no%Cstd -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_access -xprefetch_level=3 -xalias_level=compatible -KPIC -xipo=0 -xO3 -xregs=no%frameptr -xjobs=2 -xrestrict=%all -xthreadvar=%all -z combreloc -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/foss/lib -i -L/opt/foss/lib -R/opt/foss/lib -L/usr/lib -R/usr/lib -Bdynamic -lstdcxx -lCrun -lc -lm   -DQT_NO_DEBUG  -KPIC -L/opt/foss/lib -R/opt/foss/lib  -lstdcxx -L/usr/lib -R/usr/lib -lxml2 -lCrun -lrt -lsocket -L/usr/X11/lib -R/usr/X11/lib CMakeFiles/kglobalaccel.dir/kglobalaccel_dummy.o  -o kglobalaccel  -L/export/home/test/packages/BUILD/kdebase-runtime-4.2.88svn973768/build-kdebase-runtime-4.2.88svn973768/lib -L/opt/kde-4.2/lib -L/opt/foss/qt4/lib -L/usr/X11/lib ../lib/libkdeinit4_kglobalaccel.so ../lib/libkdeinit4_kglobalaccel.so /opt/kde-4.2/lib/libkdeui.so.5.3.0 /opt/kde-4.2/lib/libkdecore.so.5.3.0 /opt/foss/qt4/lib/libQtDBus.so /opt/foss/qt4/lib/libQtCore.so -lthread /opt/foss/qt4/lib/libQtSvg.so /opt/foss/qt4/lib/libQtGui.so /usr/X11/lib/libSM.so /usr/X11/lib/libICE.so /usr/X11/lib/libX11.so /usr/X11/lib/libXext.so /usr/X11/lib/libXft.so /usr/X11/lib/libXau.so /usr/X11/lib/libXdmcp.so /usr/X11/lib/libXpm.so -R/export/home/test/packages/BUILD/kdebase-runtime-4.2.88svn973768/build-kdebase-runtime-4.2.88svn973768/lib:/opt/kde-4.2/lib:/opt/foss/qt4/lib:/usr/X11/lib
ld: warning: file ../lib/libkdeinit4_kglobalaccel.so: attempted multiple inclusion of file
Undefined                     first referenced
symbol                           in file
void GlobalShortcut::setDefaultKeys(QList<int>) ../lib/libkdeinit4_kglobalaccel.so
void GlobalShortcut::setKeys(QList<int>) ../lib/libkdeinit4_kglobalaccel.so
ld: fatal: symbol referencing errors. No output written to kglobalaccel

This is on 32bit opensolaris build 111a, using SunStudio12U1(beta)
Comment 1 tropikhajma 2009-06-02 18:37:04 UTC
note I was able to build 4.2.3 using the same settings just fine.
I tried the older packages in /unstable, but I even got the same problem with 4.2.70
Comment 2 tropikhajma 2009-06-05 22:09:27 UTC
same with 4.2.89

this bug practically blocks me from building anything else from kde
Comment 3 tropikhajma 2009-06-05 23:48:51 UTC
this patch seems to fix it:

--- kglobalaccel/globalshortcut.h.orig  2009-06-05 12:46:41.734681435 +0200
+++ kglobalaccel/globalshortcut.h       2009-06-05 12:47:11.263360912 +0200
@@ -74,7 +74,7 @@
     void setActive();

     //! Sets the default keys for this shortcut.
-    void setDefaultKeys(QList<int>);
+    void setDefaultKeys(const QList<int>);

     //! Sets the friendly name for the shortcut. For display.
     void setFriendlyName(const QString &);
@@ -86,7 +86,7 @@
     void setIsFresh(bool);

     //! Sets the keys activated with this shortcut. The old keys are freed.
-    void setKeys(QList<int>);
+    void setKeys(const QList<int>);

     //! Returns the unique name aka id for the shortcuts.
     QString uniqueName() const;
Comment 4 Alexander Neundorf 2009-06-15 19:08:56 UTC
That's a problem in the C++ code, not in the buildsystem, so I reassigned to something else. Unfortunately I didn't find anything better matchign than "kde" :-/

Alex
Comment 5 groot 2009-06-15 22:46:13 UTC
SVN commit 982426 by adridg:

Const-matching in globalshortcut.h
- this doesn't seem to be an installed header, otherwise need to change the cpp file instead
- would passing QList& be better?

BUG: 194926


 M  +2 -2      globalshortcut.h  


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