Kaffe 0.9.2 on OS/2

Mikael Ståldal d96-mst at nada.kth.se
Sun Oct 26 10:52:15 PST 1997


Here are some patches for OS/2. To get the config/i386/os2 direcrory, just
copy config/i386/win32 and rename the cygnus subdirectory to emx.

With this patches and EMX 0.9c its possible to build Kaffe on OS/2. It
doesn't work though, it crashes as soon as I try to use it. I tried both
interpreter and JIT.

Only in kaffe/config/i386: os2
diff -cbr kaffe-0.9.2/config.guess kaffe/config.guess
*** kaffe-0.9.2/config.guess	Thu Jun 26 08:20:10 1997
--- kaffe/config.guess	Sun Oct 26 18:47:58 1997
***************
*** 442,447 ****
--- 442,450 ----
      i*86:CYGWIN32/*:*:*)
  	echo i386-unknown-win32/cygnus
  	exit 0 ;;
+     i*86:OS/2:*:*)
+ 	echo i386-pc-os2/emx
+ 	exit 0 ;;
  
  esac
  
diff -cbr kaffe-0.9.2/config.sub kaffe/config.sub
*** kaffe-0.9.2/config.sub	Thu Jun 26 08:20:12 1997
--- kaffe/config.sub	Sun Oct 26 18:45:38 1997
***************
*** 697,702 ****
--- 697,704 ----
  	-xenix)
  		os=-xenix
  		;;
+         -os2*)
+ 		;;
  	-none)
  		;;
  	*)
diff -cbr kaffe-0.9.2/configure.in kaffe/configure.in
*** kaffe-0.9.2/configure.in	Sat Oct  4 03:26:52 1997
--- kaffe/configure.in	Tue Oct 21 22:42:48 1997
***************
*** 141,146 ****
--- 141,155 ----
  	LN_S="cp"
  	;;
  
+ i[3456]86-os2/emx)
+ 	host_cpu=i386
+ 	host_os=os2/emx
+ 	EXEEXT=.exe
+ 	SCREXT=.cmd
+ 	dynamic_libraries=no
+ 	LN_S="cp"
+ 	;;
+ 
  i[3456]86-dgux*)
  	host_cpu=i386
  	host_os=dgux
***************
*** 457,462 ****
--- 466,473 ----
  case $host_os in
  win32*)
  	SYSTEM=win32 ;;
+ os2*)
+ 	SYSTEM=os2 ;;
  *)
  	SYSTEM=unix ;;
  esac
***************
*** 1060,1065 ****
--- 1071,1085 ----
  	fi
  	echo set KAFFEHOME=$datadir/kaffe >> ENVIRONMENT.BAT
  	echo set PATH=%PATH%\;$bindir >> ENVIRONMENT.BAT
+ elif test "$SYSTEM" = "os2" ; then
+ 	echo @echo off > ENVIRONMENT.CMD
+ 	if test "$awt_toolkit" != "none" ; then
+ 		echo set CLASSPATH=.\;$datadir/kaffe/classes.zip\;$datadir/kaffe/$awt_toolkit >> ENVIRONMENT.CMD
+ 	else
+ 		echo set CLASSPATH=.\;$datadir/kaffe/classes.zip >> ENVIRONMENT.CMD
+ 	fi
+ 	echo set KAFFEHOME=$datadir/kaffe >> ENVIRONMENT.CMD
+ 	echo set PATH=%PATH%\;$bindir >> ENVIRONMENT.CMD
  fi
  
  dnl -------------------------------------------------------------------------
diff -cbr kaffe-0.9.2/include/system.h kaffe/include/system.h
*** kaffe-0.9.2/include/system.h	Mon May  5 07:25:32 1997
--- kaffe/include/system.h	Sun Oct 26 15:05:22 1997
***************
*** 22,28 ****
  #define	file_seperator		"/"
  #define	path_seperator		":"
  #define	line_seperator		"\n"
! #elif defined(__WIN32__) || defined(__OS2__)
  #define	file_seperator		"\\"
  #define	path_seperator		";"
  #define	line_seperator		"\r\n"
--- 22,28 ----
  #define	file_seperator		"/"
  #define	path_seperator		":"
  #define	line_seperator		"\n"
! #elif defined(__WIN32__) || defined(__OS2__) || defined(__EMX__)
  #define	file_seperator		"\\"
  #define	path_seperator		";"
  #define	line_seperator		"\r\n"
diff -cbr kaffe-0.9.2/kaffe/kaffevm/paths.h kaffe/kaffe/kaffevm/paths.h
*** kaffe-0.9.2/kaffe/kaffevm/paths.h	Wed Apr 16 01:10:56 1997
--- kaffe/kaffe/kaffevm/paths.h	Sun Oct 26 15:07:30 1997
***************
*** 18,24 ****
  #define	MAXPATHLEN	1024
  #endif
  
! #if defined(__WIN32__) || defined(__OS2__)
  #define	PATHSEP		';'
  #define	DIRSEP		"\\"
  #elif defined(__amigaos__)
--- 18,24 ----
  #define	MAXPATHLEN	1024
  #endif
  
! #if defined(__WIN32__) || defined(__OS2__) || defined(__EMX__)
  #define	PATHSEP		';'
  #define	DIRSEP		"\\"
  #elif defined(__amigaos__)

-- 
/****************************************************************\
* You have just read a message from Mikael Ståldal.              *
*                                                                *
* Remove "ingen.reklam." from the address before mail replying.  *
\****************************************************************/



More information about the kaffe mailing list