Re: How to static link a program?
- From: stian nixia no
- To: Jean Br�fort <jean brefort normalesup org>
- Cc: gtk-list <gtk-list gnome org>
- Subject: Re: How to static link a program?
- Date: Sun, 6 Feb 2005 10:50:17 +0100 (CET)
> I tried on one of my projects, and the only static libraries are those
> compiled inside the project.
> It seems that those flags are intended for libraries production. To have
> static linking of the libraries in the executable, you must probably
> list the libraires in the LDFLAGS, i.e. /usr/lib/libglib.a instead of
> -lglib, which will need some editing in Makefile.am.
Correct, the configure flags are to determine if you want to make static
and/or dynamic/shared libraries.
If you add -shared or -dynamic, you make gcc/ld have a preferred choice if
it finds both shared and dynamic libraries. -shared is the default.
Stian
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]