2008-08-14 11:45:02     unable to compile kaffe for blackfin/uclinux

Document created by Aaronwu Employee on Aug 8, 2013
Version 1Show Document
  • View in full screen mode

2008-08-14 11:45:02     unable to compile kaffe for blackfin/uclinux

Jeff Hepba (UNITED STATES)

Message: 60481   

 

Hi folks. I've tried getting help for this problem from the kaffe mailing list, but haven't been able to. Hopefully somebody here can help me...

 

I'm new to the embedded world. I'm attempting to get a Java application running on a Blackfin powered board. I'm following the instructions on this page:

 

http://docs.blackfin.uclinux.org/doku.php?id=run_java_application_on_stamp_board

 

I've successfully compiled kaffe for my host linux system (although I had to disable some functionality). I'm now trying to compile kaffe for Blackfin/uClinux, using this command:

 

./configure --host=bfin-uclinux --disable-native-awt --enable-pure-java-math --with-gc=kaffe-gc --with-threads=unix-pthreads --enable-static --with-staticlib --with-staticbin --with-staticvm --disable-binreloc --disable-alsa --without-esd --with-engine=intrp --disable-gconf-peer

 

When I run make, I receive this error:

 

< much output removed >

gcc -DHAVE_CONFIG_H -I. -I../../../config -I../../../kaffe/kaffevm/systems/unix-pthreads -I../../../kaffe/kaffevm/jni -I.. -I./.. -DINTERPRETER -I../../../include -I../../../config/bfin -I../../../config/bfin/uclinux -DDIRECT_THREADING -I/usr/local/downloads/kaffe-1.1.8.forUClinux/./kaffe/kaffevm -I/usr/local/downloads/kaffe-1.1.8.forUClinux/./kaffe/kaffevm/intrp -I/usr/local/downloads/kaffe-1.1.8.forUClinux/./kaffe/kaffevm/systems/unix-pthreads -I../../../replace -I../../../config -I../../../include -I../../../libraries/javalib/external/classpath/include -DKAFFE_VMDEBUG -D_REENTRANT -Wall -W -Wextra -fno-strict-aliasing -fno-omit-frame-pointer -fsigned-char -D__UCLIBC__ -D__unix__ -DKAFFEMD_BUGGY_STACK_OVERFLOW -DKAFFE_VMDEBUG -D_SCALB_INT -Wl,-elf2flt -pthread -g -O2 -MT methodcalls.lo -MD -MP -MF .deps/methodcalls.Tpo -c methodcalls.c -o methodcalls.o

In file included from ../locks.h:18,

                 from methodcalls.c:21:

../../../config/md.h:62:1: warning: "unix" redefined

<built-in>: warning: this is the location of the previous definition

../../../config/bfin/sysdepCallMethod.h: In function 'sysdepCallMethod':

../../../config/bfin/sysdepCallMethod.h:37: error: invalid register name for 'r0'

../../../config/bfin/sysdepCallMethod.h:38: error: invalid register name for 'r1'

../../../config/bfin/sysdepCallMethod.h:39: error: invalid register name for 'r2'

make[2]: *** [methodcalls.lo] Error 1

make[2]: Leaving directory `/usr/local/downloads/kaffe-1.1.8.forUClinux/kaffe/kaffevm/intrp'

make[1]: *** [all-recursive] Error 1

make[1]: Leaving directory `/usr/local/downloads/kaffe-1.1.8.forUClinux/kaffe/kaffevm'

make: *** [all-recursive] Error 1

 

This output is from kaffe 1.1.8. I'm not using 1.1.9 because I couldn't get that to compile either, and thought perhaps an older version would do the trick.

 

I've googled extensively and haven't been able to find a solution. Any help would be greatly appreciated.

 

Thanks!

QuoteReplyEditDelete

 

 

2008-08-14 12:26:41     Re: unable to compile kaffe for blackfin/uclinux

Mike Frysinger (UNITED STATES)

