source: trunk/environment.sh @ 134

Last change on this file since 134 was 134, checked in by rosiere, 15 years ago

1) valgrind fix
2) debug file on/off

  • Property svn:keywords set to Id
File size: 2.1 KB
Line 
1#!/bin/sh
2
3declare OS_FOUND=`uname -s`-`uname -m | sed -e 's/i[0-9]/iX/' -e 's/sun4./sun4X/'`
4
5case ${OS_FOUND} in
6#    "SunOS-sun4X")
7#       export TARGET_ARCH=gccsparcOS5
8#       export EXE_SUFFIX=
9#       ;;
10    "Linux-iX86")
11        export TARGET_ARCH=linux
12        export EXE_SUFFIX=
13        ;;
14#    "FreeBSD-iX86")
15#       export TARGET_ARCH=freebsd
16#       export EXE_SUFFIX=
17#       ;;
18#    "CYGWIN_NT-5.1-iX86")
19#       export TARGET_ARCH=cygwin
20#       export EXE_SUFFIX=.exe
21#       ;;     
22    *) 
23     echo "Unknown OS found"
24esac
25
26# Export environement
27export MORPHEO_LOCALIZATION="labs_network";
28export MORPHEO_TOPLEVEL=${PWD};
29export MORPHEO_SCRIPT=${MORPHEO_TOPLEVEL}/IPs/systemC/processor/Morpheo/Script;
30export MORPHEO_HOME=${HOME}/.Morpheo;
31       MORPHEO_XTTY=${MORPHEO_TOPLEVEL}/IPs/systemC/Environment/TTY/xtty;
32
33case ${MORPHEO_LOCALIZATION} in
34    "labs_network")
35        export MORPHEO_PREFIX=/users/chaos/kane/Morpheo;
36        export MORPHEO_TMP=${MORPHEO_PREFIX};
37        ;;
38    "labs_local")
39        export MORPHEO_PREFIX=/dsk/l1/misc/Morpheo;
40        export MORPHEO_TMP=${MORPHEO_PREFIX};
41        ;;
42    "home")
43        export MORPHEO_PREFIX=${HOME}/tmp/Morpheo;
44        export MORPHEO_TMP=${MORPHEO_PREFIX};
45        ;;
46    *)
47        echo "Bad localization : \"${MORPHEO_LOCALIZATION}\"";
48        ;;
49esac
50
51echo ""
52echo "OS found : ${OS_FOUND}"
53echo ""
54echo "Modification of environement's variable :"
55echo " - MORPHEO_LOCALIZATION is set to ${MORPHEO_LOCALIZATION}"
56echo " - MORPHEO_TOPLEVEL     is set to ${MORPHEO_TOPLEVEL}"
57echo " - MORPHEO_SCRIPT       is set to ${MORPHEO_SCRIPT}"
58echo " - MORPHEO_HOME         is set to ${MORPHEO_HOME}"
59echo " - MORPHEO_PREFIX       is set to ${MORPHEO_PREFIX}"
60echo " - MORPHEO_TMP          is set to ${MORPHEO_TMP}"
61
62#----------
63# Path : add xtty and script directory.
64#        test if already in path : no multiple addition
65#----------
66
67echo ${PATH} |grep -q ${MORPHEO_SCRIPT};
68if test $? -eq 1; then
69    export  PATH=${PATH}:${MORPHEO_SCRIPT}
70    echo " - PATH             add       ${MORPHEO_SCRIPT}"
71fi;
72
73echo ${PATH} |grep -q ${MORPHEO_XTTY};
74
75if test $? -eq 1; then
76    export  PATH=${PATH}:${MORPHEO_XTTY}
77    echo " - PATH             add       ${MORPHEO_XTTY}"
78fi;
79
80echo ""
Note: See TracBrowser for help on using the repository browser.