diff -Naur --exclude=*.exe --exclude=*.o tm_axiom/tm_axiom.c tm_open-axiom/tm_axiom.c
--- tm_axiom/tm_axiom.c	Tue Dec 21 03:51:30 2004
+++ tm_open-axiom/tm_axiom.c	Tue Mar  4 18:46:48 2008
@@ -37,7 +37,7 @@
  * Modified by Bill Page 20041215
  * - add call to Robert Sutor line-break routine
  * Modified by Bill Page 20041217
- * - initialize AXIOM_exe from AXIOM environment variable
+ * - initialize AXIOM_cmd from AXIOM environment variable
  * Modified by Bill Page 20041220
  * - use args, TM_AXIOM environment variable and/or
  *     )set output texmacs option,option, ...
@@ -51,6 +51,9 @@
  * - process Axiom output with no LaTeX content, e.g.
  *     )set output tex off
  *     )set output algebra on
+ * Modified by Bill Page 20080304
+ * - revised AXIOM_cmd for open-axiom
+ * - use OPENAXIOM environment variable
  *                                                                */
 
 #include <windows.h>
@@ -84,7 +87,6 @@
 #define   READ_HANDLE 0
 #define   WRITE_HANDLE 1
 
-char AXIOM_exe[256];
 char AXIOM_cmd[256];
 char ENV_AXIOM[256];
 
@@ -101,14 +103,13 @@
   int i;
   float w;
 
-/* e.g. AXIOM=c:/Program Files/axiom/mnt/windows                        */
-  if (pAXIOM=getenv("AXIOM")) {
-    strcpy(AXIOM_exe,pAXIOM); strcat(AXIOM_exe,"/bin/AXIOMsys.exe");
-    strcpy(AXIOM_cmd,pAXIOM); strcat(AXIOM_cmd, "/bin/AXIOMsys.exe");
-    strcpy(ENV_AXIOM,"AXIOM="); strcat(ENV_AXIOM, pAXIOM);
+  if (pAXIOM=getenv("OPENAXIOM")) {
+    strcpy(AXIOM_cmd,pAXIOM); strcat(AXIOM_cmd, "/../../../../bin/open-axiom.exe");
+    strcat(AXIOM_cmd," --system=\""); strcat(AXIOM_cmd,pAXIOM); strcat(AXIOM_cmd,"\"");
+    strcpy(ENV_AXIOM,"OPENAXIOM="); strcat(ENV_AXIOM, pAXIOM);
   } else {                               /* We need the AXIOM variable! */
-    printf("You must set the AXIOM environment variable, e.g.\n");
-    printf("  AXIOM=c:/Program Files/axiom/mnt/windows\n");
+    printf("You must set the OPENAXIOM environment variable, e.g.\n");
+    printf("  OPENAXIOM=C:/Program Files/OpenAxiom/lib/open-axiom/i686-pc-mingw32/1.1.0\n");
     exit(1);
   };
 
