#
#     ##################################################################
#     ##################################################################
#     ######                                                      ######
#     ######      Advanced Regional Prediction System (ARPS)      ######
#     ######                   Version 5.0                        ######
#     ######                                                      ######
#     ######                     Developed by                     ######
#     ######     Center for Analysis and Prediction of Storms     ######
#     ######                University of Oklahoma                ######
#     ######                                                      ######
#     ##################################################################
#     ##################################################################
#
#=======================================================================
#
#  PURPOSE: This makefile generates ARPS verification executables.
#
#  AUTHOR:  Jason J. Levit
#           03/15/02
#
#  Modification history:
#
#  OTHER INFORMATION:
#       See the makearps command.
#
#=======================================================================

#-----------------------------------------------------------------------
#
# Default shell
#
#-----------------------------------------------------------------------

# SHELL=/bin/csh

#-----------------------------------------------------------------------
#
# Default names of the loader and tar, can be replaced on the command
# line for other system
#
#-----------------------------------------------------------------------

FTN = f90
LDR = f90
CC  = cc

ARPS_LD = $(LDR)

TAR = tar
AWK = awk
RM  = rm
LN  = ln
AR  = ar

ARFLAG =

TOPDIR  = 
BINDIR  = $(TOPDIR)
INCLDIR = $(TOPDIR)/include
LIBDIR  = $(TOPDIR)/lib
EXTDIR  = $(TOPDIR)/src/ext2arps
VPATH   = $(EXTDIR)

#-----------------------------------------------------------------------
#
# Compiler Flag of Options. 
#
#-----------------------------------------------------------------------

FFLAGS =
FIXFLAGS  =
FREEFLAGS =
CFLAGS =
LDFLAGS =

FIXFLAGS  =
FREEFLAGS =

#-----------------------------------------------------------------------
#
# Dependencies
#
#-----------------------------------------------------------------------

.SUFFIXES: .o .c .cc .y .l .s .sh .S .ln .h .f .F .mod .sym .def .p .r .f90 .ftn .cps .C .Y .L .java .class

.f.o:
	$(FTN) $(FFLAGS) $(FIXFLAGS) -c $<
.f90.o:
	$(FTN) $(FFLAGS) $(FREEFLAGS) -c $<
.c.o:
	$(CC)  $(CFLAGS) -c $<

#-----------------------------------------------------------------------
#
# Executable to be generated by this make file:
#
#
#
#-----------------------------------------------------------------------


#-----------------------------------------------------------------------
#
# Object library to be generated for ARPS solver:
#
# LIBARPS = libarps     ARPS shared library
# LIBADAS = libadas     ADAS shared library
#
# Additional libraries needed for verification package:
#
# IPLIB = iplib         NCEP code for interpolating gridded data
#
#-----------------------------------------------------------------------
 
IPLIB   = iplib

#-----------------------------------------------------------------------
#
# Make the iplib library.
#
# 11/07/05  File "decode.f" seems to contain everything that is needed,
#           and contains later code, at least comparing the first
#           subroutine with the matching code.  Deleting all other files
#           gets rid of many warnings on LEMIEUX.  KWT
#
#-----------------------------------------------------------------------

#IPLIBOBJS = decode.o encode.o gausslat.o gcdist.o gdsawt.o gdswiz00.o \
#            gdswiz01.o gdswiz03.o gdswiz04.o gdswiz05.o    \
#            gdswizc9.o gdswizca.o gdswzd.o gdswzd00.o gdswzd01.o      \
#            gdswzd03.o gdswzd04.o gdswzd05.o gdswzdc9.o gdswizca.o    \
#            ijkgds.o ipolates.o ipolatev.o ipxetas.o         \
#            ipxwafs2.o ipxwafs.o makgds.o movect.o polateg0.o         \
#            polateg1.o polateg4.o polates0.o polates1.o polates2.o    \
#            polates3.o polates4.o polates5.o polates6.o polatev0.o    \
#            polatev1.o polatev2.o polatev3.o polatev3.o polatev4.o    \
#            polatev6.o polfixs.o polfixv.o r63w72.o w3fi63.o           \
#            w3fi68.o w3fi71.o w3fi74.o
IPLIBOBJS = decode.o

$(IPLIB): $(IPLIBOBJS)
	rm -rf $(LIBDIR)/$@.a
	$(AR) $(ARFLAG) rc $(LIBDIR)/$@.a $(IPLIBOBJS)

#-----------------------------------------------------------------------
#
# List of object codes
#
#-----------------------------------------------------------------------

#-----------------------------------------------------------------------
#
# Set Default
#
#-----------------------------------------------------------------------

#-----------------------------------------------------------------------
#
# Compile and link archive-II radar remapping executable, 88d2arps
#
#-----------------------------------------------------------------------


#-----------------------------------------------------------------------
#
# Remove the object code for individual programs
#
#-----------------------------------------------------------------------

#clean.88d2arps:

#-----------------------------------------------------------------------
#
# Object code dependency list:
#
#-----------------------------------------------------------------------

