Re: [gtk-list] Re: static link w/gtk




On Tue, 24 Nov 1998 16:56:57 -0500 (EST)
	jgarzik@pobox.com(Jeff Garzik)  said:
jgarzik> Matt Rosencrantz wrote:
> but, how do you set the compiler flags to link some libs statically and
> some libs dynamically?

jgarzik> For the libs you specific want static, or specifically dynamic,
jgarzik> reference the full lib pathname.

jgarzik> 	gcc -o foo foo.o /usr/lib/libglib.a /usr/lib/libgtk+.a


I think it will be work at gcc/gnu ld:

 $ gcc -o foo foo.o -Wl,-Bstatic -lgtk -lgdk -lglib \
               -Wl,-Bdynamic -lXext -lX11 -lm

--
Mitsuru Oka
95i44@is.kochi-u.ac.jp



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]