RejectedSoftware Forums

Sign up

using glib

I use a C-libary which depend on glib.

I can see that I already got glib.d at
/usr/include/dmd/gtkd/gtkc/glib.d

Now how does I get vibe/dmd to link to it ?

Knud

Re: using glib

On Tue, 13 Nov 2012 10:53:14 -0600, Knud Sørensen
4tuu4k002@sneakemail.com wrote:

I use a C-libary which depend on glib.

I can see that I already got glib.d at
/usr/include/dmd/gtkd/gtkc/glib.d

Now how does I get vibe/dmd to link to it ?

Knud

Check out the Thread "Linking to C libraries"

It should have all of the information you need. If not, just ask.

Using Opera's revolutionary email client: http://www.opera.com/mail/

Re: using glib

On 2012-11-13 23:16, 1100110 wrote:

On Tue, 13 Nov 2012 10:53:14 -0600, Knud Sørensen
4tuu4k002@sneakemail.com wrote:

I use a C-libary which depend on glib.

I can see that I already got glib.d at
/usr/include/dmd/gtkd/gtkc/glib.d

Now how does I get vibe/dmd to link to it ?

Knud

Check out the Thread "Linking to C libraries"

It should have all of the information you need. If not, just ask.

I found this page helpfu.
http://developer.gnome.org/glib/stable/glib-compiling.html

running

pkg-config --libs glib-2.0

-lglib-2.0

I then used pragma(lib, "glib-2.0") and everything linked beautifully.

Knud