Makefile.am 18 KB
Newer Older
1
## Process this file with automake to produce Makefile.in
2

3
ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS} -I m4
4

5 6
AM_FCFLAGS = $(SCALAPACK_FCFLAGS) @FC_MODINC@modules @FC_MODOUT@modules
AM_LDFLAGS = $(SCALAPACK_LDFLAGS)
7 8

# libelpa
9 10
lib_LTLIBRARIES = libelpa@SUFFIX@.la
libelpa@SUFFIX@_la_LINK = $(FCLINK) $(AM_LDFLAGS) -version-info $(ELPA_SO_VERSION) -lstdc++
11

12
libelpa@SUFFIX@_la_SOURCES = src/mod_precision.f90 \
13 14
                             src/mod_mpi.F90 \
			     src/mod_mpi_stubs.F90 \
15
			     src/elpa2_kernels/mod_fortran_interfaces.F90 \
16
                             src/elpa_utilities.F90 \
17
	                     src/elpa1_compute.F90 \
Andreas Marek's avatar
Andreas Marek committed
18 19
	                     src/elpa1.F90 \
			     src/elpa2_utilities.F90 \
20
			     src/mod_pack_unpack_real.F90 \
21
			     src/elpa2_kernels/mod_single_hh_trafo_real.F90 \
22 23
			     src/mod_compute_hh_trafo_real.F90 \
			     src/mod_compute_hh_trafo_complex.F90 \
24
			     src/mod_pack_unpack_complex.F90 \
25
			     src/aligned_mem.F90 \
26
			     src/elpa2_compute.F90 \
Andreas Marek's avatar
Andreas Marek committed
27 28
			     src/elpa2.F90 \
			     src/elpa_c_interface.F90 \
29
                             src/elpa_qr/qr_utils.F90 \
Andreas Marek's avatar
Andreas Marek committed
30
                             src/elpa_qr/elpa_qrkernels.f90 \
31
                             src/elpa_qr/elpa_pdlarfb.F90 \
32
                             src/elpa_qr/elpa_pdgeqrf.F90
33 34 35 36 37

EXTRA_libelpa@SUFFIX@_la_DEPENDENCIES = src/elpa_reduce_add_vectors.X90 \
					src/elpa_transpose_vectors.X90 \
					src/redist_band.X90

38 39 40 41 42 43 44 45 46 47 48 49
if HAVE_DETAILED_TIMINGS
  libelpa@SUFFIX@_la_SOURCES += src/timer.F90 \
                                src/ftimings/ftimings.F90 \
                                src/ftimings/ftimings_type.F90 \
                                src/ftimings/ftimings_value.F90 \
                                src/ftimings/highwater_mark.c \
                                src/ftimings/resident_set_size.c \
                                src/ftimings/time.c \
                                src/ftimings/virtual_memory.c \
                                src/ftimings/papi.c
endif

50 51 52 53 54 55 56
if !WITH_MPI
  libelpa@SUFFIX@_la_SOURCES += src/mod_time_c.F90
if !HAVE_DETAILED_TIMINGS
  libelpa@SUFFIX@_la_SOURCES += src/ftimings/time.c
endif
endif

Andreas Marek's avatar
Andreas Marek committed
57
if WITH_REAL_GENERIC_KERNEL
58
  libelpa@SUFFIX@_la_SOURCES +=  src/elpa2_kernels/elpa2_kernels_real.F90
59 60
endif

Andreas Marek's avatar
Andreas Marek committed
61
if WITH_COMPLEX_GENERIC_KERNEL
62
  libelpa@SUFFIX@_la_SOURCES +=  src/elpa2_kernels/elpa2_kernels_complex.F90
63 64
endif

Andreas Marek's avatar
Andreas Marek committed
65
if WITH_REAL_GENERIC_SIMPLE_KERNEL
66
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_simple.F90
67 68
endif

Andreas Marek's avatar
Andreas Marek committed
69
if WITH_COMPLEX_GENERIC_SIMPLE_KERNEL
70
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_complex_simple.F90
71 72
endif

Andreas Marek's avatar
Andreas Marek committed
73
if WITH_REAL_BGP_KERNEL
74
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_bgp.f90
75 76
endif

Andreas Marek's avatar
Andreas Marek committed
77
if WITH_REAL_BGQ_KERNEL
78
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_bgq.f90
79 80
endif

