prelim aix diffs
Todd T. Fries
toddf at acm.org
Tue Nov 3 19:05:09 PST 1998
Incase any of these changes are useful/enlightening I'd like to submit them
as 'minimum requirements to reach the linking stage' on AIX 4.3.1 .. which,
unfortunately fails due to some symbols I need to track down.
I'm using the AIX native cc compiler, not gcc, and I realize some of these
changes aren't very helpful to those who do use gcc on aix .. so I submit
the below as "this works but .. there is a better way, right?" ..
--
Todd Fries .. toddf at acm.org
cvs server: Diffing .
Index: configure
===================================================================
RCS file: /home/cvspublic/kaffe/configure,v
retrieving revision 1.33
diff -u -r1.33 configure
--- configure 1998/10/20 03:24:35 1.33
+++ configure 1998/11/03 23:16:56
@@ -1422,13 +1422,13 @@
EOF
-echo $ac_n "checking size of __int64""... $ac_c" 1>&6
-echo "configure:1427: checking size of __int64" >&5
-if eval "test \"`echo '$''{'ac_cv_sizeof___int64'+set}'`\" = set"; then
+echo $ac_n "checking size of int64""... $ac_c" 1>&6
+echo "configure:1427: checking size of int64" >&5
+if eval "test \"`echo '$''{'ac_cv_sizeof_int64'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$cross_compiling" = yes; then
- ac_cv_sizeof___int64=0
+ ac_cv_sizeof_int64=0
else
cat > conftest.$ac_ext <<EOF
#line 1435 "configure"
@@ -1438,26 +1438,26 @@
{
FILE *f=fopen("conftestval", "w");
if (!f) exit(1);
- fprintf(f, "%d\n", sizeof(__int64));
+ fprintf(f, "%d\n", sizeof(int64));
exit(0);
}
EOF
if { (eval echo configure:1446: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
- ac_cv_sizeof___int64=`cat conftestval`
+ ac_cv_sizeof_int64=`cat conftestval`
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -fr conftest*
- ac_cv_sizeof___int64=0
+ ac_cv_sizeof_int64=0
fi
rm -fr conftest*
fi
fi
-echo "$ac_t""$ac_cv_sizeof___int64" 1>&6
+echo "$ac_t""$ac_cv_sizeof_int64" 1>&6
cat >> confdefs.h <<EOF
-#define SIZEOF___INT64 $ac_cv_sizeof___int64
+#define SIZEOF_INT64 $ac_cv_sizeof_int64
EOF
Index: config/config-mem.h
===================================================================
RCS file: /home/cvspublic/kaffe/config/config-mem.h,v
retrieving revision 1.2
diff -u -r1.2 config-mem.h
--- config-mem.h 1998/09/10 08:34:19 1.2
+++ config-mem.h 1998/11/03 23:16:57
@@ -29,12 +29,16 @@
#if !defined(HAVE_MEMCPY)
void bcopy(void*, void*, size_t);
+#ifndef memcpy
#define memcpy(_d, _s, _n) bcopy((_s), (_d), (_n))
#endif
+#endif
#if !defined(HAVE_MEMMOVE)
/* use bcopy instead */
+#ifndef memmove
#define memmove(to,from,size) bcopy((from),(to),(size))
+#endif
#endif
#if !defined(HAVE_GETPAGESIZE)
Index: config/powerpc/aix/config.frag
===================================================================
RCS file: /home/cvspublic/kaffe/config/powerpc/aix/config.frag,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 config.frag
--- config.frag 1998/03/31 19:10:53 1.1.1.1
+++ config.frag 1998/11/03 23:16:58
@@ -3,5 +3,10 @@
#
host_cpu=powerpc
host_os=aix
-CFLAGS="-g -fsigned-char -DAIX -Dunix"
+if [ "$ac_cv_prog_gcc" = "no" ]
+then
+ CFLAGS="-O2 -g -DAIX -Dunix"
+else
+ CFLAGS="-g -fsigned-char -DAIX -Dunix"
+fi
dynamic_libraries=no
Index: include/Arrays.h
===================================================================
RCS file: /home/cvspublic/kaffe/include/Arrays.h,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 Arrays.h
--- Arrays.h 1998/03/31 19:10:53 1.1.1.1
+++ Arrays.h 1998/11/03 23:16:58
@@ -14,7 +14,7 @@
#define ARRAY_FIELDS \
unsigned int length; \
- double align[0]
+ double align[1]
struct Array {
Hjava_lang_Object base;
Index: include/nets.h
===================================================================
RCS file: /home/cvspublic/kaffe/include/nets.h,v
retrieving revision 1.2
diff -u -r1.2 nets.h
--- nets.h 1998/08/28 18:24:31 1.2
+++ nets.h 1998/11/03 23:16:58
@@ -15,11 +15,13 @@
#include "config-mem.h"
#include <errno.h>
+#ifndef AIX
extern int h_errno;
+#endif
#define MAXHOSTNAME 128
-#if defined(HAVE_STRERROR)
+#ifdef HAVE_STRERROR
#define SYS_ERROR strerror(errno)
#else
extern char* sys_errlist[];
Index: kaffe/kaffevm/gtypes.h
===================================================================
RCS file: /home/cvspublic/kaffe/kaffe/kaffevm/gtypes.h,v
retrieving revision 1.2
diff -u -r1.2 gtypes.h
--- gtypes.h 1998/06/19 01:35:20 1.2
+++ gtypes.h 1998/11/03 23:16:58
@@ -21,20 +21,26 @@
#elif defined(__CHAR_UNSIGNED__)
#error "no signed char type"
#else
+#ifndef AIX
typedef char int8;
#endif
+#endif
typedef unsigned char uint8;
#if SIZEOF_SHORT == 2
+#ifndef AIX
typedef short int16;
+#endif
typedef unsigned short uint16;
#else
#error "sizeof(short) must be 2"
#endif
#if SIZEOF_INT == 4
+#ifndef AIX
typedef int int32;
+#endif
typedef unsigned int uint32;
#elif SIZEOF_LONG == 4
typedef long int32;
@@ -47,7 +53,9 @@
typedef long int64;
typedef unsigned long uint64;
#elif SIZEOF_LONG_LONG == 8
+#ifndef AIX
typedef long long int64;
+#endif
typedef unsigned long long uint64;
#elif SIZEOF___INT64 == 8
typedef __int64 int64;
Index: kaffe/kaffevm/systems/unix-jthreads/jthread.h
===================================================================
RCS file: /home/cvspublic/kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h,v
retrieving revision 1.12
diff -u -r1.12 jthread.h
--- jthread.h 1998/08/28 18:24:39 1.12
+++ jthread.h 1998/11/03 23:16:58
@@ -112,7 +112,7 @@
* print a struct jthread
*/
/* for alignment (Gcc extension) */
- double align[0];
+ double align[1];
} jthread, *jthread_t;
#define GET_COOKIE() (jthread_current()->jlThread)
Index: libraries/clib/awt/X/toolkit.h
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/clib/awt/X/toolkit.h,v
retrieving revision 1.5
diff -u -r1.5 toolkit.h
--- toolkit.h 1998/09/08 22:27:20 1.5
+++ toolkit.h 1998/11/03 23:16:59
@@ -135,7 +135,9 @@
/*******************************************************************************
*
*/
-
+#ifdef AIX
+#define __inline__
+#endif
static __inline__ char* java2CString ( JNIEnv *env, Toolkit* X, jstring jstr ) {
jboolean isCopy;
More information about the kaffe
mailing list