This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: Fix libjava build on Solaris/x86 (PR libgcj/30513)


When I tried to bootstrap mainline on Solaris 10/x86 with the (still
unreviewed) boehm-gc patch

	http://gcc.gnu.org/ml/java-patches/2007-q2/msg00304.html

I noticed that i?86-pc-solaris2* is affected by PR libgcj/30513, too.  The
following patch fixes this.

Unfortunately, libgcj.so fails to link since many object files contain
non-PIC code even when compiled with -fPIC.  I'll have to investigate this.

Ok for mainline after the lockdown?

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University


Tue Jun 19 20:41:35 2007  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>

	PR libgcj/30513
	* configure.host (i[3-6]86-*): Undef sun.

Index: libjava/configure.host
===================================================================
--- libjava/configure.host	(revision 125822)
+++ libjava/configure.host	(working copy)
@@ -101,6 +101,9 @@ case "${host}" in
 	# the .text section of libgcj.so is 30k larger, and the .eh_frame
 	# section is 1.4M smaller.
 	libgcj_flags="${libgcj_flags} -ffloat-store -fomit-frame-pointer"
+	# On Solaris we have defined 'sun' which later conflicts with 
+	# namespace usage. So to work this away we use the below undefine.
+	libgcj_flags="${libgcj_flags} -Usun"
 	libgcj_interpreter=yes
 	libgcj_cxxflags=
 	libgcj_cflags=


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]