81
if WITH_REAL_SSE_ASSEMBLY_KERNEL
82
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_asm_x86_64.s
Andreas Marek's avatar
Andreas Marek committed
83
else
84
if WITH_COMPLEX_SSE_ASSEMBLY_KERNEL
85
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_asm_x86_64.s
86 87
endif
endif
Andreas Marek's avatar
Andreas Marek committed
88

89 90 91 92
if WITH_REAL_SSE_BLOCK2_KERNEL
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_sse_2hv.c
endif

Andreas Marek's avatar
Andreas Marek committed
93
if WITH_REAL_AVX_BLOCK2_KERNEL
94
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_avx-avx2_2hv.c
95 96
endif

97 98 99 100
if WITH_REAL_SSE_BLOCK4_KERNEL
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_sse_4hv.c
endif

Andreas Marek's avatar
Andreas Marek committed
101
if WITH_REAL_AVX_BLOCK4_KERNEL
102
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_avx-avx2_4hv.c
103 104
endif

105 106 107 108
if WITH_REAL_SSE_BLOCK6_KERNEL
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_sse_6hv.c
endif

Andreas Marek's avatar
Andreas Marek committed
109
if WITH_REAL_AVX_BLOCK6_KERNEL
110
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_real_avx-avx2_6hv.c
111 112
endif

113
if WITH_COMPLEX_SSE_BLOCK1_KERNEL
Andreas Marek's avatar
Andreas Marek committed
114
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_complex_sse_1hv.c
115 116
endif

Andreas Marek's avatar
Andreas Marek committed
117
if WITH_COMPLEX_AVX_BLOCK1_KERNEL
Andreas Marek's avatar
Andreas Marek committed
118
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_complex_avx-avx2_1hv.c
119 120
endif

121
if WITH_COMPLEX_SSE_BLOCK2_KERNEL
Andreas Marek's avatar
Andreas Marek committed
122
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_complex_sse_2hv.c
123 124
endif

Andreas Marek's avatar
Andreas Marek committed
125
if WITH_COMPLEX_AVX_BLOCK2_KERNEL
Andreas Marek's avatar
Andreas Marek committed
126
  libelpa@SUFFIX@_la_SOURCES += src/elpa2_kernels/elpa2_kernels_complex_avx-avx2_2hv.c
127 128 129
endif

