FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Linking problem

 
Post new topic   Reply to topic     Forum Index -> QtD
View previous topic :: View next topic  
Author Message
stanleyxu2005



Joined: 20 Jul 2009
Posts: 3

PostPosted: Thu Oct 29, 2009 1:25 pm    Post subject: Linking problem Reply with quote

Hi All,

I have almost built the first demo, but ...
The components I have are as follows:
1. QtK SDK (LGPL edition) 4.5.3
2. the latest svn version of QtD (trunk-r309.zip)
3. DMD 1.050
4. Tango (current from trunk)
5. Platform: openSUSE 11.1.
6. cmake 2.6

After QtD was built successfully, I try to compile the demo (http://www.dsource.org/projects/qtd/wiki/MacCaseStudy)

I got many linking errors:
Code:
../../../../build_dir/build/lib/libqtdgui.a(QPrintDialog_shell.cpp.o): In function `qtd_QPrintDialog_setOption_PrintDialogOption_bool':
QPrintDialog_shell.cpp:(.text+0x20b): undefined reference to `QPrintDialog::setOption(QAbstractPrintDialog::PrintDialogOption, bool)'
../../../../build_dir/build/lib/libqtdgui.a(QPrintDialog_shell.cpp.o): In function `qtd_QPrintDialog_options':
QPrintDialog_shell.cpp:(.text+0x22b): undefined reference to `QPrintDialog::options() const'


There are many undefined references. I checked the source and the '.a' files. These functions are defined correctly.

Have I still forget something by linking the demo or building the library?

Any hint is welcome Cool
_________________
[http://stanleyxu2005.blogspot.com/ blog: stanleyxu's area51][[br]]
[http://gosurfbrowser.com project: gosurf webbrowser]
Back to top
View user's profile Send private message
stanleyxu2005



Joined: 20 Jul 2009
Posts: 3

PostPosted: Fri Oct 30, 2009 8:30 am    Post subject: Reply with quote

I have solve the problem by myself. Cool Cool Cool

There are two set of libQtXXXX in my Linux system.
  • A copy of Qt 4.4.3 (from my Linux installation) at "/usr/lib"
  • A copy of Qt 4.5.3 SDK at "/qt_sdk/lib"

Even when I try the command
Code:
dmd main.d -I/myinc -L-L/qt_sdk/lib -L-lQtCore -L-lqtcore

It searchs into "/usr/lib" for "libQtCore.so" at first.

I renamed "libQtCore.so" to "libQtCoreSDK.so", the problem was solved.

I hope this helps some other guys as well. Have fun with QtD.
_________________
[http://stanleyxu2005.blogspot.com/ blog: stanleyxu's area51][[br]]
[http://gosurfbrowser.com project: gosurf webbrowser]
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> QtD All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group