4
command=`echo $input | sed 's/^\([^ ]*\).*/\1/g'`
8
# Filter, copying files:
13
# -.-.dir/ --> [-.-.dir]
22
-e 's/ \([-\.][-\.]*[^\/]*\)\// \[\1\]/g' \
26
# rm) entry remove because it is not needed any more. CG 301089
28
## Filter removing files in directories:
30
## tabs --> single blank
34
## file.o --> file.obj;*
35
## file.exe--> file.exe;*
36
## file.a --> file.obl;*
38
# -e 's/[ ][ ]*/ /g' \
41
# -e 's/[^ ]*\.f //g' \
43
# -e 's/^rm/\$ DELETE/' \
44
# -e 's/\.o[ ]*/.obj;*,/g' \
45
# -e 's/\.exe[ ]*/.exe;*,/g' \
46
# -e 's/\.a[ ]*/.olb;*,/g' \
47
# -e 's/\.c[ ]*/.c;*,/g' \
48
# -e 's/\.for[ ]*/.for;*,/g' \
49
# -e 's/\.h[ ]*/.h;*,/g' \
54
# Filter compiling "C" files in directories:
56
# tabs --> single blank
61
# pl*.* --> pl*_* (eg. pl2.1 in pl2_1)
63
# -Ddef --> /DEFINE=(def
65
# /DEFINE* --> /DEFINE=(*)
66
# -Iinclude_R4 --> (null)
68
# -Idir --> /INCLUDE=([dir]
70
# /DEFINE* --> /DEFINE=(*)
76
# [*midas.<rels> --> ['MIDASHOME'.'MIDVERS'
83
-e 's/ -I\.\// -I\./g' \
85
-e 's/pl\(.\)\./pl\1_/' \
87
-e 's/-D/\/DEFINE=\(/' \
89
-e 's/DEFINE[^ ]*/&\)/' \
90
-e 's/ -I[^ ]*include_R4 / /g' \
92
-e 's/ -I\([^ ]*\)/ \/INCLUDE=\(\[\1\]/' \
93
-e 's/ -I\([^ ]*\)/,\[\1\]/g' \
94
-e 's/INCLUDE[^ ]*/&\)/' \
100
-e 's/\[[^,]*midas\.[^\.]*/\['\''MIDASHOME'\''.'\''MIDVERS'\''/g'
104
# Filter compiling fortran files in directories:
114
echo $input | sed -e 's/^f77/\$ FORTRAN/' \
121
# Filter generating libraries files in directories:
123
# ar --> $ LIB/REPLACE
125
# dirs/lib.a --> lib.a
127
# file1.o file2.o --> file1,file2
128
echo $input | sed -e 's/^ar[ ]*ruv/\$ LIB\/REPLACE/' \
129
-e 's/[ ][\.\/]*/ /g' \
130
-e 's/REPLACE .*\/\(.*\)/REPLACE \1/' \
132
-e 's/\.o[ ]*/\.obj,/g' \
136
# Filter linking files in directories:
138
# tabs --> single blank
141
# file.opt --> file/OPT,
142
# file.o --> file.obj,
143
# lib1.a lib2.a --> lib1/L, lib2/L
144
# ldvms * -o dir.file.exe --> $ LINK/NOMAP/EXE=[dir]
145
# -o *exec/file.exe --> (null)
148
# libtermcap/L --> (null)
149
# libreadline/L --> (null)
150
# libsocket/L --> (null)
151
# libnsl/L --> (null)
153
# -.dir.file.obj --> [-.dir.]file.obj
155
echo $input | sed -e 's/[ ][ ]*/ /g' \
158
-e 's/\.opt /\/OPT, /g' \
159
-e 's/\.o /\.obj, /g' \
160
-e 's/\.a /\/L, /g' \
161
-e 's/^ldvms \(.*\) -o [^\.-]*\.exe/$ LINK\/NOMAP \1/' \
162
-e 's/^ldvms \(.*\) -o \(.*\)\.[^\.]*\.exe/$ LINK\/NOMAP\/EXE=\[\2\] \1/' \
163
-e 's/\(.*\)NOMAP\(.*OPT.*\)/\1NOTRACE\2/' \
164
-e 's/[-\.][-\.]*lib\.//g' \
166
-e 's/ -l\([^ ]*\)/ lib\1\/L,/g' \
168
-e 's/libtermcap\/L,//g' \
169
-e 's/libreadline\/L,//g' \
170
-e 's/libsocket\/L,//g' \
171
-e 's/libnsl\/L,//g' \
174
-e 's/ \(-.*\)\.\([^\.-]*\.obj\)/ \[\1\]\2/g' \
179
# Filter compiling macros files in directories:
182
echo $input | sed -e 's/^macro/\$ MACRO/'
185
# Filter for UNIX filter esoext.exe
188
# Filter for other executables:
189
# It removes ftoc_names.exe` argument for FORIF command
190
# It removes ftoc_vmr.exe` argument for FORIF command
192
# tabs --> single blank
193
# `*ftoc_names.exe` --> blank
194
# `*ftoc_vmr` --> blank
196
# (blank)./ --> blank/
200
# rel_dir/file.exe --> [.rel_dir]file
201
# abs_dir/file.exe --> [abs_dir]file
203
# [.*]file --> $ file
207
-e 's/ `[^ ]*ftoc_names.exe` / /'g \
208
-e 's/ `[^ ]*ftoc_vmr` / /'g \
214
-e 's/\([^ ]*\)\.\([^ ]*\).exe/[\1]\2/g' \
217
-e 's/^\[[^ ]*\]//' \
223
# Filter "ranlib" and "esoext" files in directories:
226
# echo $input | sed -e 's/^.*$//'