forked from Exawind/amr-wind
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmake.incflo
101 lines (80 loc) · 2.95 KB
/
make.incflo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# Path to AMReX directory and incflo directories
TOP = .
AMREX_HOME ?= $(INCFLO_HOME)/submods/amrex
HYPRE_DIR ?= $(INCFLO_HOME)/submods/hypre/src
# Non-verbose compilation
VERBOSE = FALSE
# Always use 3 dimensions for incflo
DIM = 3
EBASE ?= incflo
USE_MG = TRUE
USE_EB = FALSE
include $(AMREX_HOME)/Tools/GNUMake/Make.defs
#These are the directories in incflo/src
Bdirs := $(INCFLO_HOME)src
Bdirs += $(INCFLO_HOME)src/boundary_conditions
Bdirs += $(INCFLO_HOME)src/convection
Bdirs += $(INCFLO_HOME)src/derive
Bdirs += $(INCFLO_HOME)src/diffusion
Bdirs += $(INCFLO_HOME)src/prob
Bdirs += $(INCFLO_HOME)src/projection
Bdirs += $(INCFLO_HOME)src/rheology
Bdirs += $(INCFLO_HOME)src/setup
Bdirs += $(INCFLO_HOME)src/utilities
Bdirs += $(INCFLO_HOME)src/utilities/tagging
Bdirs += $(INCFLO_HOME)src/core
Bdirs += $(INCFLO_HOME)src/wind_energy
Bdirs += $(INCFLO_HOME)src/equation_systems
Bdirs += $(INCFLO_HOME)src/equation_systems/icns
Bdirs += $(INCFLO_HOME)src/equation_systems/temperature
Bdirs += $(INCFLO_HOME)src/equation_systems/density
Bpack += $(foreach dir, $(Bdirs), $(TOP)/$(dir)/Make.package)
Blocs += $(foreach dir, $(Bdirs), $(TOP)/$(dir))
include $(Bpack)
INCLUDE_LOCATIONS += $(Blocs)
VPATH_LOCATIONS += $(Blocs)
#These are the directories in AMReX
Pdirs := Base AmrCore Boundary
ifeq ($(USE_EB), TRUE)
Pdirs += EB
endif
ifeq ($(USE_HYPRE), TRUE)
Pdirs += Extern/HYPRE
endif
Ppack += $(foreach dir, $(Pdirs), $(AMREX_HOME)/Src/$(dir)/Make.package)
Plocs += $(foreach dir, $(Pdirs), $(AMREX_HOME)/Src/$(dir))
include $(Ppack)
INCLUDE_LOCATIONS += $(Plocs)
VPATH_LOCATIONS += $(Plocs)
include $(AMREX_HOME)/Src/LinearSolvers/MLMG/Make.package
INCLUDE_LOCATIONS += $(AMREX_HOME)/Src/LinearSolvers/MLMG
VPATH_LOCATIONS += $(AMREX_HOME)/Src/LinearSolvers/MLMG
include $(AMREX_HOME)/Src/LinearSolvers/Projections/Make.package
INCLUDE_LOCATIONS += $(AMREX_HOME)/Src/LinearSolvers/Projections
VPATH_LOCATIONS += $(AMREX_HOME)/Src/LinearSolvers/Projections
all: $(executable)
$(SILENT) $(RM) AMReX_buildInfo.cpp
@echo SUCCESS
# job_info support
CEXE_sources += AMReX_buildInfo.cpp
CEXE_headers += $(AMREX_HOME)/Tools/C_scripts/AMReX_buildInfo.H
INCLUDE_LOCATIONS += $(AMREX_HOME)/Tools/C_scripts
AMReX_buildInfo.cpp:
$(AMREX_HOME)/Tools/C_scripts/makebuildinfo_C.py \
--amrex_home "$(AMREX_HOME)" \
--COMP "$(COMP)" --COMP_VERSION "$(COMP_VERSION)" \
--CXX_comp_name "$(CXX)" --CXX_flags "$(CXXFLAGS) $(CPPFLAGS) $(includes)" \
--F_comp_name "$(F90)" --F_flags "$(F90FLAGS)" \
--link_flags "$(LDFLAGS)" --libraries "$(libraries)" \
--GIT "$(TOP) $(AMREX_HOME)"
vpath %.c . $(VPATH_LOCATIONS)
vpath %.cpp . $(VPATH_LOCATIONS)
vpath %.h . $(VPATH_LOCATIONS)
vpath %.H . $(VPATH_LOCATIONS)
vpath %.F . $(VPATH_LOCATIONS)
vpath %.f90 . $(VPATH_LOCATIONS)
vpath %.f . $(VPATH_LOCATIONS)
vpath %.fi . $(VPATH_LOCATIONS)
include $(AMREX_HOME)/Tools/GNUMake/Make.rules
clean::
$(SILENT) $(RM) AMReX_buildInfo.cpp