libjava failed to build on Linux/x86

Per Bothner per@bothner.com
Thu Jan 24 14:09:00 GMT 2002


It's failing for me too, but in a different place:

/home/bothner/GNU/linux-gcc/gcc/g++ -B/home/bothner/GNU/linux-gcc/gcc/ 
-nostdinc++ -nostdinc++ 
-I/home/bothner/GNU/linux-gcc/i686-pc-linux-gnu/libstdc++-v3/include/i686-pc-linux-gnu 
-I/home/bothner/GNU/linux-gcc/i686-pc-linux-gnu/libstdc++-v3/include 
-I/home/bothner/GNU/gcc/libstdc++-v3/libsupc++ 
-I/home/bothner/GNU/gcc/libstdc++-v3/libio 
-I/home/bothner/GNU/gcc/libstdc++-v3/include/backward 
-I/home/bothner/GNU/gcc/libstdc++-v3/testsuite 
-L/home/bothner/GNU/linux-gcc/i686-pc-linux-gnu/libstdc++-v3/src 
-L/home/bothner/GNU/linux-gcc/i686-pc-linux-gnu/libstdc++-v3/src/.libs 
-B/home/bothner/GNU/install-gcc/i686-pc-linux-gnu/bin/ 
-B/home/bothner/GNU/install-gcc/i686-pc-linux-gnu/lib/ -isystem 
/home/bothner/GNU/install-gcc/i686-pc-linux-gnu/include -DHAVE_CONFIG_H 
-I. -I/home/bothner/GNU/gcc/libjava -I./include -I./gcj 
-I/home/bothner/GNU/gcc/libjava -Iinclude 
-I/home/bothner/GNU/gcc/libjava/include 
-I/home/bothner/GNU/gcc/libjava/../boehm-gc/include -DGC_LINUX_THREADS=1 
-D_REENTRANT=1 -DTHREAD_LOCAL_ALLOC=1 -DSILENT=1 -DNO_SIGNALS=1 
-DNO_EXECUTE_PERMISSION=1 -DALL_INTERIOR_POINTERS=1 
-DJAVA_FINALIZATION=1 -DGC_GCJ_SUPPORT=1 -DATOMIC_UNCOLLECTABLE=1 
-I/home/bothner/GNU/gcc/libjava/libltdl 
-I/home/bothner/GNU/gcc/libjava/libltdl 
-I/home/bothner/GNU/gcc/libjava/.././libjava/../gcc 
-I/home/bothner/GNU/gcc/libjava/../zlib 
-I/home/bothner/GNU/gcc/libjava/../libffi/include -I../libffi/include 
-fno-rtti -fnon-call-exceptions -fdollars-in-identifiers 
-D__NO_MATH_INLINES -ffloat-store -I/usr/X11R6/include -W -Wall 
-D_GNU_SOURCE -DPREFIX=\"/home/bothner/GNU/install-gcc\" -g 
-D_GNU_SOURCE -MD -MT java/lang/natObject.lo -MF java/lang/natObject.pp 
-c /home/bothner/GNU/gcc/libjava/java/lang/natObject.cc  -fPIC -DPIC -o 
java/lang/.libs/natObject.o
In file included from 
/home/bothner/GNU/gcc/libjava/java/lang/natObject.cc:281:
/home/bothner/GNU/gcc/boehm-gc/include/gc.h:53:1: warning: 
"GC_LINUX_THREADS" redefined
/home/bothner/GNU/gcc/libjava/java/lang/natObject.cc:1:1: warning: this 
is the location of the previous definition
/home/bothner/GNU/gcc/libjava/java/lang/natObject.cc: In function `bool
    compare_and_swap(volatile obj_addr_t*, unsigned int, unsigned int)':
/home/bothner/GNU/gcc/libjava/java/lang/natObject.cc:329: inconsistent 
operand
    constraints in an `asm'
make[3]: *** [java/lang/natObject.lo] Error 1

The asm is:

   inline static bool
   compare_and_swap(volatile obj_addr_t *addr,
		 
				obj_addr_t old,
						obj_addr_t new_val)
   {
     char result;
     __asm__ __volatile__("lock; cmpxchgl %2, %0; setz %1"
	    	: "=m"(*(addr)), "=q"(result)
		: "r" (new_val), "0"(*(addr)), "a"(old) : "memory");
     return (bool) result;
   }


-- 
	--Per Bothner
per@bothner.com   http://www.bothner.com/per/



More information about the Java mailing list