mirror of
https://github.com/TREX-CoE/Sherman-Morrison.git
synced 2024-08-25 06:31:44 +02:00
![François Coppens](/assets/img/avatar_default.png)
decomposition in the Fortran code and made a basic call to the subroutine MYSUBROUTINE, which is bound to the C++ void function 'Sherman-Morrison();. For now compilation fails with lots of undefined references.'
40 lines
969 B
Makefile
40 lines
969 B
Makefile
CXX=icpc
|
|
CXXFLAGS=-O0 -debug full -traceback
|
|
FC=ifort
|
|
FFLAGS=-O0 -debug full -traceback
|
|
# ARCH=-xCORE-AVX2
|
|
|
|
## Deps & objs for the C++ stuff
|
|
cppDEPS = cppmain.cpp SM_MaponiA3.cpp SM_MaponiA3.hpp Helpers.hpp
|
|
cppOBJ = cppmain.o SM_MaponiA3.o
|
|
|
|
## Deps & objs for the Fortran stuff
|
|
fDEPS = fmain.f90 SM_MaponiA3_mod.f90
|
|
fOBJ = SM_MaponiA3.o SM_MaponiA3_mod.o fmain.o
|
|
|
|
## Compile recipes for C++ stuff
|
|
%.o: %.cpp $(cppDEPS)
|
|
$(CXX) $(ARCH) $(CXXFLAGS) -c -o $@ $<
|
|
|
|
## Compile recepies for Fortran stuff
|
|
%.o: %.f90 $(fDEPS)
|
|
$(FC) $(ARCH) $(FFLAGS) -c -o $@ $<
|
|
|
|
.PHONY: all clean distclean
|
|
|
|
all: cppSherman-Morrison fSherman-Morrison
|
|
|
|
clean:
|
|
@rm -vf *.o *.mod
|
|
|
|
distclean: clean
|
|
@rm -vf cppSherman-Morrison fSherman-Morrison
|
|
|
|
## Linking the C++ example program
|
|
cppSherman-Morrison: $(cppOBJ)
|
|
$(CXX) $(ARCH) $(CXXFLAGS) -o $@ $^
|
|
|
|
## Linking Fortran example program calling the C++ function 'Sherman_Morrison()'
|
|
fSherman-Morrison: $(fOBJ)
|
|
$(FC) $(ARCH) $(FFLAGS) -o $@ $^
|