Subversion Repositories wimsdev

Rev

Rev 8177 | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. /*    Copyright (C) 1998-2003 XIAO, Gang of Universite de Nice - Sophia Antipolis
  2.  *
  3.  *  This program is free software; you can redistribute it and/or modify
  4.  *  it under the terms of the GNU General Public License as published by
  5.  *  the Free Software Foundation; either version 2 of the License, or
  6.  *  (at your option) any later version.
  7.  *
  8.  *  This program is distributed in the hope that it will be useful,
  9.  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  11.  *  GNU General Public License for more details.
  12.  *
  13.  *  You should have received a copy of the GNU General Public License
  14.  *  along with this program; if not, write to the Free Software
  15.  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  16.  */
  17.  
  18.  
  19. /******** Modifiable definitions ****************/
  20.  
  21.         /* buffer length for about information */
  22. #define aboutlen 512
  23.  
  24. /******** Nothing to modify below ***************/
  25.  
  26. #include <stdio.h>
  27. #include <stdlib.h>
  28. #include <stdarg.h>
  29. #include <unistd.h>
  30. #include <string.h>
  31. #include <ctype.h>
  32. #include <time.h>
  33. #include <errno.h>
  34. #include <sys/time.h>
  35. #include <sys/wait.h>
  36. #include <sys/types.h>
  37. #include <sys/stat.h>
  38. #include <signal.h>
  39. #include <fcntl.h>
  40. #include "../config.h"
  41. #include "../wimsdef.h"
  42. #include "../Lib/libwims.h"
  43.  
  44. #define parmlim (MAX_LINELEN+256)
  45. #define inputlim (512*1024)
  46. #define SETUP_NO (sizeof(setups)/sizeof(setups[0]))
  47. extern int illegal_no;
  48. extern int illpart_no;
  49. extern char *stringprinter;
  50. extern char *quitstring;
  51.  
  52. /* from common.c */
  53. void find_illegal(char *p);
  54. char *find_matching2(char *p, char c);
  55. void strip_zeros(char *p);
  56. void prepabout(char *cmd, char *outf, char *errf);
  57. int readabout(void);
  58. char *strip_trailing_spaces2(char *p);
  59. extern char aboutbuf[aboutlen];
  60. extern char outputfname[256], *tmp_dir;
  61. extern unsigned int seed; /* random seed value */
  62. extern char *wseed;
  63. void prepare1(void);
  64. void run(void);
  65.  
  66. extern char *progname;
  67. extern char *illpart[];
  68.  
  69. /* from pari.c */
  70. extern char *illegal[];
  71. extern int precision, fsizelim;
  72. extern char header[];
  73. extern char *nameofcmd;
  74.  
  75. /* from scilab.c */
  76. extern int must_chroot;
  77.  
  78. /* from yacas.c */
  79. extern char *cmdparm;
  80.