2016-12-20 11:59:08 +01:00
|
|
|
include ${SLEPC_DIR}/lib/slepc/conf/slepc_common
|
2016-12-20 16:02:23 +01:00
|
|
|
#CC=gcc
|
|
|
|
#FC = ifort
|
2018-01-28 11:16:22 +01:00
|
|
|
CLINKER = mpicc -fPIC #-wd1572 -O3 -axAVX,SSE4.2 -fno-alias -no-prec-div -no-prec-sqrt -ip
|
2016-12-20 11:59:08 +01:00
|
|
|
MAKE = /usr/bin/make
|
2016-12-20 16:02:23 +01:00
|
|
|
MKDIR_P = /bin/mkdir -p
|
|
|
|
OBJ_DIR := obj
|
|
|
|
LIB_DIR := libs
|
|
|
|
BIN_DIR := bin
|
|
|
|
SRC_DIR := src
|
2016-12-20 11:59:08 +01:00
|
|
|
|
2016-12-20 16:02:23 +01:00
|
|
|
.PHONY: ex1
|
|
|
|
|
|
|
|
ex1: ${BIN_DIR}/ex1
|
2016-12-20 11:59:08 +01:00
|
|
|
|
2016-12-20 12:03:29 +01:00
|
|
|
${OBJ_DIR}:
|
|
|
|
${MKDIR_P} ${OBJ_DIR}
|
|
|
|
|
2016-12-20 16:02:23 +01:00
|
|
|
${LIB_DIR}:
|
|
|
|
${MKDIR_P} ${LIB_DIR}
|
|
|
|
|
|
|
|
${BIN_DIR}:
|
|
|
|
${MKDIR_P} ${BIN_DIR}
|
|
|
|
|
|
|
|
directories: ${OBJ_DIR} ${LIB_DIR} ${BIN_DIR}
|
|
|
|
|
|
|
|
${LIB_DIR}/irpf90.a: directories
|
2020-03-17 10:45:45 +01:00
|
|
|
cd ${SRC_DIR} && irpf90 init && $(MAKE) irpf90.a && cp irpf90.a ../${LIB_DIR}
|
2016-12-20 12:03:29 +01:00
|
|
|
|
2018-01-28 18:41:28 +01:00
|
|
|
${OBJ_DIR}/get_ntot.o: ${SRC_DIR}/get_ntot.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
2016-12-20 16:02:23 +01:00
|
|
|
${OBJ_DIR}/read2.o: ${SRC_DIR}/read2.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
2016-12-20 11:59:08 +01:00
|
|
|
|
2018-01-28 11:16:22 +01:00
|
|
|
${OBJ_DIR}/get_s2.o: ${SRC_DIR}/get_s2.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
|
|
|
${OBJ_DIR}/get_s2_cyclic.o: ${SRC_DIR}/get_s2_cyclic.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
|
|
|
${OBJ_DIR}/get_s2_mov.o: ${SRC_DIR}/get_s2_mov.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
|
|
|
${OBJ_DIR}/get_dmat.o: ${SRC_DIR}/get_dmat.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
|
|
|
${OBJ_DIR}/get_val_iaa2.o: ${SRC_DIR}/get_val_iaa2.c directories chkopts
|
|
|
|
${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
|
|
|
|
2016-12-20 16:02:23 +01:00
|
|
|
${OBJ_DIR}/ex1.o: ${SRC_DIR}/ex1.c
|
|
|
|
-${CC} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -c -o $@ $< ${SLEPC_EPS_LIB}
|
2016-12-20 11:59:08 +01:00
|
|
|
|
2018-01-28 18:41:28 +01:00
|
|
|
${BIN_DIR}/ex1: ${OBJ_DIR}/get_ntot.o ${OBJ_DIR}/read2.o ${OBJ_DIR}/get_s2_mov.o ${OBJ_DIR}/get_s2_cyclic.o ${OBJ_DIR}/get_s2.o ${OBJ_DIR}/get_dmat.o ${OBJ_DIR}/get_val_iaa2.o ${LIB_DIR}/irpf90.a ${OBJ_DIR}/ex1.o ${SRC_DIR}/read2.h ${SRC_DIR}/get_ntot.h ${SRC_DIR}/stimsyr.h chkopts
|
2020-03-05 15:25:26 +01:00
|
|
|
-${CLINKER} ${SLEPC_INCLUDE} ${PETSC_CC_INCLUDES} -o ${BIN_DIR}/ex1 ${OBJ_DIR}/ex1.o ${OBJ_DIR}/read2.o ${OBJ_DIR}/get_ntot.o ${OBJ_DIR}/get_s2.o ${OBJ_DIR}/get_s2_mov.o ${OBJ_DIR}/get_s2_cyclic.o ${OBJ_DIR}/get_dmat.o ${OBJ_DIR}/get_val_iaa2.o ${LIB_DIR}/irpf90.a ${SLEPC_EPS_LIB}
|
2016-12-20 11:59:08 +01:00
|
|
|
# ${RM} ex1.o read2.o
|