Attached are some of my FreeBSD/amd64 patches: kaffe-config.alias: The name is "amd64" on FreeBSD, not x86_64. (Calling it freebsd2 is ugly as well, but moving files in CVS is uglier)
kaffe-freebsdamd64.tar.gz: config/ files for FreeBSD/amd64. I'm not sure about FP_OFFSET, and it may require fp reg saving as in i386, but I was using pthreads. kaffe-methodcalls-external.diff: The lack of extern.h inclusion caused the prototype to be defaulted, I guess, which means an int return type. This truncated the function pointer and caused a crash on startup. It would be nice to default to pthreads on FreeBSD. However, we have two threading libraries: libc_r on 4.x, and libpthread (no 's') on 5.x. I overrode the libpthreads default using PTHREAD_LIBS during configure, and that got me almost there, except that ld couldn't find the pthread symbols in building libkaffevm. I just put PTHREAD_LIBS in that Makefile.am to get the build working. This could really use a clean solution. -- Eric Anholt [EMAIL PROTECTED] http://people.freebsd.org/~anholt/ [EMAIL PROTECTED]
Index: config/config.alias =================================================================== RCS file: /cvs/kaffe/kaffe/config/config.alias,v retrieving revision 1.21 diff -u -r1.21 config.alias --- config/config.alias 21 Aug 2004 15:11:30 -0000 1.21 +++ config/config.alias 20 Oct 2004 23:13:28 -0000 @@ -7,6 +7,7 @@ hppa*) Khost_cpu=parisc ;; i[3456]86) Khost_cpu=i386 ;; sa110) Khost_cpu=arm ;; +amd64) Khost_cpu=x86_64 ;; arm32) Khost_cpu=arm ;; armv*[lb]) Khost_cpu=arm ;; mipsel) Khost_cpu=mips ;;
kaffe-freebsdamd64.tar.gz
Description: application/compressed-tar
Index: kaffe/kaffevm/intrp/methodcalls.c =================================================================== RCS file: /cvs/kaffe/kaffe/kaffe/kaffevm/intrp/methodcalls.c,v retrieving revision 1.2 diff -u -r1.2 methodcalls.c --- kaffe/kaffevm/intrp/methodcalls.c 27 Aug 2004 12:22:05 -0000 1.2 +++ kaffe/kaffevm/intrp/methodcalls.c 20 Oct 2004 23:10:31 -0000 @@ -21,6 +21,7 @@ #include "thread.h" #include "slots.h" #include "soft.h" +#include "external.h" void * engine_buildTrampoline (Method *meth, void **where, errorInfo *einfo UNUSED)
_______________________________________________ kaffe mailing list [EMAIL PROTECTED] http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
