Luca wrote:
> Dan Nicholson wrote:
>   
>> On 9/20/06, Luca <[EMAIL PROTECTED]> wrote:
>>     
>>> I'm recompiling gcc-4.1.1 in order to user NVIDIA-SDK, but I'm having an
>>> error I'm trying to solve.
>>> Gcc-4.1.1 configure so:
>>> "../gcc-4.1.1/configure --prefix=/usr --libexecdir=/usr/lib
>>> --enable-shared --enable-threads=posix --enable-__cxa_atexit
>>> --enable-clocale=gnu
>>> --enable-languages=c,ada,c++,fortran,java,objc,obj-c++,treelang
>>> --with-mpfr=usr --with-gmp=/usr --with-system-zlib --with-x
>>> --enable-java-awt=gtk,xlib --enable-gtk-cairo --enable-java-gc=boehm
>>> --with-libart-prefix=/usr --without-system-unwind
>>> --enable-libstdcxx-allocator=mt --enable-libstdcxx-debug".
>>>
>>> While making in java I receive this error:
>>> "./gcj-dbtool -n classmap.db || touch classmap.db
>>> Unexpected error from pthread_mutex_trylock
>>> /bin/sh: line 1: 15360 Aborted                ./gcj-dbtool -n
>>> classmap.db
>>> make[3]: Leaving directory
>>> `/sources/gcc-build/i686-pc-linux-gnu/libjava'
>>> make[2]: Leaving directory
>>> `/sources/gcc-build/i686-pc-linux-gnu/libjava'
>>> make[1]: Leaving directory `/sources/gcc-build'"
>>>       
>> Two things I noticed. First, I think that the the error is hrom the
>> boehm garbage collector. From boehm-gc/pthread_support.c:
>>
>>        switch(pthread_mutex_trylock(lock)) {
>>            case 0:
>> #               ifdef LOCK_STATS
>>                    ++GC_spin_count;
>> #               endif
>>                return;
>>            case EBUSY:
>>                break;
>>            default:
>>                ABORT("Unexpected error from pthread_mutex_trylock");
>>        }
>>
>> So, you could try removing --enable-java-gc=boehm. However, I think
>> you can ignore the error. Here's from libjava/Makefile.am:
>>
>> ## The .db file.  This rule is only used for native builds, so it is
>> ## safe to invoke gcj-dbtool.
>> $(db_name): gcj-dbtool$(EXEEXT)
>> ## In case it exists already.
>>        @rm -f $(db_name)
>> ## We don't actually care if it fails -- if it does, just make an
>> ## empty file.  This is simpler than trying to discover when mmap is
>> ## not available.
>>        ./gcj-dbtool -n $(db_name) || touch $(db_name)
>>
>> Does make return unsuccessfully?
>>
>> -- 
>> Dan
>>     
>
> Hi Dan, the trick about omitting the --enable-java-gc=boehm does not
> work, in fact from the configuring instructions of gcc it says that if
> it is not specified it uses it by default.
>  The Error is:
> creating gcj-dbtool
> ./gcj-dbtool -n classmap.db || touch classmap.db
> Unexpected error from pthread_mutex_trylock
> /bin/sh: line 1:  9997 Aborted                 ./gcj-dbtool -n classmap.db
> make[3]: Leaving directory `/sources/gcc-build/i686-pc-linux-gnu/libjava'
> make[2]: Leaving directory `/sources/gcc-build/i686-pc-linux-gnu/libjava'
> make[1]: Leaving directory `/sources/gcc-build'
>
> However I think it is something deeper, in fact, making check for Gc6.6
> reports this error:
> gcc -DPACKAGE_NAME=\"gc\" -DPACKAGE_TARNAME=\"gc\"
> -DPACKAGE_VERSION=\"6.6\" -DPACKAGE_STRING=\"gc\ 6.6\"
> -DPACKAGE_BUGREPORT=\"[EMAIL PROTECTED]" -DGC_VERSION_MAJOR=6
> -DGC_VERSION_MINOR=6 -DPACKAGE=\"gc\" -DVERSION=\"6.6\"
> -DGC_LINUX_THREADS=1 -D_REENTRANT=1 -DTHREAD_LOCAL_ALLOC=1
> -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1
> -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1
> -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=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. -I. -I./include   -fexceptions -g -O2 -c
> ./tests/test.c
> /bin/sh ./libtool --mode=link gcc -fexceptions -g -O2  -o gctest  test.o
> ./libgc.la -lpthread -ldl
> gcc -fexceptions -g -O2 -o .libs/gctest test.o  ./.libs/libgc.so
> /usr/local/lib/libpthread.so -ldl -Wl,--rpath -Wl,/usr/local/lib
> ./.libs/libgc.so: undefined reference to `sem_destroy'
> ./.libs/libgc.so: undefined reference to `sem_wait'
> ./.libs/libgc.so: undefined reference to `sem_post'
> ./.libs/libgc.so: undefined reference to `pthread_detach'
> ./.libs/libgc.so: undefined reference to `sem_init'
> ./.libs/libgc.so: undefined reference to `sem_getvalue'
> collect2: ld returned 1 exit status
> make[2]: *** [gctest] Error 1
> make[2]: Leaving directory `/sources/gc6.6'
> make[1]: *** [check-am] Error 2
> make[1]: Leaving directory `/sources/gc6.6'
> make: *** [check-recursive] Error 1
>
> Bye,
> Luca
>   
Solved by touching manually in libjava dir classpath.db, however can you
tell me something about the check of Gc6.6?

Thanks,
Luca
-- 
http://linuxfromscratch.org/mailman/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to