public inbox for java-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Fix linking with -findirect-dispatch
@ 2013-04-16  8:36 Andreas Schwab
  2013-04-16  8:39 ` Jakub Jelinek
  0 siblings, 1 reply; 21+ messages in thread
From: Andreas Schwab @ 2013-04-16  8:36 UTC (permalink / raw)
  To: java-patches; +Cc: gcc-patches

Linking with -findirect-dispatch fails with this error:

x86_64-linux-gcj -o ecjx -findirect-dispatch --main=org.eclipse.jdt.internal.compiler.batch.GCCMain ../../../gcc/libjava/../ecj.jar ecjx.o  
/usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: /tmp/ccppO92n.o: undefined reference to symbol '_Jv_MonitorExit'
/usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: note: '_Jv_MonitorExit' is defined in DSO /usr/lib64/libgcj.so.13 so try adding it to the linker command line

Andreas.

	* configure.ac (LIBGCJ_SPEC_LGCJ_BC): Append -lgcj.
	(libgcj_spec_lgcj_bc_override): Likewise.
	* configure: Regenerate.

diff --git a/libjava/configure.ac b/libjava/configure.ac
index ba6b363..d378125 100644
--- a/libjava/configure.ac
+++ b/libjava/configure.ac
@@ -266,7 +266,7 @@ if test "$enable_libgcj_sublibs" = yes ; then
   # words in the string and you're relying on the ordering to
   # append the correct one.
   libgcj_spec_lgcj_override="-lgcj-noncore -lgcj"
-  libgcj_spec_lgcj_bc_override="-lgcj-noncore -lgcj_bc"
+  libgcj_spec_lgcj_bc_override="-lgcj-noncore -lgcj_bc -lgcj"
 fi
 
 
@@ -1165,7 +1165,7 @@ AC_CONFIG_LINKS(sysdep/backtrace.h:$fallback_backtrace_h)
 AC_CONFIG_LINKS(sysdep/descriptor.h:$descriptor_h)
 
 LIBGCJ_SPEC_LGCJ=-lgcj
-LIBGCJ_SPEC_LGCJ_BC=-lgcj_bc
+LIBGCJ_SPEC_LGCJ_BC="-lgcj_bc -lgcj"
 if test x"$libgcj_spec_lgcj_override" != x ; then
   LIBGCJ_SPEC_LGCJ=$libgcj_spec_lgcj_override
 fi
-- 
1.8.2.1

-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2013-06-03 10:56 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-04-16  8:36 [PATCH] Fix linking with -findirect-dispatch Andreas Schwab
2013-04-16  8:39 ` Jakub Jelinek
2013-04-16  8:59   ` Bryce McKinlay
2013-04-16  9:13   ` Andreas Schwab
2013-04-16  9:19     ` Jakub Jelinek
2013-04-16  9:37       ` Andreas Schwab
2013-04-16  9:49         ` Jakub Jelinek
2013-04-16  9:55           ` Matthias Klose
2013-04-26 11:22             ` Matthias Klose
2013-04-26 11:50               ` Andrew Haley
2013-04-16  9:57           ` Andreas Schwab
2013-04-16 10:08             ` Jakub Jelinek
2013-04-16 10:11               ` Andreas Schwab
2013-04-16 10:26                 ` Jakub Jelinek
2013-04-16 10:31                   ` Andreas Schwab
2013-04-16 16:13                   ` Andreas Schwab
2013-04-16 16:19                     ` Jakub Jelinek
2013-04-16 17:22                       ` Andreas Schwab
2013-06-03 10:56                       ` Andreas Schwab
2013-04-16 16:39                     ` Bryce McKinlay
2013-04-17 13:17                       ` Andreas Schwab

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).