-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
30 lines (24 loc) · 804 Bytes
/
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
# define the shell to bash
SHELL := /bin/bash
# define the C/C++ compiler to use,default here is clang
CC = gcc-7
MPICC = mpicc
MPIRUN = mpirun -np 4
test_sequential:
#tar -xvzf code.tar.gz
cd knnring; make lib; cd ..
cd knnring; cp lib/*.a inc/knnring.h ../; cd ..
$(CC) tester.c knnring_sequential.a -o $@ -lm -lopenblas
./test_sequential
test_synchronous:
#tar -xvzf code.tar.gz
cd knnring; make lib; cd ..
cd knnring; cp lib/*.a inc/knnring.h ../; cd ..
$(MPICC) tester_synchronous.c knnring_synchronous.a -o $@ -lm -lopenblas
$(MPIRUN) ./test_synchronous
test_asynchronous:
#tar -xvzf code.tar.gz
cd knnring; make lib; cd ..
cd knnring; cp lib/*.a inc/knnring.h ../; cd ..
$(MPICC) tester_asynchronous.c knnring_asynchronous.a -o $@ -lm -lopenblas
$(MPIRUN) ./test_asynchronous