From d6c122f73bdb73f53e4ebf913e5c0e402860f429 Mon Sep 17 00:00:00 2001 From: David Daney Date: Wed, 8 Mar 2006 20:22:02 +0000 Subject: gcj.texi: Document -static-libgcj option. gcc/java/ 2006-03-08 David Daney * gcj.texi: Document -static-libgcj option. libjava/ 2006-03-08 David Daney * configure.ac (LD): Add AC_CHECK_TOOL for ld. (LD_START_STATIC_SPEC): New AC_SUBST, set with ld check. (LD_FINISH_STATIC_SPEC): Ditto * configure: Regenerated. * libgcj.spec.in: Wrap -lgcj in LD_START_STATIC_SPEC and LD_FINISH_STATIC_SPEC. From-SVN: r111847 --- gcc/java/gcj.texi | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'gcc/java/gcj.texi') diff --git a/gcc/java/gcj.texi b/gcc/java/gcj.texi index 84e0e16..84659a54 100644 --- a/gcc/java/gcj.texi +++ b/gcc/java/gcj.texi @@ -420,6 +420,20 @@ Create an application whose command-line processing is that of the @code{gij} command. This option is an alternative to using @code{--main}; you cannot use both. + +@item -static-libgcj +This option causes linking to be done against a static version of the +libgcj runtime library. This option is only available if +corresponding linker support exists. + +@strong{Caution:} Static linking of libgcj may cause essential parts +of libgcj to be omitted. Some parts of libgcj use reflection to load +classes at runtime. Since the linker does not see these references at +link time, it can omit the referred to classes. The result is usually +(but not always) a @code{ClassNotFoundException} being thrown at +runtime. Caution must be used when using this option. For more +details see: +@w{@uref{http://gcc.gnu.org/wiki/Statically%20linking%20libgcj}} @end table @node Code Generation -- cgit v1.1