--- MITgcm/tools/genmake 2002/02/11 21:52:31 1.60 +++ MITgcm/tools/genmake 2002/03/04 17:26:41 1.62 @@ -1,6 +1,6 @@ #!/bin/csh -f # -# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/tools/Attic/genmake,v 1.60 2002/02/11 21:52:31 heimbach Exp $ +# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/tools/Attic/genmake,v 1.62 2002/03/04 17:26:41 adcroft Exp $ # $Name: $ # # Makefile generator for MITgcm UV codes @@ -9,7 +9,7 @@ # modified by aja 01/00 # Default lists -set DISABLE = ( aim autodiff cal cost ctrl ecco exf grdchk flt ) +set DISABLE = ( aim autodiff cal cost ctrl ecco exf grdchk flt ptracers ) set DEFINES = ( ) set ENABLE = ( ) set MODS = ( ) @@ -257,6 +257,12 @@ echo Adding pkg dir: $adr set SOURCEDIRS = ($SOURCEDIRS $adr) set INCLUDEDIRS = ($INCLUDEDIRS $adr) + switch ($dr) + case ptracers: + set DEFINES = ($DEFINES '-DALLOW_PTRACERS'); breaksw + default: + breaksw + endsw else echo " *" Package \"$dr\" NOT enabled. switch ($dr) @@ -291,6 +297,7 @@ set KPP = ( ) set FC = ( 'f77' ) set LINK = ( 'f77' ) +set MAKEDEPEND = ( 'makedepend' ) set INCLUDES = ( -I. ) set FFLAGS = ( ) set FOPTIM = ( ) @@ -393,6 +400,7 @@ case SunOS: set LN = ( '/usr/bin/ln -s' ) set CPP = ( '/usr/ccs/lib/cpp -P' ) + set MAKEDEPEND = ( ${TOOLSDIR}/xmakedepend ) set DEFINES = ( ${DEFINES} '-DTARGET_SUN -DWORDLENGTH=4 -D_d=E' ) set FFLAGS = ( '-stackvar -explicitpar -vpara -e -u -noautopar -xtypemap=real:64,double:64,integer:32 -fsimple=0' ) set FOPTIM = ( '-dalign -O3 -xarch=v9' ) @@ -535,7 +543,7 @@ '-bmaxdata:0x80000000 ' ) set LDFLAGS = ( '-O3 -qarch=pwr3 -qtune=pwr3 -qcache=auto -qmaxmem=-1' \ '-bmaxdata:0x80000000' ) - set LIBS = ( ' timer_stats.o -L/usr/local/apps/mass -lmass' ) + set LIBS = ( ' -L/usr/local/apps/mass -lmass' ) # set FFLAGS = ( '-extend_source -mp -mpio -bytereclen -r10000 -mips4' ) # set FOPTIM = ( '-O3' ) # set NOOPTFLAGS = ( '-O0' ) @@ -634,6 +642,7 @@ # CPP : C-preprocessor command # INCLUDES : Directories searched for header files # DEFINES : Macro definitions for CPP +# MAKEDEPEND : Dependency generator # KPP : Special preprocessor command (specific to platform) # KFLAGS : Flags for KPP # FC : Fortran compiler command @@ -692,6 +701,8 @@ LN = ${LN} # C preprocessor CPP = cat \$< | ${S64} | ${CPP} +# Dependency generator +MAKEDEPEND = ${MAKEDEPEND} # Special preprocessor (KAP on DECs, FPP on Crays) KPP = ${KPP} # Fortran compiler @@ -737,7 +748,7 @@ \$(LINK) -o \$@ \$(FFLAGS) \$(FOPTIM) \$(OBJFILES) \$(LIBS) depend: @make links - ../tools/makedepend -o .f \$(DEFINES) \$(INCLUDES) \$(SRCFILES) + \$(MAKEDEPEND) -o .f \$(DEFINES) \$(INCLUDES) \$(SRCFILES) links: \$(SRCFILES) \$(CSRCFILES) \$(HEADERFILES)