problem in gtk programming

dark0s Optik shiftcoder at gmail.com
Mon Oct 27 10:55:16 PDT 2008


Ok

in tcsh gcc `pkg-config gtk+-2.0 --libs --cflags` -o prova prova.c works

and

in bash gcc $(pkg-config gtk+-2.0 --libs --cflags) -o prova prova.c works

Thank you very much!
savio

2008/10/27, Ulrich Spoerlein <uspoerlein at gmail.com>:
> On Sun, 26.10.2008 at 21:21:22 +0100, dark0s Optik wrote:
>> #pkg-config --libs --cflags gtk+-2.0
>> -I/usr/pkg/include/gtk-2.0 -I/usr/pkg/lib/gtk-2.0/include
>> -I/usr/pkg/include/atk-1.0 -I/usr/pkg/include/cairo
>> -I/usr/pkg/include/pango-1.0 -I/usr/pkg/include/glib/glib-2.0
>> -I/usr/pkg/lib/glib-2.0/include -I/usr/pkg/include/freetype2
>> -I/usr/pkg/include -I/usr/pkg/include/libpng12
>> -I/usr/pkg/include/pixman-1  -Wl,-R/usr/pkg/lib -L/usr/pkg/lib
>> -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0
>> -lpangocairo-1.0 -lpango-1.0 -lcairo -lgobject-2.0 -lgmodule-2.0
>> -lglib-2.0 -lintl
>>
>> I must include all above librarries and path in gcc command, how can I
>> run gcc with pkg-config as
>> gcc 'pkg-config gtk+-2.0 --libs --cflags ....
>
> Use backticks like this:
>
>> gcc `pkg-config gtk+-2.0 --libs --cflags` ....
>
> `` is totally different to '' or ""
>
> Cheers,
> Ulrich Spoerlein
> --
> It is better to remain silent and be thought a fool,
> than to speak, and remove all doubt.
>


-- 
only the paranoid will survive





More information about the Users mailing list