source: Sophya/trunk/SophyaLib/Mgr/install_peida@ 554

Last change on this file since 554 was 218, checked in by ansari, 26 years ago

Creation module DPC/Mgr Reza 9/04/99

  • Property svn:executable set to *
File size: 2.9 KB
Line 
1#!/bin/csh
2# Script d'installation PEIDA
3# Version preliminaire - Reza 27/11/97 +cmv
4
5if( "$1" == "-h" ) then
6 echo "install_peida <-s repertoire source> <-d repertoire destination>"
7 echo " [-m nom_machine-compilateur]"
8 if($?DPCDEVREP) then
9 echo " - defaut repertoire source: $DPCDEVREP"
10 else
11 echo " pas de defaut donnez explicitement le repertoire source"
12 endif
13 if($?DPCBASEREP) then
14 echo " - defaut repertoire destination: $DPCBASEREP"
15 else
16 echo " pas de defaut donnez explicitement le repertoire destination"
17 endif
18 echo " - possibilites nom_machine-compilateur"
19 echo " [AIX-xlC AIX-g++ HP-UX-aCC HP-UX-g++ OSF1-cxx OSF1-g++ Linux-g++ ...]"
20 if($?EROSCXX) then
21 echo " defaut: `uname`-$EROSCXX"
22 else
23 echo " pas de defaut donnez explicitement nom_machine-compilateur"
24 endif
25 exit -1
26endif
27
28unset srcdir
29unset dstdir
30unset macomp
31
32while( $#argv > 1 )
33 if( "$1" == "-s" ) then
34 set srcdir = $2
35 endif
36 if( "$1" == "-d" ) then
37 set dstdir = $2
38 endif
39 if( "$1" == "-m" ) then
40 set macomp = $2
41 endif
42 shift
43 shift
44end
45
46if( ! $?srcdir && $?DPCDEVREP ) then
47 echo "defaut srcdir set to DPCDEVREP"
48 set srcdir = $DPCDEVREP
49endif
50if( ! $?dstdir && $?DPCBASEREP ) then
51 echo "defaut dstdir set to DPCBASEREP"
52 set dstdir = $DPCBASEREP
53endif
54if( ! $?macomp && $?EROSCXX ) then
55 echo "defaut macomp set to uname-EROSCXX"
56 set macomp = `uname`-$EROSCXX
57endif
58
59if( ! $?srcdir || ! $?dstdir || ! $?macomp ) then
60 echo "precisez ce que vous voulez:"
61 echo srcdir=$?srcdir dstdir=$?dstdir macomp=$?macomp
62 exit -1
63else
64 set SRC = $srcdir/$macomp
65 set DST = $dstdir/$macomp
66 echo "************** PEIDA_Install script : ****************** "
67 echo "copie de $srcdir"
68 echo " vers $dstdir pour $macomp"
69 echo " pour $macomp"
70 # echo "SRC= $SRC , DST= $DST"
71 echo "********************************************************"
72endif
73
74#set DO = echo
75set DO =
76
77# d'abord les includes
78#foreach d ( Include Include/tnt Include/CInc Include/SystCxx Include/Syst )
79foreach d ( Include Include/tnt Include/CInc Include/Syst )
80 echo "PEIDA_Install: Installing $d ... "
81 if( ! -e $srcdir/$d ) then
82 echo "rep. inexistant: $SRC/$d"
83 else if( ! -e $dstdir/$d ) then
84 echo "rep. inexistant: $DST/$d"
85 else
86 cd $srcdir/$d
87 $DO cp * $dstdir/$d/.
88 $DO chmod -R a+r $dstdir/$d/
89 endif
90end
91
92# puis le reste
93foreach d ( Libs ShLibs Exec )
94 echo "PEIDA_Install: Installing $d ... "
95 if( ! -e $SRC/$d ) then
96 echo "rep. inexistant: $SRC/$d"
97 else if( ! -e $DST/$d ) then
98 echo "rep. inexistant: $DST/$d"
99 else
100 if( "$d" == "Exec" ) then
101 foreach f ( stars++ assocbr++ synth++ spiapp piapp )
102 if( -e $SRC/$d/$f ) then
103 $DO cp $SRC/$d/$f $DST/$d/.
104 endif
105 end
106 $DO chmod -R a+x $DST/$d/
107 else
108 cd $SRC/$d/.
109 $DO cp * $DST/$d/.
110 endif
111 $DO chmod -R a+r $DST/$d/
112 endif
113end
114
115echo 'PEIDA_Install complete'
116
117exit 0
Note: See TracBrowser for help on using the repository browser.