[BACK]Return to ox_m2.c CVS log [TXT][DIR] Up to [local] / OpenXM / src / Macaulay2 / m2

Diff for /OpenXM/src/Macaulay2/m2/ox_m2.c between version 1.1 and 1.2

version 1.1, 2000/10/09 12:04:01 version 1.2, 2000/12/14 05:09:29
Line 1 
Line 1 
 /* $OpenXM$ */  /* $OpenXM: OpenXM/src/Macaulay2/m2/ox_m2.c,v 1.1 2000/10/09 12:04:01 takayama Exp $ */
 /* original code from */  /* original code from */
 /* $Id$ */  /* $Id$ */
 #include <stdio.h>  #include <stdio.h>
 #include <unistd.h>  #include <unistd.h>
   #include <stdlib.h>
   
 #define OXDIR "/home/mike/M2stuff/takayama/rat/"  #define OXDIR "/home/mike/M2stuff/takayama/rat/"
 int main(int argc, char **argv)  int main(int argc, char **argv)
 {  {
     char *c,*s1, *s2, *e;
     e = getenv("OpenXM_HOME");
     c = (char *) malloc(strlen(e)+256);
     s1 = (char *) malloc(strlen(e)+256);
     s2 = (char *) malloc(strlen(e)+256);
     strcpy(c,e); strcat(c,"/bin/M2");
     strcpy(s1,e); strcat(s1,"/lib/m2/oxcommon.m2");
     strcpy(s2,e); strcat(s2,"/lib/m2/oxserver.m2");
   
   dup2(3,0);    dup2(3,0);
   dup2(4,1);    dup2(4,1);
   /*execl("/usr/local/bin/M2", "M2", "-n", "oxcommon.m2",    /*execl("/usr/local/bin/M2", "M2", "-n", "oxcommon.m2",
        "oxserver.m2", "-e\"OXserver()\"", NULL);         "oxserver.m2", "-e\"OXserver()\"", NULL);
   */    */
     /*
   execl("/usr/local/bin/M2", "M2", "-n", "-silent", OXDIR "oxcommon.m2",    execl("/usr/local/bin/M2", "M2", "-n", "-silent", OXDIR "oxcommon.m2",
        OXDIR "oxserver.m2", NULL);         OXDIR "oxserver.m2", NULL);
              */
     execl(c, "M2", "-n", "-silent", s1, s2, NULL);
   return 0;    return 0;
 }  }

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>