-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
99 lines (80 loc) · 1.55 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
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
#these compiler variables and flag are in alphabetical order by official language name
#the order of runs in make all follows this ordering
#C
CC = gcc
CF = -O3
#C++
CPPC = g++
CPPF = -O3
#Chapel
CHPLC = chpl
CHPLF = --fast
#Fortran
FC = gfortran
FF = -O3 -w
#Go
GOC = go
#GOF = FLAGS?
#Java
JC = javac
JR = java
#JavaScript
JS = node
#Python
PY = python3
all:
@echo " "
@echo "Running tests:"
@$(MAKE) -s c
@$(MAKE) -s cpp
@$(MAKE) -s chapel
@$(MAKE) -s fortran
@$(MAKE) -s go
@$(MAKE) -s java
@$(MAKE) -s javascript
@$(MAKE) -s python
@echo "Finished testing."
@$(MAKE) -s results
results:
@echo " "
@echo "Updating results..."
@$(PY) src/update_results.py
@echo "...finished."
@echo " "
clean:
@echo " "
@echo "Cleaning build artifacts..."
@rm -r build/*
@mkdir build/java
@echo "...finished."
@echo " "
c:
@echo " ...C"
@$(CC) $(CF) -o build/c src/languages/c/tests.c
@./build/c
cpp:
@echo " ...C++"
@$(CPPC) $(CPPF) -o build/cpp src/languages/cpp/tests.cpp
@./build/cpp
chapel:
@echo " ...Chapel"
@$(CHPLC) $(CHPLF) -o build/chapel src/languages/chapel/tests.chpl
@./build/chapel
fortran:
@echo " ...Fortran"
@$(FC) $(FF) -o build/fortran src/languages/fortran/tests.f90
@./build/fortran
go:
@echo " ...Go"
@$(GOC) build -o build/go src/languages/go/tests.go
@./build/go
java:
@echo " ...Java"
@$(JC) -d build/java src/languages/java/tests.java
@$(JR) -cp build/java tests
javascript:
@echo " ...JavaScript"
@$(JS) src/languages/javascript/tests.js
python:
@echo " ...Python"
@$(PY) src/languages/python/tests.py