# install any .mod files in the include/ dir
130
elpa_includedir = $(includedir)/elpa@SUFFIX@-@PACKAGE_VERSION@
131
nobase_elpa_include_HEADERS = $(wildcard modules/*)
Andreas Marek's avatar
Andreas Marek committed
132
nobase_elpa_include_HEADERS += elpa/elpa.h elpa/elpa_kernel_constants.h elpa/elpa_generated.h
133

Lorenz Huedepohl's avatar
Lorenz Huedepohl committed
134 135
dist_man_MANS = \
	   man/solve_evp_real.3 \
136
	   man/solve_evp_real_1stage.3 \
Andreas Marek's avatar
Andreas Marek committed
137
	   man/solve_evp_complex.3 \
138
	   man/solve_evp_complex_1stage.3 \
Andreas Marek's avatar
Andreas Marek committed
139 140 141
	   man/solve_evp_real_2stage.3 \
	   man/solve_evp_complex_2stage.3 \
	   man/get_elpa_row_col_comms.3 \
142
	   man/get_elpa_communicators.3 \
143
	   man/elpa2_print_kernels.1
Andreas Marek's avatar
Andreas Marek committed
144

145
# other files to distribute
146
filesdir = $(docdir)/examples
147
dist_files_DATA = \
Andreas Marek's avatar
Andreas Marek committed
148 149 150 151 152 153 154 155 156 157 158
  test/fortran_test_programs/read_real.F90 \
  test/fortran_test_programs/test_complex2.F90 \
  test/fortran_test_programs/test_complex2_default_kernel.F90 \
  test/fortran_test_programs/test_complex2_choose_kernel_with_api.F90 \
  test/fortran_test_programs/test_complex.F90 \
  test/fortran_test_programs/test_real2.F90 \
  test/fortran_test_programs/test_real2_default_kernel.F90 \
  test/fortran_test_programs/test_real2_default_kernel_qr_decomposition.F90 \
  test/fortran_test_programs/test_real2_choose_kernel_with_api.F90 \
  test/fortran_test_programs/test_real.F90 \
  test/fortran_test_programs/test_real_with_c.F90 \
159
  src/elpa2_print_kernels.F90
160

161
dist_doc_DATA = README.md USERS_GUIDE.md INSTALL.md CONTRIBUTING.md LICENSE Changelog COPYING/COPYING COPYING/gpl.txt COPYING/lgpl.txt
162

163 164
# pkg-config stuff
pkgconfigdir = $(libdir)/pkgconfig
165
pkgconfig_DATA = @PKG_CONFIG_FILE@
166

167 168
# programs
bin_PROGRAMS = \
169 170 171
  elpa2_print_kernels@SUFFIX@

noinst_PROGRAMS = \
172 173 174 175 176
  elpa1_test_real@SUFFIX@ \
  elpa1_test_complex@SUFFIX@ \
  elpa2_test_real@SUFFIX@ \
  elpa2_test_complex@SUFFIX@ \
  elpa2_test_real_default_kernel@SUFFIX@ \
177
  elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@ \
178 179
  elpa2_test_complex_default_kernel@SUFFIX@ \
  elpa2_test_real_choose_kernel_with_api@SUFFIX@ \
Andreas Marek's avatar
Andreas Marek committed
180
  elpa2_test_complex_choose_kernel_with_api@SUFFIX@ \
181 182 183
  elpa1_test_real_with_c@SUFFIX@
if !WITH_OPENMP
noinst_PROGRAMS += \
184
  elpa1_test_real_c_version@SUFFIX@ \
Andreas Marek's avatar
Andreas Marek committed
185 186
  elpa1_test_complex_c_version@SUFFIX@ \
  elpa2_test_real_c_version@SUFFIX@ \
187 188
  elpa2_test_complex_c_version@SUFFIX@
endif
189

190
build_lib = libelpa@SUFFIX@.la
Andreas Marek's avatar
Andreas Marek committed
191

192
if HAVE_REDIRECT
Andreas Marek's avatar
Andreas Marek committed
193
  redirect_sources = test/shared_sources/redir.c test/shared_sources/redirect.F90
194 195 196 197
else
  redirect_sources =
endif

198 199 200 201 202 203
#test/shared_sources/mod_precision_created.f90: src/mod_precision.f90
#	cp $(top_srcdir)/src/mod_precision.f90 $(top_srcdir)/test/shared_sources/mod_precision_created.f90

shared_sources = test/shared_sources/util.F90 test/shared_sources/read_input_parameters.F90  \
		 test/shared_sources/check_correctnes.F90 test/shared_sources/setup_mpi.F90 \
		 test/shared_sources/blacs_infrastructure.F90 test/shared_sources/prepare_matrix.F90 \
204
		 test/shared_sources/mod_output_types.F90
205
if !WITH_OPENMP
Andreas Marek's avatar
Andreas Marek committed
206
elpa1_test_real_c_version@SUFFIX@_SOURCES = test/c_test_programs/elpa1_test_real_c_version.c $(shared_sources) $(redirect_sources)
Andreas Marek's avatar
Andreas Marek committed
207
elpa1_test_real_c_version@SUFFIX@_LDADD = $(build_lib)
208
elpa1_test_real_c_version@SUFFIX@_LINK = $(LINK) $(FCLIBS)
209
EXTRA_elpa1_test_real_c_version@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
210

Andreas Marek's avatar
Andreas Marek committed
211 212 213
elpa1_test_complex_c_version@SUFFIX@_SOURCES = test/c_test_programs/elpa1_test_complex_c_version.c $(shared_sources) $(redirect_sources)
elpa1_test_complex_c_version@SUFFIX@_LDADD = $(build_lib)
elpa1_test_complex_c_version@SUFFIX@_LINK = $(LINK) $(FCLIBS)
214
EXTRA_elpa1_test_complex_c_version@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
215 216 217 218

elpa2_test_real_c_version@SUFFIX@_SOURCES = test/c_test_programs/elpa2_test_real_c_version.c $(shared_sources) $(redirect_sources)
elpa2_test_real_c_version@SUFFIX@_LDADD = $(build_lib)
elpa2_test_real_c_version@SUFFIX@_LINK = $(LINK) $(FCLIBS)
219
EXTRA_elpa2_test_real_c_version@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
220 221 222 223

elpa2_test_complex_c_version@SUFFIX@_SOURCES = test/c_test_programs/elpa2_test_complex_c_version.c $(shared_sources) $(redirect_sources)
elpa2_test_complex_c_version@SUFFIX@_LDADD = $(build_lib)
elpa2_test_complex_c_version@SUFFIX@_LINK = $(LINK) $(FCLIBS)
224
EXTRA_elpa2_test_complex_c_version@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
225
endif
Andreas Marek's avatar
Andreas Marek committed
226 227

elpa1_test_real@SUFFIX@_SOURCES = test/fortran_test_programs/test_real.F90 $(shared_sources) $(redirect_sources)
228
elpa1_test_real@SUFFIX@_LDADD = $(build_lib)
Lorenz Huedepohl's avatar
Typo  
Lorenz Huedepohl committed
229
EXTRA_elpa1_test_real@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
230

231 232
elpa1_test_real_with_c@SUFFIX@_SOURCES = test/fortran_test_programs/test_real_with_c.F90 test/shared_sources/mod_from_c.F90 \
					 test/shared_sources/call_elpa1.c $(shared_sources) $(redirect_sources)
Andreas Marek's avatar
Andreas Marek committed
233
elpa1_test_real_with_c@SUFFIX@_LDADD = $(build_lib)
234
EXTRA_elpa1_test_real_with_c@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
235

236 237
#elpa1_test_complex_with_c@SUFFIX@_SOURCES = test/fortran_test_programs/test_complex_with_c.F90 test/shared_sources/mod_from_c.F90 test/shared_sources/call_elpa1.c $(shared_sources) $(redirect_sources)
#elpa1_test_complex_with_c@SUFFIX@_LDADD = $(build_lib)
238
#EXTRA_elpa1_test_complex_with_c@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
239 240

elpa2_test_real@SUFFIX@_SOURCES = test/fortran_test_programs/test_real2.F90 $(shared_sources) $(redirect_sources)
241
elpa2_test_real@SUFFIX@_LDADD = $(build_lib)
242
EXTRA_elpa2_test_real@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
243

Andreas Marek's avatar
Andreas Marek committed
244
elpa2_test_real_default_kernel@SUFFIX@_SOURCES = test/fortran_test_programs/test_real2_default_kernel.F90 $(shared_sources) $(redirect_sources)
245
elpa2_test_real_default_kernel@SUFFIX@_LDADD = $(build_lib)
246
EXTRA_elpa2_test_real_default_kernel@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
247

248

249 250
elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@_SOURCES = test/fortran_test_programs/test_real2_default_kernel_qr_decomposition.F90 \
								   $(shared_sources) $(redirect_sources)
251
elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@_LDADD = $(build_lib)
252
EXTRA_elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
253

254 255
elpa2_test_real_choose_kernel_with_api@SUFFIX@_SOURCES = test/fortran_test_programs/test_real2_choose_kernel_with_api.F90 \
							 $(shared_sources) $(redirect_sources)
256
elpa2_test_real_choose_kernel_with_api@SUFFIX@_LDADD = $(build_lib)
257
EXTRA_elpa2_test_real_choose_kernel_with_api@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
258

Andreas Marek's avatar
Andreas Marek committed
259
elpa1_test_complex@SUFFIX@_SOURCES = test/fortran_test_programs/test_complex.F90 $(shared_sources) $(redirect_sources)
260
elpa1_test_complex@SUFFIX@_LDADD = $(build_lib)
261
EXTRA_elpa1_test_complex@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
262

263

264
elpa2_test_complex@SUFFIX@_SOURCES = test/fortran_test_programs/test_complex2.F90 $(shared_sources) $(redirect_sources)
265
elpa2_test_complex@SUFFIX@_LDADD = $(build_lib)
266
EXTRA_elpa2_test_complex@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
267

Andreas Marek's avatar
Andreas Marek committed
268
elpa2_test_complex_default_kernel@SUFFIX@_SOURCES = test/fortran_test_programs/test_complex2_default_kernel.F90 $(shared_sources) $(redirect_sources)
269
elpa2_test_complex_default_kernel@SUFFIX@_LDADD = $(build_lib)
270
EXTRA_elpa2_test_complex_default_kernel@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
271

272 273
elpa2_test_complex_choose_kernel_with_api@SUFFIX@_SOURCES = test/fortran_test_programs/test_complex2_choose_kernel_with_api.F90 \
							    $(shared_sources) $(redirect_sources)
274
elpa2_test_complex_choose_kernel_with_api@SUFFIX@_LDADD = $(build_lib)
275
EXTRA_elpa2_test_complex_choose_kernel_with_api@SUFFIX@_DEPENDENCIES = test/fortran_test_programs/elpa_test_programs_print_headers.X90
Andreas Marek's avatar
Andreas Marek committed
276

277
elpa2_print_kernels@SUFFIX@_SOURCES = src/elpa2_print_kernels.F90 $(shared_sources) $(redirect_sources)
278
elpa2_print_kernels@SUFFIX@_LDADD = $(build_lib)
Andreas Marek's avatar
Andreas Marek committed
279

280
check_SCRIPTS = \
281 282 283 284 285 286 287 288 289 290
  elpa1_test_real@SUFFIX@.sh \
  elpa1_test_real_with_c@SUFFIX@.sh \
  elpa2_test_real@SUFFIX@.sh \
  elpa2_test_real_default_kernel@SUFFIX@.sh \
  elpa1_test_complex@SUFFIX@.sh \
  elpa2_test_complex@SUFFIX@.sh \
  elpa2_test_complex_default_kernel@SUFFIX@.sh \
  elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@.sh \
  elpa2_test_real_choose_kernel_with_api@SUFFIX@.sh \
  elpa2_test_complex_choose_kernel_with_api@SUFFIX@.sh \
291
  elpa2_print_kernels@SUFFIX@
292

293 294
if !WITH_OPENMP
check_SCRIPTS += \
295 296 297 298
  elpa1_test_real_c_version@SUFFIX@.sh \
  elpa1_test_complex_c_version@SUFFIX@.sh \
  elpa2_test_real_c_version@SUFFIX@.sh \
  elpa2_test_complex_c_version@SUFFIX@.sh
299
endif
300

301
TESTS = $(check_SCRIPTS)
302 303 304
elpa1_test_real@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa1_test_real@SUFFIX@ $$TEST_FLAGS' > elpa1_test_real@SUFFIX@.sh
	chmod +x elpa1_test_real@SUFFIX@.sh
305

306 307 308
elpa1_test_real_with_c@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa1_test_real_with_c@SUFFIX@ $$TEST_FLAGS' > elpa1_test_real_with_c@SUFFIX@.sh
	chmod +x elpa1_test_real_with_c@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
309

310 311 312
elpa2_test_real_c_version@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_real_c_version@SUFFIX@ $$TEST_FLAGS' > elpa2_test_real_c_version@SUFFIX@.sh
	chmod +x elpa2_test_real_c_version@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
313

314 315 316
elpa2_test_complex_c_version@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_complex_c_version@SUFFIX@ $$TEST_FLAGS' > elpa2_test_complex_c_version@SUFFIX@.sh
	chmod +x elpa2_test_complex_c_version@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
317

318 319 320
elpa1_test_real_c_version@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa1_test_real_c_version@SUFFIX@ $$TEST_FLAGS' > elpa1_test_real_c_version@SUFFIX@.sh
	chmod +x elpa1_test_real_c_version@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
321

322 323 324 325 326 327
elpa1_test_complex_c_version@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa1_test_complex_c_version@SUFFIX@ $$TEST_FLAGS' > elpa1_test_complex_c_version@SUFFIX@.sh
	chmod +x elpa1_test_complex_c_version@SUFFIX@.sh
elpa2_test_real@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_real@SUFFIX@ $$TEST_FLAGS' > elpa2_test_real@SUFFIX@.sh
	chmod +x elpa2_test_real@SUFFIX@.sh
328

329 330 331
elpa2_test_real_default_kernel@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_real_default_kernel@SUFFIX@ $$TEST_FLAGS' > elpa2_test_real_default_kernel@SUFFIX@.sh
	chmod +x elpa2_test_real_default_kernel@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
332

333 334 335
elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@' > elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@.sh
	chmod +x elpa2_test_real_default_kernel_qr_decomposition@SUFFIX@.sh
336

337 338 339
elpa2_test_real_choose_kernel_with_api@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_real_choose_kernel_with_api@SUFFIX@ $$TEST_FLAGS' > elpa2_test_real_choose_kernel_with_api@SUFFIX@.sh
	chmod +x elpa2_test_real_choose_kernel_with_api@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
340

341 342 343
elpa1_test_complex@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa1_test_complex@SUFFIX@ $$TEST_FLAGS' > elpa1_test_complex@SUFFIX@.sh
	chmod +x elpa1_test_complex@SUFFIX@.sh
344

345 346 347
elpa2_test_complex@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_complex@SUFFIX@ $$TEST_FLAGS' > elpa2_test_complex@SUFFIX@.sh
	chmod +x elpa2_test_complex@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
348

349 350 351
elpa2_test_complex_default_kernel@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_complex_default_kernel@SUFFIX@ $$TEST_FLAGS' > elpa2_test_complex_default_kernel@SUFFIX@.sh
	chmod +x elpa2_test_complex_default_kernel@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
352

353 354 355
elpa2_test_complex_choose_kernel_with_api@SUFFIX@.sh:
	echo 'mpiexec -n 2 ./elpa2_test_complex_choose_kernel_with_api@SUFFIX@ $$TEST_FLAGS' > elpa2_test_complex_choose_kernel_with_api@SUFFIX@.sh
	chmod +x elpa2_test_complex_choose_kernel_with_api@SUFFIX@.sh
Andreas Marek's avatar
Andreas Marek committed
356

Andreas Marek's avatar
Andreas Marek committed
357 358 359
elpa2_utilities.i: $(top_srcdir)/src/elpa2_utilities.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/elpa2_utilities.F90 -o $@

Andreas Marek's avatar
Andreas Marek committed
360 361
elpa2.i: $(top_srcdir)/src/elpa2.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/elpa2.F90 -o $@
362

Andreas Marek's avatar
Andreas Marek committed
363 364
elpa1.i: $(top_srcdir)/src/elpa1.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/elpa1.F90 -o $@
365

366 367 368
elpa2_kernels_real.i: $(top_srcdir)/src/elpa2_kernels/elpa2_kernels_real.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/elpa2_kernels/elpa2_kernels_real.F90 -o $@

369 370 371
mod_compute_hh_trafo_real.i: $(top_srcdir)/src/mod_compute_hh_trafo_real.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/mod_compute_hh_trafo_real.F90 -o $@

372 373 374 375
mod_compute_hh_trafo_complex.i: $(top_srcdir)/src/mod_compute_hh_trafo_complex.F90
	$(CPP) $(CPPFLAGS) -I$(top_builddir)/ -c $(top_srcdir)/src/mod_compute_hh_trafo_complex.F90 -o $@


376 377
include doxygen.am

378
CLEANFILES = \
Andreas Marek's avatar
Andreas Marek committed
379
  elpa-generated.h \
380 381
  elpa1_test* \
  elpa2_test*\
382
  *.i
383 384

clean-local:
Lorenz Huedepohl's avatar
Lorenz Huedepohl committed
385 386 387 388
	-rm -rf modules/* .fortran_dependencies/*

distclean-local:
	-rm config-f90.h
389 390 391
	-rm -rf ./src/elpa2_kernels/.deps
	-rm -rf ./src/.deps
	-rm -rf ./test/.deps
392
	-rm -rf ./elpa/elpa_generated.h
Lorenz Huedepohl's avatar
Lorenz Huedepohl committed
393
	-rmdir ./src/elpa2_kernels/
394 395
	-rmdir ./src
	-rmdir ./test
396
	-rmdir ./m4
397
	-rmdir modules/
Lorenz Huedepohl's avatar
Lorenz Huedepohl committed
398
	-rmdir .fortran_dependencies/
399

400 401 402
EXTRA_DIST = \
  fdep/fortran_dependencies.pl \
  fdep/fortran_dependencies.mk \
403
  test/fortran_test_programs/elpa_test_programs_print_headers.X90 \
404 405 406
  src/elpa_reduce_add_vectors.X90 \
  src/elpa_transpose_vectors.X90 \
  src/redist_band.X90
407

408 409 410 411 412 413 414
# Rules to re-generated the headers
elpa/elpa_generated.h: $(top_srcdir)/src/elpa_c_interface.F90
	grep -h "^ *!c>" $^ | sed 's/^ *!c>//;' > $@ || { rm $@; exit 1; }

test/shared_sources/generated.h: $(wildcard $(top_srcdir)/test/shared_sources/*.F90)
	grep -h "^ *!c>" $^ | sed 's/^ *!c>//;' > $@ || { rm $@; exit 1; }

415 416 417
LIBTOOL_DEPS = @LIBTOOL_DEPS@
libtool: $(LIBTOOL_DEPS)
	$(SHELL) ./config.status libtool
418

419

420
@FORTRAN_MODULE_DEPS@
421 422 423 424 425

# Fortran module dependencies only work within each target,
# specify that the test programs need a finished library before
# one can compile them

426
# $1  Object name
427
define require_elpa_lib
428
$1: libelpa@SUFFIX@.la
429 430

endef
431
$(foreach p,$(bin_PROGRAMS) $(noinst_PROGRAMS),$(foreach o,$($p_OBJECTS),$(eval $(call require_elpa_lib,$o))))