# This is the makefile for the mesa 1D interpolation library

MESA_DIR = ../..

#################################################################

# STEP 1: set up the standard info

include $(MESA_DIR)/utils/makefile_header

#################################################################

# STEP 2: build the library

LIB = libinterp_1d.a
LIB_DEFS = interp_1d_def.o
LIB_OBJS = \
    interp_1d_misc.o interp_1d_pm.o interp_1d_mp.o \
    interp_1d_misc_sg.o interp_1d_pm_sg.o interp_1d_mp_sg.o \
    interp_1d_lib.o interp_1d_lib_sg.o

$(LIB) : $(LIB_DEFS) $(LIB_OBJS)
	$(LIB_TOOL) $(LIB) $(LIB_OBJS)
	
#################################################################

COMPILE = $(COMPILE_TO_DEPLOY) $(FCfixed)
#COMPILE = $(COMPILE_TO_TEST) $(FCfixed)

%.o: $(MOD_PUBLIC_DIR)/%.f
	$(COMPILE) $<

%.o: $(MOD_PRIVATE_DIR)/%.f
	$(COMPILE) $<

clean:
	-@rm -f *.o *.mod $(LIB)
