-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmakefile
55 lines (40 loc) · 1.38 KB
/
makefile
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
## -*- fill-column:110 -*-
# @file makefile
# @author Mitch Richling <https://www.mitchr.me/>
# @Copyright Copyright 1999 by Mitch Richling. All rights reserved.
# @brief Build the MPI example programs.@EOL
# @Keywords MPI examples
# @Std GenericMake
# Depending upon which MPI implementation is used, the following may need to be adjusted.
MPICC = mpicc
MPICXX = mpic++
MPIF7 = mpif77
MPIF9 = mpif90
# Uncomment to build all when make file changes
#SPECDEP=makefile
TARGETS = initStuffC helloC helloF90 helloF77 helloCPP reduceC sendRecvC sendRecvErrC barrierC groupsC
all : $(TARGETS)
@echo Make Complete
helloC : helloC.c $(SPECDEP)
$(MPICC) helloC.c -o helloC
helloCPP : helloCPP.cpp $(SPECDEP)
$(MPICXX) helloCPP.cpp -o helloCPP
helloF90 : helloF90.f90 $(SPECDEP)
$(MPIF9) helloF90.f90 -o helloF90
helloF77 : helloF77.f $(SPECDEP)
$(MPIF7) helloF77.f -o helloF77
initStuffC : initStuffC.c $(SPECDEP)
$(MPICC) initStuffC.c -o initStuffC
reduceC : reduceC.c $(SPECDEP)
$(MPICC) reduceC.c -o reduceC
sendRecvC : sendRecvC.c $(SPECDEP)
$(MPICC) sendRecvC.c -o sendRecvC
sendRecvErrC : sendRecvErrC.c $(SPECDEP)
$(MPICC) sendRecvErrC.c -o sendRecvErrC
barrierC : barrierC.c $(SPECDEP)
$(MPICC) barrierC.c -o barrierC
groupsC : groupsC.c $(SPECDEP)
$(MPICC) groupsC.c -o groupsC
clean :
rm -rf a.out *~ *.bak $(TARGETS) hostnames p4pg.hostnames
@echo Make Complete