The R Project SVN R

Rev

Rev 13288 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 13288 Rev 14330
1
#! /bin/sh
1
#! /bin/sh
2
#
2
#
3
# ${R_HOME}/bin/Rcmd
3
# ${R_HOME}/bin/Rcmd
4
 
4
 
5
## Shell script wrapper for all R CMD commands.
5
## Shell script wrapper for all R CMD commands.
6
## For internal use only.
6
## For internal use only.
7
 
7
 
8
R_CMD="${R_HOME}/bin/Rcmd"
8
R_CMD="${R_HOME}/bin/Rcmd"
9
export R_CMD
9
export R_CMD
10
 
10
 
-
 
11
R_OSTYPE="unix"
-
 
12
export R_OSTYPE
-
 
13
 
11
## Add `share/perl' to the perl library path.
14
## Add `share/perl' to the perl library path.
12
if test -n "${PERL5LIB}"; then
15
if test -n "${PERL5LIB}"; then
13
  PERL5LIB="${R_HOME}/share/perl:${PERL5LIB}"
16
  PERL5LIB="${R_HOME}/share/perl:${PERL5LIB}"
14
  export PERL5LIB
17
  export PERL5LIB
15
else
18
else
16
  PERLLIB="${R_HOME}/share/perl:${PERLLIB}"
19
  PERLLIB="${R_HOME}/share/perl:${PERLLIB}"
17
  export PERLLIB
20
  export PERLLIB
18
fi
21
fi
19
 
22
 
20
. ${R_HOME}/etc/Renviron
23
. ${R_HOME}/etc/Renviron
21
export `sed 's/^ *#.*//; s/^\(.*\)=.*/\1/' ${R_HOME}/etc/Renviron`
24
export `sed 's/^ *#.*//; s/^\(.*\)=.*/\1/' ${R_HOME}/etc/Renviron`
22
 
25
 
23
PATH="${R_HOME}/bin:${PATH}" 
26
PATH="${R_HOME}/bin:${PATH}" 
24
case "${1}" in
27
case "${1}" in
25
  perl)
28
  perl)
26
    shift;
29
    shift;
27
    exec ${PERL} "${@}"
30
    exec ${PERL} "${@}"
28
    ;;
31
    ;;
29
  awk)
32
  awk)
30
    shift;
33
    shift;
31
    exec ${AWK}  "${@}"
34
    exec ${AWK}  "${@}"
32
    ;;
35
    ;;
33
  *)
36
  *)
34
    exec "${@}"
37
    exec "${@}"
35
    ;;
38
    ;;
36
esac
39
esac
37
 
40
 
38
### Local Variables: ***
41
### Local Variables: ***
39
### mode: sh ***
42
### mode: sh ***
40
### sh-indentation: 2 ***
43
### sh-indentation: 2 ***
41
### End: ***
44
### End: ***