View previous topic :: View next topic |
Author |
Message |
sheridan
Joined: 11 Jul 2008 Posts: 9
|
Posted: Mon Feb 15, 2010 12:48 pm Post subject: linking gtkD on Win and Linux |
|
|
Hi!
I am new in gtkD programming, and would like to make a cross-platform GUI application with gtkD. I successfully compiled gtkD with dsss, but I got linker errors both on Linux and Windows when I would like to compile a simple demo inCode::Blocks.
Is it possibble to build gtkD based application using Code::Blocks? I got the following libs (Win):
DD-atk.lib
DD-cairo.lib
DD-gdk.lib
DD-gdkpixbuf.lib
DD-gio.lib
DD-glade.lib
DD-glib.lib
DD-gobject.lib
DD-gthread.lib
DD-gtk.lib
DD-gtkc.lib
DD-pango.lib
I added them to Code::Blocks, but the following hello word application always has linker errors:
Code: | import gtk.MainWindow;
import gtk.Label;
import gtk.Main;
void main(string[] args)
{
}
|
The errors:
Code: | Symbol Undefined _D3gtk4Main12__ModuleInfoZ|
Symbol Undefined _D3gtk5Label12__ModuleInfoZ|
Symbol Undefined _D3gtk10MainWindow12__ModuleInfoZ| |
I do not understand, what can be the problem. Please help me to solve this. |
|
Back to top |
|
|
Mike Wey
Joined: 07 May 2007 Posts: 428
|
Posted: Mon Feb 15, 2010 1:18 pm Post subject: |
|
|
Is phobos in the list of libraries? |
|
Back to top |
|
|
sheridan
Joined: 11 Jul 2008 Posts: 9
|
Posted: Mon Feb 15, 2010 1:26 pm Post subject: |
|
|
Phobos do need to add at the project link options. I had compiled a lot of projects already using this configuration.
The problem is the same on Linux and Windows. I think the problem is that the libs are build with dsss, but I use Code::Blocks. But I like this IDE, I do not want to use dsss to build my project.
Do I need maybe only one compact library. eg.: libgtkD.a??? If yes, how can I build it? |
|
Back to top |
|
|
GG
Joined: 05 Nov 2009 Posts: 18
|
Posted: Tue Feb 16, 2010 11:28 am Post subject: |
|
|
I have never use Code::Blocks but if you want only one compact library GtkD.lib:
For Windows follow this http://dsource.org/forums/viewtopic.php?t=5129
For Linux, use make: there is GNUmakefile in gtkD folder.
You will get libgtkd.a, libgtkdgl.a, libgtkdsv.a, then maybe you can link them to Code::Block |
|
Back to top |
|
|
Epileg
Joined: 10 Sep 2009 Posts: 77
|
|
Back to top |
|
|
|