[kaffe] Problem to locate "libnative.a"

daniel at fh-konstanz.de daniel at fh-konstanz.de
Sun Oct 23 14:19:33 PDT 2005


Hello people,

i have following problem:

i have ported kaffe 1.0.6 for ecos as os on my motorola coldfire 5282 board with
8 MB Flash. I have used this version of kaffe, because the "sinby" developers
have added some specific code for ecos.
Before uploading and starting kaffe on my motorola board, i have created an
jffs2 image with following libraries:

rt.jar
libnative.a and other a. files. 

I have installed these files in the root directory "/" and adapted the following
environment variables:

vmargs.classhome = rt.jar
DEFAULT_CLASSPATH = "/"
KAFFELIBRARYPATH = "/"

After starting kaffe, i realized, that kaffe can mount my jffs2 filesystem
successfully (the rc value is 0).

mount( "/dev/flash1", "/", "jffs2" );

Kaffe can also open and read the rt.jar file successfully:

rc = KOPEN(path, O_RDONLY, 0, &h);
	if (rc) {
		return (CP_INVALID);
	}

	rc = KREAD(h, buf, sizeof(buf), &c);
	KCLOSE(h);
	if (c != sizeof(buf)) {
		return (CP_INVALID)

But finally foolowing message occurs:

now loading...... /libnative.a
user_search_path:(null) libnative.a
LTDL_SEARCHPATH_VAR:(null) libnative.a
sys_search_path:/lib:/usr/lib libnative.a
xtryall_dlopen /libnative.a
tryall_dlopen loader:366a2 /libnative.a
sys->name:libnative.a

Failed to locate native library "libnative" in path /

Aborting.

I have configured kaffe with following options in config/m68k/ecos/config.frag:

ac_cv_prog_cc_cross='yes'
cross_compiling='yes'
enable_xprofiling='no'

host_cpu=m68k
host_os=ecos

with_staticlib=yes 
with_libraries=yes 
with_x=no
with_threads=ecos-native

ac_cv_c_bigendian='yes'
ac_cv_sizeof_int='4'
ac_cv_sizeof_long='4'
ac_cv_sizeof_long_long='8'
#ac_cv_sizeof___int64='8'
ac_cv_sizeof_short='2'
ac_cv_sizeof_voidp='4'
ac_cv_alignmentof_voidp='4'

ac_cv_c_char_unsigned='no'
ac_cv_typedef_bool='yes'

dynamic_libraries='no'
ac_cv_func_dlopen='no'
ac_cv_func_dlerror='no'
ac_cv_func_sbrk='no'
ac_cv_func_getuid='no'

ac_cv_func_strerror='yes'

ac_cv_header_sys_utsname_h='no'

enable_mips2='no'

I have spend about 5 days for searching the error, but cannot solve the problem.
Can anybody help me?

Perhaps you can give me some information, which environment variables i have to 
set. Do i have to compress the *.a files in a jar file?
I have made a static binary including the libnative.a. Why kaffe can not find
that library?

Thank you so much for answering,

Dani! 







More information about the kaffe mailing list