1 | #!/bin/sh |
---|
2 | # $Id$ |
---|
3 | #--------------------------------------------------------------------- |
---|
4 | #- w_i_h 04/10/1999 |
---|
5 | #- Reconnaissance du systeme |
---|
6 | #--------------------------------------------------------------------- |
---|
7 | ( uname -s 1> /dev/null ) 2> /dev/null |
---|
8 | if [ $? -ne 0 ]; then |
---|
9 | exit 1; |
---|
10 | fi; |
---|
11 | #- |
---|
12 | USYS=`uname -s`; |
---|
13 | #- |
---|
14 | if [ "$USYS" = "AIX" ]; then |
---|
15 | WSYS=`uname -n | sed -e "s/^\(zahir\)\(.*\)/\1/"`; |
---|
16 | if [ "$WSYS" = "zahir" ]; then |
---|
17 | DSYS="aix"; |
---|
18 | else |
---|
19 | DSYS="ax_mono"; |
---|
20 | fi; |
---|
21 | elif [ "$USYS" = "AIXESA" ]; then |
---|
22 | DSYS="aixesa"; |
---|
23 | elif [ "$USYS" = "ConvexOS" ]; then |
---|
24 | DSYS="convex"; |
---|
25 | elif [ "$USYS" = "CP486" \ |
---|
26 | -o "$USYS" = "dev" ]; then |
---|
27 | DSYS="sco"; |
---|
28 | elif [ "$USYS" = "Darwin" ]; then |
---|
29 | DSYS="Darwin"; |
---|
30 | elif [ "$USYS" = "HP-UX" ]; then |
---|
31 | WSYS=`uname -n`; |
---|
32 | if [ "$WSYS" = "moon" ]; then |
---|
33 | DSYS="eshpux"; |
---|
34 | else |
---|
35 | DSYS="hpux"; |
---|
36 | fi; |
---|
37 | elif [ "$USYS" = "IRIX" ]; then |
---|
38 | WSYS=`uname -r | sed -e "s/\..*//"` |
---|
39 | if [ "$WSYS" = "4" ]; then |
---|
40 | DSYS="sgi4"; |
---|
41 | else |
---|
42 | DSYS="sgi5"; |
---|
43 | fi; |
---|
44 | elif [ "$USYS" = "IRIX64" ]; then |
---|
45 | DSYS="sgi6"; |
---|
46 | elif [ "$USYS" = "Linux" ]; then |
---|
47 | WSYS=`uname -n | sed -e "s/^\(asterix\)\(.*\)/\1/" \ |
---|
48 | -e "s/^\(obelix\)\(.*\)/\1/" \ |
---|
49 | -e "s/^\(ds\)\([0-9]*\)/\1/"` |
---|
50 | if [ "$WSYS" = "asterix" \ |
---|
51 | -o "$WSYS" = "obelix" ]; then |
---|
52 | DSYS="lxiv8"; |
---|
53 | elif [ "$WSYS" = "mercure" ]; then |
---|
54 | DSYS="sx8mercure"; |
---|
55 | elif [ "$WSYS" = "brodie" ]; then |
---|
56 | DSYS="sx8brodie"; |
---|
57 | elif [ "$WSYS" = "ds" ]; then |
---|
58 | DSYS="sxdkrz"; |
---|
59 | else |
---|
60 | DSYS="linux"; |
---|
61 | fi; |
---|
62 | elif [ "$USYS" = "MIPS" ]; then |
---|
63 | DSYS="mips"; |
---|
64 | elif [ "$USYS" = "OSF1" ]; then |
---|
65 | DSYS="osf1"; |
---|
66 | elif [ "$USYS" = "SunOS" ]; then |
---|
67 | WSYS=`uname -r | sed -e "s/\..*//"` |
---|
68 | if [ "$WSYS" = "5" ]; then |
---|
69 | WSYS=`uname -r | sed -e "s/.*\.//"` |
---|
70 | if [ "$WSYS" = 1 \ |
---|
71 | -o "$WSYS" = 2 \ |
---|
72 | -o "$WSYS" = 3 ]; then |
---|
73 | DSYS="solaris"; |
---|
74 | else |
---|
75 | DSYS="solaris"; |
---|
76 | fi; |
---|
77 | else |
---|
78 | DSYS="sun"; |
---|
79 | fi; |
---|
80 | elif [ "$USYS" = "SUPER-UX" ]; then |
---|
81 | DSYS="nec"; |
---|
82 | elif [ "$USYS" = "ULTRIX" ]; then |
---|
83 | DSYS="ultrix"; |
---|
84 | elif [ "$USYS" = "UNICOS" \ |
---|
85 | -o "$USYS" = "sn4803" \ |
---|
86 | -o "$USYS" = "sn4602" ]; then |
---|
87 | DSYS="cray"; |
---|
88 | elif [ "$USYS" = "UNIX_System_V" ]; then |
---|
89 | DSYS="fjvpp"; |
---|
90 | else |
---|
91 | WSYS=`uname -m`; |
---|
92 | if [ "$WSYS" = "CRAY T3E" ]; then |
---|
93 | DSYS="t3e"; |
---|
94 | else |
---|
95 | DSYS="Unknown"; |
---|
96 | fi; |
---|
97 | fi; |
---|
98 | #- |
---|
99 | echo "$DSYS"; |
---|
100 | #- |
---|
101 | exit 0; |
---|