1 |
#!/bin/csh -f |
#!/bin/csh -f |
2 |
# |
# |
3 |
# $Header$ |
# $Header$ |
4 |
|
# $Name$ |
5 |
# |
# |
6 |
# Makefile generator for MITgcm UV codes |
# Makefile generator for MITgcm UV codes |
7 |
# created by cnh 03/98 |
# created by cnh 03/98 |
9 |
# modified by aja 01/00 |
# modified by aja 01/00 |
10 |
|
|
11 |
# Default lists |
# Default lists |
12 |
set DISABLE = ( aim ) |
set DISABLE = ( aim autodiff cal cost ctrl ecco exf grdchk ) |
13 |
|
set DEFINES = ( ) |
14 |
set ENABLE = ( ) |
set ENABLE = ( ) |
15 |
set MODS = ( ) |
set MODS = ( ) |
16 |
|
|
78 |
echo "-enable overrides -disable, ie. a package listed in both is enabled" |
echo "-enable overrides -disable, ie. a package listed in both is enabled" |
79 |
exit |
exit |
80 |
breaksw |
breaksw |
81 |
|
case -ieee: |
82 |
|
set IEEE |
83 |
|
breaksw |
84 |
case -enable=*: |
case -enable=*: |
85 |
set ENABLE = ( $ENABLE `echo $arg | sed 's/-enable=//' | sed 's/,/ /g' `) |
set ENABLE = ( $ENABLE `echo $arg | sed 's/-enable=//' | sed 's/,/ /g' `) |
86 |
breaksw |
breaksw |
93 |
echo "Including paths to JAM libraries" |
echo "Including paths to JAM libraries" |
94 |
breaksw |
breaksw |
95 |
case -help: |
case -help: |
96 |
echo "usage: $0 [-help] [-makefile[=...]] [-platform=...] [-mpi]" |
echo "usage: $0 [-help] [-makefile[=...]] [-platform=...] [-mpi] [-jam] [-disable=pkg1[,pkg2,...]] [-enable=pkg1[,pkg2,...]] [-mods=dir1[,dir2,...]] [-rootdir=dir]" |
97 |
|
cat << EOF |
98 |
|
|
99 |
|
$0 is used to generate the Makefile in the current directory. |
100 |
|
|
101 |
|
Typical invocations are: |
102 |
|
o from "bin": ../tools/genmake |
103 |
|
o from "verification/expt/code": ../../../tools/genmake |
104 |
|
o from "verification/expt/input": ../../../tools/genmake -mods=../code |
105 |
|
o from a scratch directory: ~/mitgcm/tools/genmake -rootdir=~/mitgcm |
106 |
|
or ~/mitgcm/tools/genmake -rootdir=~/mitgcm -mods=~/mymods |
107 |
|
|
108 |
|
Packages (collected modules of code) can be disabled to avoid unnecessary |
109 |
|
compilation of unused code. For instance if you know you will not |
110 |
|
use GM/Redi, KPP and OBCS and they are appropriate turned-off in the |
111 |
|
configuration: |
112 |
|
.../tools/genmake -disable=gmredi,kpp,obcs |
113 |
|
|
114 |
|
If you add some source files you can re-call the previous instance of |
115 |
|
genmake with "make makefile". |
116 |
|
|
117 |
|
genmake also reads the file .genmakerc which can be used to configure |
118 |
|
options (primarily the command-line options above) for particular experiments. |
119 |
|
EOF |
120 |
exit |
exit |
121 |
breaksw |
breaksw |
122 |
default: |
default: |
140 |
set mach = ( `uname -a` ) |
set mach = ( `uname -a` ) |
141 |
echo Operating system: $mach |
echo Operating system: $mach |
142 |
|
|
|
|
|
143 |
# Directories for source, includes, binaries and executables |
# Directories for source, includes, binaries and executables |
144 |
# |
# |
145 |
# If -rootdir wasn't specified then assume script is being run from bin |
# If -rootdir wasn't specified then assume script is being run from bin |
146 |
# but if it was supplied then we should place the executable in the build dir |
# but if it was supplied then we should place the executable in the build dir |
147 |
if (! $?ROOTDIR) then |
if (! $?ROOTDIR) then |
148 |
set ROOTDIR = ( .. ) |
set pwd=`pwd` |
149 |
else |
if ($pwd:t == bin & -d ../model & -d ../eesupp & -d ../pkg) then |
150 |
if (! $?EXEDIR) set EXEDIR = ( . ) |
set ROOTDIR = ( .. ) |
151 |
|
endif |
152 |
|
endif |
153 |
|
# Scan for logical ROOTDIR |
154 |
|
if (! $?ROOTDIR) then |
155 |
|
foreach dr (. .. ../.. ../../.. ../../../.. ../../../../..) |
156 |
|
if (-d $dr/model & -d $dr/eesupp & -d $dr/pkg) then |
157 |
|
set ROOTDIR = $dr |
158 |
|
echo ROOTDIR was not specified. Setting ROOTDIR = \"$ROOTDIR\" |
159 |
|
break |
160 |
|
endif |
161 |
|
end |
162 |
|
endif |
163 |
|
if (! $?ROOTDIR) then |
164 |
|
echo Root directory was not specified and could not be determined. |
165 |
|
echo Specify the root location of the model source with -rootdir=dir |
166 |
|
exit 1 |
167 |
endif |
endif |
168 |
if (! -d $ROOTDIR) then |
if (! -d $ROOTDIR) then |
169 |
echo Root directory $ROOTDIR not found.;exit 1 |
echo Root directory $ROOTDIR not found.;exit 1 |
172 |
# source code in the standard directories |
# source code in the standard directories |
173 |
if (! $?MODS) then |
if (! $?MODS) then |
174 |
set SOURCEDIRS = ( ) |
set SOURCEDIRS = ( ) |
175 |
set INCLUDEDIRS = ( . ) |
set INCLUDEDIRS = ( ) |
176 |
else |
else |
177 |
set SOURCEDIRS = ( $MODS ) |
set SOURCEDIRS = ( $MODS ) |
178 |
set INCLUDEDIRS = ( . $MODS ) |
set INCLUDEDIRS = ( $MODS ) |
179 |
endif |
endif |
180 |
if (! $?BUILDDIR) set BUILDDIR = ( . ) |
if (! $?BUILDDIR) set BUILDDIR = ( . ) |
181 |
if (! -d $BUILDDIR) then |
if (! -d $BUILDDIR) then |
182 |
echo Build directory $BUILDDIR not found.;exit 1 |
echo Build directory $BUILDDIR not found.;exit 1 |
183 |
endif |
endif |
184 |
if (! $?EXEDIR) set EXEDIR = ( $ROOTDIR/exe ) |
if (! $?EXEDIR) then |
185 |
|
set pwd=`pwd` |
186 |
|
if ($pwd:t == bin & -d ../exe & $ROOTDIR == ..) then |
187 |
|
set EXEDIR = ( ../exe ) |
188 |
|
else |
189 |
|
set EXEDIR = ( . ) |
190 |
|
endif |
191 |
|
endif |
192 |
if (! -d $EXEDIR) then |
if (! -d $EXEDIR) then |
193 |
echo Executable directory $EXEDIR not found.;exit 1 |
echo Executable directory $EXEDIR not found.;exit 1 |
194 |
endif |
endif |
198 |
endif |
endif |
199 |
if (! $?EXECUTABLE) set EXECUTABLE = ( mitgcmuv ) |
if (! $?EXECUTABLE) set EXECUTABLE = ( mitgcmuv ) |
200 |
|
|
201 |
|
# We have a special set of source files in eesupp/src which |
202 |
|
# are generated from some template source files. We'll make them |
203 |
|
# first so the appear as regular source code |
204 |
|
if (-r $ROOTDIR/eesupp/src/Makefile) then |
205 |
|
echo Making source files in eesupp from templates... |
206 |
|
(cd $ROOTDIR/eesupp/src/; make) >& make_eesupp.errs |
207 |
|
if ($status == 0) then |
208 |
|
rm -f make_eesupp.errs |
209 |
|
else |
210 |
|
cat make_eesupp.errs |
211 |
|
exit 2 |
212 |
|
endif |
213 |
|
endif |
214 |
|
|
215 |
# Now scan the standard source code tree |
# Now scan the standard source code tree |
216 |
foreach dr ($SOURCEDIRS) |
foreach dr ($SOURCEDIRS) |
217 |
set adr=$dr |
set adr=$dr |
218 |
if (! -d $adr) then |
if (! -d $adr) then |
219 |
echo mods directory $adr not found.; exit 1 |
echo mods directory $adr not found.; exit 1 |
220 |
endif |
endif |
221 |
echo Adding mods directory $adr |
echo Adding mods dir: $adr |
|
end |
|
|
if (! $?STANDARDDIRS) set STANDARDDIRS=(eesupp model diags) |
|
|
foreach dr ($STANDARDDIRS) |
|
|
set adr=$ROOTDIR/$dr/src |
|
|
if (! -d $adr) then |
|
|
echo Source directory $adr not found.; exit 1 |
|
|
endif |
|
|
echo Adding source directory $adr |
|
|
set SOURCEDIRS = ($SOURCEDIRS $adr) |
|
|
set idr = `echo $adr | sed 's/src/inc/'` |
|
|
set INCLUDEDIRS = ($INCLUDEDIRS $idr) |
|
222 |
end |
end |
223 |
if (! $?PACKAGES) then |
if (! $?PACKAGES) then |
224 |
set PACKAGES=(`cd $ROOTDIR/pkg; ls -1 | grep -v CVS`) |
set PACKAGES=() |
225 |
|
foreach pkg (`cd $ROOTDIR/pkg; find . -type d | grep -v CVS | sed 's:\./::' | grep -v "\." | sort`) |
226 |
|
if (-d $ROOTDIR/pkg/$pkg) set PACKAGES=($PACKAGES $pkg) |
227 |
|
end |
228 |
endif |
endif |
229 |
foreach dr ($PACKAGES) |
foreach dr ($PACKAGES) |
230 |
set enable |
set enable |
231 |
foreach p ($DISABLE) |
foreach p ($DISABLE) |
232 |
|
if ($p != 'all' & ! -d $ROOTDIR/pkg/$p) then |
233 |
|
echo Specified package \"$p\" does not exist. |
234 |
|
exit 1 |
235 |
|
endif |
236 |
if ($dr == $p) unset enable |
if ($dr == $p) unset enable |
237 |
if ($p == 'all') unset enable |
if ($p == 'all') unset enable |
238 |
|
# The following allows entire trees to be disabled |
239 |
|
if ($dr:h == $p) unset enable |
240 |
|
if ($dr:h:h == $p) unset enable |
241 |
|
if ($dr:h:h:h == $p) unset enable |
242 |
|
if ($dr:h:h:h:h == $p) unset enable |
243 |
end |
end |
244 |
foreach p ($ENABLE) |
foreach p ($ENABLE) |
245 |
if ($dr == $p) set enable |
if ($dr == $p) set enable |
249 |
if (! -d $adr) then |
if (! -d $adr) then |
250 |
echo Source directory $adr not found.; exit 1 |
echo Source directory $adr not found.; exit 1 |
251 |
endif |
endif |
252 |
echo Adding package directory $adr |
echo Adding pkg dir: $adr |
253 |
set SOURCEDIRS = ($SOURCEDIRS $adr) |
set SOURCEDIRS = ($SOURCEDIRS $adr) |
254 |
set INCLUDEDIRS = ($INCLUDEDIRS $adr) |
set INCLUDEDIRS = ($INCLUDEDIRS $adr) |
255 |
else |
else |
256 |
echo "*" Package \"$dr\" has not been enabled. |
echo " *" Package \"$dr\" NOT enabled. |
257 |
|
switch ($dr) |
258 |
|
case mom_fluxform: |
259 |
|
set DEFINES = ($DEFINES '-DDISABLE_MOM_FLUXFORM'); breaksw |
260 |
|
case mom_vecinv: |
261 |
|
set DEFINES = ($DEFINES '-DDISABLE_MOM_MOMVECINV'); breaksw |
262 |
|
default: |
263 |
|
breaksw |
264 |
|
endsw |
265 |
|
endif |
266 |
|
end |
267 |
|
if (! $?STANDARDDIRS) set STANDARDDIRS=(eesupp model) |
268 |
|
foreach dr ($STANDARDDIRS) |
269 |
|
set adr=$ROOTDIR/$dr/src |
270 |
|
if (! -d $adr) then |
271 |
|
echo Source directory $adr not found.; exit 1 |
272 |
endif |
endif |
273 |
|
echo Adding src dir: $adr |
274 |
|
set SOURCEDIRS = ($SOURCEDIRS $adr) |
275 |
|
set idr = `echo $adr | sed 's/src/inc/'` |
276 |
|
set INCLUDEDIRS = ($INCLUDEDIRS $idr) |
277 |
end |
end |
278 |
|
|
279 |
# This is the generic configuration. |
# This is the generic configuration. |
283 |
set KPP = ( ) |
set KPP = ( ) |
284 |
set FC = ( 'f77' ) |
set FC = ( 'f77' ) |
285 |
set LINK = ( 'f77' ) |
set LINK = ( 'f77' ) |
286 |
set DEFINES = ( ) |
set INCLUDES = ( -I. ) |
|
set INCLUDES = ( ) |
|
287 |
set FFLAGS = ( ) |
set FFLAGS = ( ) |
288 |
set FOPTIM = ( ) |
set FOPTIM = ( ) |
289 |
set KFLAGS1 = ( ) |
set KFLAGS1 = ( ) |
305 |
|
|
306 |
# Platform specific options |
# Platform specific options |
307 |
switch ($platform$USEMPI) |
switch ($platform$USEMPI) |
|
case OSF1: |
|
308 |
case OSF1+mpi: |
case OSF1+mpi: |
309 |
|
echo "Configuring for DEC Alpha with MPI" |
310 |
|
set LIBS = ( '-lfmpi -lmpi -lkmp_osfp10 -pthread' ) |
311 |
|
case OSF1: |
312 |
echo "Configuring for DEC Alpha" |
echo "Configuring for DEC Alpha" |
313 |
set CPP = ( '/usr/bin/cpp -P' ) |
set CPP = ( '/usr/bin/cpp -P' ) |
314 |
set DEFINES = ( ${DEFINES} '-DTARGET_DEC -DWORDLENGTH=1' ) |
set DEFINES = ( ${DEFINES} '-DTARGET_DEC -DWORDLENGTH=1' ) |
315 |
set KPP = ( 'kapf' ) |
set KPP = ( ) |
316 |
set KPPFILES = ( 'main.F' ) |
set KPPFILES = ( ) |
317 |
set KFLAGS1 = ( '-scan=132 -noconc -cmp=' ) |
set KFLAGS1 = ( ) |
318 |
set FC = ( 'f77' ) |
set FC = ( 'f77' ) |
319 |
set FFLAGS = ( '-convert big_endian -r8 -extend_source -automatic -call_shared -notransform_loops -align dcommons' ) |
set FFLAGS = ( '-convert big_endian -r8 -extend_source -automatic -call_shared -notransform_loops -align dcommons' ) |
320 |
set FOPTIM = ( '-O5 -fast -tune host -inline all' ) |
set FOPTIM = ( '-O5 -fast -tune host -inline all' ) |
321 |
set NOOPTFLAGS = ( '-O0' ) |
set NOOPTFLAGS = ( '-O0' ) |
|
set LIBS = ( '-lfmpi -lmpi -lkmp_osfp10 -pthread' ) |
|
322 |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F') |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F') |
323 |
set RMFILES = ( '*.p.out' ) |
set RMFILES = ( '*.p.out' ) |
324 |
breaksw |
breaksw |
336 |
echo "Configuring for SGI Mips" |
echo "Configuring for SGI Mips" |
337 |
set DEFINES = ( ${DEFINES} '-DTARGET_SGI -DWORDLENGTH=4' ) |
set DEFINES = ( ${DEFINES} '-DTARGET_SGI -DWORDLENGTH=4' ) |
338 |
set INCLUDES = ( '-I/usr/local/mpi/include' ) |
set INCLUDES = ( '-I/usr/local/mpi/include' ) |
339 |
set FFLAGS = ( '-extend_source -mp -mpio -bytereclen -r10000 -mips4' ) |
set FFLAGS = ( '-extend_source -mp -mpio -bytereclen -r10000 -mips4 -r8 -static' ) |
340 |
set FOPTIM = ( '-O3' ) |
set FOPTIM = ( '-O3' ) |
341 |
# set NOOPTFLAGS = ( '-O0' ) |
# set NOOPTFLAGS = ( '-O0' ) |
342 |
# set NOOPTFILES = ( 'barrier.F different_multiple.F ' \ |
# set NOOPTFILES = ( 'barrier.F different_multiple.F ' \ |
388 |
set FFLAGS = ( '-stackvar -explicitpar -vpara -e -u -noautopar') |
set FFLAGS = ( '-stackvar -explicitpar -vpara -e -u -noautopar') |
389 |
set FOPTIM = ( '-fast -O3' ) |
set FOPTIM = ( '-fast -O3' ) |
390 |
set NOOPTFLAGS = ( '-O0' ) |
set NOOPTFLAGS = ( '-O0' ) |
391 |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F ini_vertical_grid.F') |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F ini_vertical_grid.F ini_spherical_polar_grid.F ini_cori.F mon_printstats_rl.F mon_printstats_rs.F') |
392 |
breaksw |
breaksw |
393 |
case SunOS+mpi: |
case SunOS+mpi: |
394 |
set LN = ( '/usr/bin/ln -s' ) |
set LN = ( '/usr/bin/ln -s' ) |
400 |
set NOOPTFLAGS = ( '-O0' ) |
set NOOPTFLAGS = ( '-O0' ) |
401 |
set LIBS = ( '-L/usr/local/mpi/lib/solaris/ch_shmem -lmpi -lthread' \ |
set LIBS = ( '-L/usr/local/mpi/lib/solaris/ch_shmem -lmpi -lthread' \ |
402 |
'-lsocket -lnsl' ) |
'-lsocket -lnsl' ) |
403 |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F ini_vertical_grid.F') |
set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F ini_vertical_grid.F ini_spherical_polar_grid.F ini_cori.F mon_printstats_rl.F mon_printstats_rs.F') |
404 |
breaksw |
breaksw |
405 |
case IRIX32: |
case IRIX32: |
406 |
echo "Configuring for SGI ONYX running IRIX64" |
echo "Configuring for SGI ONYX running IRIX64" |
437 |
set DEFINES = ( ${DEFINES} '-D_BYTESWAPIO -DWORDLENGTH=4' ) |
set DEFINES = ( ${DEFINES} '-D_BYTESWAPIO -DWORDLENGTH=4' ) |
438 |
set FC = ( 'g77' ) |
set FC = ( 'g77' ) |
439 |
set FFLAGS = ( '-Wimplicit -Wunused -Wuninitialized' ) |
set FFLAGS = ( '-Wimplicit -Wunused -Wuninitialized' ) |
440 |
set FOPTIM = ( '-O3 -malign-double -funroll-loops ' ) |
if ($?IEEE) set FFLAGS = ( $FFLAGS '-ffloat-store' ) |
441 |
|
set FOPTIM = ( '-O3 -malign-double -funroll-loops' ) |
442 |
set LINK = ( 'g77' ) |
set LINK = ( 'g77' ) |
443 |
breaksw |
breaksw |
444 |
case Linux+pgi+mpi: |
case Linux+pgi+mpi: |
445 |
if ($?include_jam_libs) then |
if ($?include_jam_libs) then |
446 |
set INCLUDES = ( '-I/usr/local//mpich-cnh-install/include' ) |
set INCLUDES = ( '-I/usr/local/mpich-1.2.1/pgi_fortran_binding/include' ) |
447 |
set LIBS = ( '-L/usr/local/mpich-cnh-install/lib/LINUX/ch_p4/ -lfmpich -lmpich' ) |
set LIBS = ( '-L/usr/local/mpich-1.2.1/pgi_fortran_binding/lib/ -lfmpich -lmpich' ) |
448 |
else |
else |
449 |
set INCLUDES = ( '-I/usr/local/include' ) |
set INCLUDES = ( '-I/usr/local/include' ) |
450 |
set LIBS = ( '-L/usr/local/lib/LINUX/ch_p4/ -lfmpich -lmpich' ) |
set LIBS = ( '-L/usr/local/lib/LINUX/ch_p4/ -lfmpich -lmpich' ) |
514 |
echo "" >> srclinks.tmp |
echo "" >> srclinks.tmp |
515 |
echo -n 'SRCFILES = ' > srclist.inc |
echo -n 'SRCFILES = ' > srclist.inc |
516 |
echo -n 'CSRCFILES = ' > csrclist.inc |
echo -n 'CSRCFILES = ' > csrclist.inc |
517 |
#echo -n 'HEADERFILES = ' > hlist.inc |
echo -n 'HEADERFILES = ' > hlist.inc |
518 |
foreach dr ($SOURCEDIRS) |
foreach dr ($SOURCEDIRS $INCLUDEDIRS .) |
519 |
set deplist=( ) |
set deplist=( ) |
520 |
foreach srcfile (`cd $dr; ls *.[hcF]`) |
foreach srcfile (`cd $dr; ls *.[hcF]`) |
521 |
if (! -r .links.tmp/$srcfile) then |
if (! -r .links.tmp/$srcfile) then |
534 |
echo -n " " $srcfile >> csrclist.inc |
echo -n " " $srcfile >> csrclist.inc |
535 |
breaksw |
breaksw |
536 |
case h: |
case h: |
537 |
# touch .links.tmp/$srcfile |
touch .links.tmp/$srcfile |
538 |
# set deplist=($deplist $srcfile) |
set deplist=($deplist $srcfile) |
539 |
# echo ' \' >> hlist.inc |
echo ' \' >> hlist.inc |
540 |
# echo -n " " $srcfile >> hlist.inc |
echo -n " " $srcfile >> hlist.inc |
541 |
breaksw |
breaksw |
542 |
endsw |
endsw |
543 |
endif |
endif |
552 |
rm -rf .links.tmp |
rm -rf .links.tmp |
553 |
echo "" >> srclist.inc |
echo "" >> srclist.inc |
554 |
echo "" >> csrclist.inc |
echo "" >> csrclist.inc |
555 |
#echo "" >> hlist.inc |
echo "" >> hlist.inc |
556 |
|
|
557 |
set THISHOSTNAME = ( `hostname` ) |
set THISHOSTNAME = ( `hostname` ) |
558 |
set THISCWD = ( `pwd` ) |
set THISCWD = ( `pwd` ) |
606 |
# extra stuff for Hyades ............................................ |
# extra stuff for Hyades ............................................ |
607 |
HYADES_DIR = /u/u0/cnh/jam-lib/software |
HYADES_DIR = /u/u0/cnh/jam-lib/software |
608 |
HYADES_DIR = /u/u0/cnh/jam-lib-twoproc |
HYADES_DIR = /u/u0/cnh/jam-lib-twoproc |
609 |
|
HYADES_DIR = /usr/local/jamlib/current/dual_proc |
610 |
WORK_DIR = \$(HYADES_DIR) |
WORK_DIR = \$(HYADES_DIR) |
611 |
DEPOSIT_DIR = linux_bin |
DEPOSIT_DIR = linux_bin |
612 |
|
|
666 |
|
|
667 |
cat srclist.inc >> ${mfile} |
cat srclist.inc >> ${mfile} |
668 |
cat csrclist.inc >> ${mfile} |
cat csrclist.inc >> ${mfile} |
669 |
|
cat hlist.inc >> ${mfile} |
670 |
echo 'F77FILES = $(SRCFILES:.F=.f)' >> ${mfile} |
echo 'F77FILES = $(SRCFILES:.F=.f)' >> ${mfile} |
671 |
echo 'OBJFILES = $(SRCFILES:.F=.o) $(CSRCFILES:.c=.o)' >> ${mfile} |
echo 'OBJFILES = $(SRCFILES:.F=.o) $(CSRCFILES:.c=.o)' >> ${mfile} |
672 |
|
|
673 |
rm -f srclist.inc csrclist.inc flist.tmp clist.tmp |
rm -f srclist.inc csrclist.inc hlist.inc flist.tmp clist.tmp |
674 |
|
|
675 |
cat >> ${mfile} <<EOF |
cat >> ${mfile} <<EOF |
676 |
|
|
683 |
depend: |
depend: |
684 |
@make links |
@make links |
685 |
makedepend -o .f \$(INCLUDES) \$(SRCFILES) |
makedepend -o .f \$(INCLUDES) \$(SRCFILES) |
686 |
links: \$(SRCFILES) |
|
687 |
|
links: \$(SRCFILES) \$(CSRCFILES) \$(HEADERFILES) |
688 |
|
|
689 |
small_f: \$(F77FILES) |
small_f: \$(F77FILES) |
690 |
|
|
691 |
|
output.txt: \$(EXECUTABLE) |
692 |
|
@echo -n "running ... " |
693 |
|
@\$(EXECUTABLE) > \$@ |
694 |
|
|
695 |
clean: |
clean: |
696 |
-rm -rf *.o *.f *.p ${RMFILES} |
-rm -rf *.o *.f *.p ${RMFILES} |
697 |
Clean: |
Clean: |
698 |
@make clean |
@make clean |
699 |
-find . -type l -exec rm {} \; |
@make cleanlinks |
700 |
-rm -f Makefile.bak |
-rm -f Makefile.bak |
701 |
CLEAN: |
CLEAN: |
702 |
@make Clean |
@make Clean |
703 |
-find \$(ROOTDIR) -name "*.meta" -exec rm {} \; |
-find \$(EXEDIR) -name "*.meta" -exec rm {} \; |
704 |
-find \$(ROOTDIR) -name "*.data" -exec rm {} \; |
-find \$(EXEDIR) -name "*.data" -exec rm {} \; |
705 |
-rm -f \$(EXECUTABLE) |
-rm -f \$(EXECUTABLE) |
706 |
|
|
707 |
|
makefile: |
708 |
|
${0} $argv |
709 |
|
cleanlinks: |
710 |
|
-find . -type l -exec rm {} \; |
711 |
|
|
712 |
# The normal chain of rules is ( .F - .f - .o ) |
# The normal chain of rules is ( .F - .f - .o ) |
713 |
.F.f: |
.F.f: |
714 |
\$(CPP) \$(DEFINES) \$(INCLUDES) > \$@ |
\$(CPP) \$(DEFINES) \$(INCLUDES) > \$@ |