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

installation problem

 
Post new topic   Reply to topic     Forum Index -> gtkD
View previous topic :: View next topic  
Author Message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Mon Jul 07, 2008 2:46 pm    Post subject: installation problem Reply with quote

I tried to install gtkD from svn and by the pre-release (9).

"dsss build && sudo dsss install" builds and installs the libs but the source files (e.g. GtkD.d) aren't copied (I've searched /usr/*).
Any idea what could have gone wrong?

When I compile my own program (makefile, also includes /usr/include/d)
Code:
main.d(8): module GtkD cannot read file 'gtk/GtkD.d'
make: *** [main] Error 1
Back to top
View user's profile Send private message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Mon Jul 07, 2008 2:47 pm    Post subject: Reply with quote

Btw., /usr/local/include/d doesn't exist.
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Mon Jul 07, 2008 3:52 pm    Post subject: Reply with quote

Can you see in the output of dsss installl where it's copying the file to ?
Back to top
View user's profile Send private message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Mon Jul 07, 2008 6:59 pm    Post subject: Reply with quote

Here is the complete output of dsss install:

http://rafb.net/p/SrJ0kk58.html
Back to top
View user's profile Send private message
okibi



Joined: 04 Jan 2007
Posts: 170

PostPosted: Tue Jul 08, 2008 11:05 am    Post subject: Reply with quote

I wasn't aware that dsss copied the source files anywhere, merely created the di files and libs and moved them where they need to be.

(sorry, I still use compd...)

Could you not just add the path to the gtkd src files when you compile your program?

Also, gtk/GtkD.d isn't used anymore and will not be included in RC1.
Back to top
View user's profile Send private message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Tue Jul 08, 2008 11:19 am    Post subject: Reply with quote

Solved.

I included the gtkD source path, removed gtk.GtkD from the imports
and changed stuff like GtkD.init(args); to Main.init(args); to get my app compiled.

I didn't expected this to get changed. (Is it even mentioned somewhere?)
Anyway, DSSS doesn't seem to copy the sources at all.
Back to top
View user's profile Send private message
okibi



Joined: 04 Jan 2007
Posts: 170

PostPosted: Tue Jul 08, 2008 1:57 pm    Post subject: Reply with quote

Your welcome! Smile

GtkD was renamed to Main in Pre-release 9. This was actually not displayed anywhere except in the code examples. I will update the wiki immediately.

(note: I thought I left GtkD.d in pre9 just for this reason...)
Back to top
View user's profile Send private message
radon7



Joined: 23 Nov 2009
Posts: 3

PostPosted: Mon Nov 23, 2009 2:17 pm    Post subject: compile problems Reply with quote

I am using Debian lenny and when I try to compile a program that just makes a window basically I get the following-

window.d:1: module MainWindow cannot read file 'gtk/MainWindow.d'

Is this because I don't have the files in a certain path that gdc uses for source files or is there something I am missing somewhere else.
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Mon Nov 23, 2009 2:33 pm    Post subject: Reply with quote

If you are using DSSS it should take care of the file paths.

When using gdc directly you'll need to tell it where it can find the files.
Back to top
View user's profile Send private message
radon7



Joined: 23 Nov 2009
Posts: 3

PostPosted: Mon Nov 23, 2009 3:28 pm    Post subject: Reply with quote

How do I pass the paths to gdc directly. Using the -B option doesn't get me anywhere.
I am using the command gdc -B /path/to/files window.d -o window

creating a dsss.conf file as

name = window
[window.d]
target = window

then running dsss build gives the following output basically the same thing plus some

Default prefix /usr is unwritable, using /home/jaye/d instead.
window.d => window
window.d(1): module MainWindow cannot read file 'gtk/MainWindow.d'
Command /usr/bin/rebuild returned with code 256, aborting.
Error: Command failed, aborting.


I can look at the MainWindow.d file so I know it exists and on my disk.
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Tue Nov 24, 2009 3:11 pm    Post subject: Reply with quote

gdc -Ipath/to/files window.d -o window

Should do it, don't include the gtk directory in the path.

When using DSSS you'll need to build and install (dsss build && dsss install, from the directory that contains: src, srcgl) gtkD with DSSS before you can build gtkD apps with it.
Back to top
View user's profile Send private message
radon7



Joined: 23 Nov 2009
Posts: 3

PostPosted: Fri Nov 27, 2009 11:05 pm    Post subject: ARRRR Reply with quote

Thanks Mikey I got that figured out and now I have another problem. Running gdc now that it finds the files I get this output ---


gdc window.d -o window
/tmp/ccCuVTd6.o: In function `_Dmain':
window.d:(.text+0x1b): undefined reference to _D3gtk4Main4Main4initFAAaZv'
window.d:(.text+0x34): undefined reference to _D3gtk10MainWindow10MainWindow7__ClassZ'
window.d:(.text+0x4b): undefined reference to
window.d:(.text+0x92): undefined reference to _D3gtk5Label5Label7__ClassZ'
window.d:(.text+0xa8): undefined reference to _D3gtk5Label5Label5_ctorMFAabZC3gtk5Label5Label'
window.d:(.text+0xd5): undefined reference to _D3gtk4Main4Main3runFZv'
/tmp/ccCuVTd6.o:(.data+0x38): undefined reference to _D3gtk10MainWindow12__ModuleInfoZ'
/tmp/ccCuVTd6.o:(.data+0x3c): undefined reference to _D3gtk5Label12__ModuleInfoZ'
/tmp/ccCuVTd6.o:(.data+0x40): undefined reference to _D3gtk4Main12__ModuleInfoZ'
collect2: ld returned 1 exit status


Am I missing a library that should be installed or is something else going on here. I installed everything I new of from debians repositories.
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Sat Nov 28, 2009 6:47 am    Post subject: Reply with quote

You'll need to tell the linker to link with the GtkD library and libdl.

gdc -Ipath/to/files window.d -o window -L-ldl -L-lgtkd -L-L/path/to/folder/that/contains/the/gtkd/lib

If you haven't build the gtkd lib yet you can use the makefile that comes with gtkd to do so, just call make from the directory that contains the GNUmakefile. (I'm assuming you are not using DSSS)
Back to top
View user's profile Send private message
cutecub00
Guest





PostPosted: Fri Jan 29, 2010 6:05 am    Post subject: Reply with quote

I didn't get this topic..please tell me in detailed manner..thank you
Back to top
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Fri Jan 29, 2010 2:28 pm    Post subject: Reply with quote

And i don't get your question, if you could create a new topic with some details about your problem, we might have some more success.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> gtkD 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