Message: 60482   

 

"gcc" is being invoked instead of "bifn-uclinux-gcc".  that isnt going to work ...

 

probably things werent configured properly so the cross-compile toolchain was not selected or found ...

QuoteReplyEditDelete

 

 

2008-08-14 14:02:26     Re: unable to compile kaffe for blackfin/uclinux

Jeff Hepba (UNITED STATES)

Message: 60485   

 

 

 

Yes, I think you are right. I changed my PATH to include the blackfin toolchain, but now when I run the configure script, I get this error:

 

./configure --host=bfin-uclinux --disable-native-awt --enable-pure-java-math --with-gc=kaffe-gc --with-threads=unix-pthreads --enable-static --with-staticlib --with-staticbin --with-staticvm --disable-binreloc --disable-alsa --without-esd --with-engine=intrp --disable-gconf-peer

configure: WARNING: If you wanted to set the --build type, don't use --host.

    If a cross compiler is detected then cross compile mode will be used.

checking for a BSD-compatible install... /usr/bin/install -c

checking whether build environment is sane... yes

checking for a thread-safe mkdir -p... /bin/mkdir -p

checking for gawk... gawk

checking whether make sets $(MAKE)... yes

checking for bfin-uclinux-strip... bfin-uclinux-strip

checking how to create a ustar tar archive... gnutar

checking whether to enable maintainer-specific portions of Makefiles... no

checking for bfin-uclinux-gcc... bfin-uclinux-gcc

checking for C compiler default output file name...

configure: error: C compiler cannot create executables

See `config.log' for more details.

 

 

 

Config.log indicates:

 

configure:3461: bfin-uclinux-gcc    conftest.c   >&5

/opt/uClinux/bfin-uclinux/lib/../bfin-uclinux/bin/ld.real: crt1.o: No such file: No such file or directory

 

 

 

Anybody know how to work around this probem? Thanks.

 

 

QuoteReplyEditDelete

 

 

2008-08-14 14:14:20     Re: unable to compile kaffe for blackfin/uclinux

Mike Frysinger (UNITED STATES)

Message: 60486   

 

have you installed the toolchain properly ?  please review the installing document:

http://docs.blackfin.uclinux.org/doku.php?id=toolchain:installing

QuoteReplyEditDelete

 

 

2008-08-14 14:34:01     Re: unable to compile kaffe for blackfin/uclinux

Jeff Hepba (UNITED STATES)

Message: 60487   

 

I think I've installed the toolchain properly. I followed the steps on the page you referred to. I've tried both the .tgz and .rpm files, and I get the same result either way.

QuoteReplyEditDelete

 

 

2008-08-14 14:46:39     Re: unable to compile kaffe for blackfin/uclinux

Mike Frysinger (UNITED STATES)

Message: 60488   

 

if your compiler cannot find the crt object, that indicates you have not installed any uClibc package.  please review the page:

http://docs.blackfin.uclinux.org/doku.php?id=toolchain:installing#available_packages

QuoteReplyEditDelete

 

 

2008-08-14 14:58:45     Re: unable to compile kaffe for blackfin/uclinux

Jeff Hepba (UNITED STATES)

Message: 60489   

 

Thanks for your help Mike. I'm making progress...

 

Configure gets farther along now, but still fails with:

 

< much output deleted >

 

Information: Using pure Java math library

checking if malloc debugging is wanted... no

configure: error: Can't find or can't use system zlib.h

QuoteReplyEditDelete

 

 

2008-08-14 19:59:42     Re: unable to compile kaffe for blackfin/uclinux

Mike Frysinger (UNITED STATES)

Message: 60498   

 

our toolchain doesnt include any libraries.  any third party libraries are provided via uclinux-dist or it's up to you to build/integrate.

 

this page may assist you:

http://docs.blackfin.uclinux.org/doku.php?id=uclinux-dist:existing_libraries#using_libs_in_external_applications

Attachments

    Outcomes