File: shell.c

package info (click to toggle)
rscheme 0.7.2-1.1
  • links: PTS
  • area: main
  • in suites: slink
  • size: 10,672 kB
  • ctags: 12,430
  • sloc: lisp: 37,104; ansic: 29,763; cpp: 2,630; sh: 1,677; makefile: 568; yacc: 202; lex: 175; perl: 33
file content (51 lines) | stat: -rw-r--r-- 1,434 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/*-----------------------------------------------------------------*-C-*---
 * File:    handc/rshell/shell.c
 *
 *          Copyright (C)1997 Donovan Kolbly <d.kolbly@rscheme.org>
 *          as part of the RScheme project, licensed for free use.
 *          See <http://www.rscheme.org/> for the latest information.
 *
 * File version:     1.10
 * File mod date:    1997.11.29 23:10:43
 * System build:     v0.7.2, 97.12.21
 *
 * Purpose:          Trivial "shell" application
 *------------------------------------------------------------------------*/

#include <stdlib.h>
#include <stdio.h>
#include <rscheme/api.h>
#include <rscheme/stdmodul.h>
#include <rscheme/rlseconf.h>

#ifdef PLATFORM_MAC_CODEWARRIOR
#include <stdio.h>
#include <sioux.h>
#endif

struct module_descr *(std_modules[]) = { STD_MODULES_DECL };

int main( int argc, const char **argv )
{
#ifdef PLATFORM_MAC_CODEWARRIOR
  /* configure the I/O window */
  SIOUXSettings.autocloseonquit = TRUE;
  SIOUXSettings.asktosaveonclose = TRUE;
#endif

  rs_install_dir = getenv( "RS_INSTALL_DIR" );
  if (!rs_install_dir)
    /* rs_install_dir = INSTALL_DIR; */
    rs_install_dir = "/usr/lib/rscheme";

#ifdef PLATFORM_MAC
  return rscheme_std_main( argc, argv, std_modules, "install/system.img" );
#else
  {
    char temp[1024];

    sprintf( temp, "%s/resource/system.img", rs_install_dir );
    return rscheme_std_main( argc, argv, std_modules, temp );
  }
#endif
}