You are not logged in.

Dear visitor, welcome to KDE-Forum.org. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Raniz

Beginner

  • "Raniz" started this thread

Posts: 2

Location: Sweden

  • Send private message

1

Monday, July 5th 2004, 5:46pm

Dcop implementation results in error

I've been trying to implement DCOP-support into Yammi, but sofar I haven't had any success.

I had some troubles but those were fixed by subclassing my DcopInterface after KMainWindow (I was told to do this on another forum).

But now a new problem has arisen. When I try to compile I get this error:

Quoted

/bin/sh ../libtool --silent --mode=link --tag=CXX g++ -Wnon-virtual-dtor -Wno-long-long -Wundef -Wall -W -Wpointer-arith -Wwrite-strings -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -Wchar-subscripts -O2 -Wformat-security -Wmissing-format-attribute -fno-exceptions -fno-check-new -fno-common -o yammi -R /usr/kde/3.2/lib -R /usr/qt/3/lib -R /usr/X11R6/lib -L/usr/X11R6/lib -L/usr/qt/3/lib -L/usr/kde/3.2/lib main.o artsplayer.o CFrameHeader.o CMP3Info.o ConsistencyCheckDialog.o CVBitRate.o foldercategories.o folder.o foldergroups.o foldermedia.o foldersorted.o fuzzsrch.o lineeditshift.o mediaplayer.o mp3_layer.o mydatetime.o mylist.o mylistview.o noatunplayer.o preferencesdialog.o prefs.o song.o songentry.o songentryint2.o songentryint.o songentrystring.o songentrytimestamp.o songinfo.o songlistitem.o updatedatabasedialog.o updatedatabasemediadialog.o xmmsplayer.o yammigui.o yammimodel.o vcedit.o ConsistencyCheckParameter.o applytoalldialog.o trackpositionslider.o util.o searchthread.o ApplyToAllBase.o ConsistencyCheckDialogBase.o DeleteDialog.o PreferencesDialogBase.o SongInfoDialog.o UpdateDatabaseDialogBase.o UpdateDatabaseMediaDialogBase.o mediaplayer.moc.o foldergroups.moc.o yammigui.moc.o lineeditshift.moc.o trackpositionslider.moc.o artsplayer.moc.o songinfo.moc.o folder.moc.o foldercategories.moc.o updatedatabasedialog.moc.o dummyplayer.moc.o mylistview.moc.o updatedatabasemediadialog.moc.o applytoalldialog.moc.o yammimodel.moc.o preferencesdialog.moc.o xmmsplayer.moc.o foldermedia.moc.o noatunplayer.moc.o ConsistencyCheckDialog.moc.o -lartskde -lkdeui -L/usr/lib -L/usr/X11R6/lib -lgtk -lgdk -rdynamic -lgmodule -lglib -ldl -lXi -lXext -lX11 -lm -lxmms -lid3 -lz -lvorbisfile -lvorbis -logg -lstdc++
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x36c): undefined reference to `YammiDcopIface::process(QCString const&, QMemArray<char> const&, QCString&, QMemArray<char>&)'
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x370): undefined reference to `YammiDcopIface::functions()'
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x374): undefined reference to `YammiDcopIface::interfaces()'
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x3a8): undefined reference to `virtual thunk [v:0,-16] to YammiDcopIface::process(QCString const&, QMemArray<char> const&, QCString&, QMemArray<char>&)'
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x3b8): undefined reference to `virtual thunk [v:0,-32] to YammiDcopIface::interfaces()'
*yammigui.moc.o(.gnu.linkonce.r._ZTV8YammiGui+0x3bc): undefined reference to `virtual thunk [v:0,-36] to YammiDcopIface::functions()'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x18): undefined reference to `typeinfo for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x24): undefined reference to `YammiDcopIface::process(QCString const&, QMemArray<char> const&, QCString&, QMemArray<char>&)'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x28): undefined reference to `YammiDcopIface::functions()'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x2c): undefined reference to `YammiDcopIface::interfaces()'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x54): undefined reference to `typeinfo for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x60): undefined reference to `virtual thunk [v:0,-16] to YammiDcopIface::process(QCString const&, QMemArray<char> const&, QCString&, QMemArray<char>&)'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x70): undefined reference to `virtual thunk [v:0,-32] to YammiDcopIface::interfaces()'
*yammigui.moc.o(.gnu.linkonce.r._ZTC8YammiGui1240_14YammiDcopIface+0x74): undefined reference to `virtual thunk [v:0,-36] to YammiDcopIface::functions()'
*yammigui.moc.o(.gnu.linkonce.t._ZN14YammiDcopIfaceD1Ev+0xb): In function `YammiDcopIface::~YammiDcopIface [in-charge]()':
*: undefined reference to `vtable for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.t._ZN14YammiDcopIfaceD1Ev+0x12): In function `Ya
*mmiDcopIface::~YammiDcopIface [in-charge]()':
*: undefined reference to `vtable for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.t._ZN14YammiDcopIfaceD0Ev+0x11): In function `YammiDcopIface::~YammiDcopIface [in-charge deleting]()':
*: undefined reference to `vtable for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.t._ZN14YammiDcopIfaceD0Ev+0x18): In function `YammiDcopIface::~YammiDcopIface [in-charge deleting]()':
*: undefined reference to `vtable for YammiDcopIface'
*yammigui.moc.o(.gnu.linkonce.r._ZTI8YammiGui+0x18): undefined reference to `typeinfo for YammiDcopIface'
*collect2: ld returned 1 exit status
*gmake[3]: *** [yammi] Error 1
*gmake[3]: Target `all-am' not remade because of errors.
*gmake[2]: Nothing to be done for `all-am'.
*gmake[2]: *** [all-recursive] Error 1
*gmake[2]: Target `all' not remade because of errors.
*gmake[1]: *** [all-recursive] Error 1
*gmake: *** [all] Error 2


This is the changes that I've made sofar:

Created an interface which inherits DCOPOBject:

Source code

1
2
3
4
5
6
7
class YammiDcopIface: virtual public DCOPObject {

	K_DCOP

	k_dcop:

};
Edited the YammiGui class so that it inherits YammiDcopIface AFTER KMainWindow and added a call to DCOPObject("YammiPlayer") BEFORE the call to KMainWindow() in the Constructor.

f_edemar

Beginner

Posts: 14

Location: Sweden

  • Send private message

2

Monday, July 5th 2004, 10:32pm

You must compile the program with yammidcopiface.skel:
add
yammidcopiface.skel
in the end of the line
yammi_SOURCES
in Makefile.am

This post has been edited 1 times, last edit by "f_edemar" (Jul 5th 2004, 10:34pm)


Raniz

Beginner

  • "Raniz" started this thread

Posts: 2

Location: Sweden

  • Send private message

3

Tuesday, July 6th 2004, 6:49pm

That did it.

Thanks!