forked from jaurentz/getbeta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
make.inc.gannett
44 lines (31 loc) · 1.39 KB
/
make.inc.gannett
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
#this is the home directory of where the project lives.
HOMEDIR := /usr1/jaurentz/Projects/getBeta
# C compiler
CC := nvcc
CFLAGS := -O3 -fopenmp
# CUDA compiler
CUC := nvcc
CUFLAGS := -O3 --compiler-options '$(CFLAGS)' -gencode arch=compute_35,code=sm_35
#source file directory
SRCDIR := $(HOMEDIR)/src
#example file directory
EXDIR := $(HOMEDIR)/examples
#wildcard picks all the files with .c extension
SRCS := $(wildcard $(SRCDIR)/*.c) $(wildcard $(SRCDIR)/*.cu)
#will replace the .c files with the .o files once they have been compiled.
OBJS := $(patsubst $(SRCDIR)/%.cu,$(SRCDIR)/%.o,$(wildcard $(SRCDIR)/*.cu)) $(patsubst $(SRCDIR)/%.c,$(SRCDIR)/%.o,$(wildcard $(SRCDIR)/*.c))
#wildcard picks all of the files in example directory with .c file extension.
CEXS := $(wildcard $(EXDIR)/*.c)
CUEXS := $(wildcard $(EXDIR)/*.cu)
#patsubst will replace the .c files with .o
EXS := $(patsubst $(EXDIR)/%.c,$(EXDIR)/% ,$(CEXS)) $(patsubst $(EXDIR)/%.cu,$(EXDIR)/% ,$(CUEXS))
# cucheb
CUCHEBDIR := /usr1/jaurentz/MyLibs/cucheb
# lapack
LAPACKDIR := /usr1/jaurentz/MyLibs/lapack-3.5.0
# lapacke
LAPACKEDIR := $(LAPACKDIR)/lapacke
#calling LAPACKE LAPACK & BLAS
LIBS := -L $(CUCHEBDIR)/lib -L $(LAPACKDIR) -lcucheb -lcudart -lcuda -lcusparse -lcublas -lcurand -lcufft -lm -llapacke -llapack -lblas
#calling the header file.
INCS := -I $(HOMEDIR)/include/ -I $(CUCHEBDIR)/include -I $(LAPACKEDIR)/include