-
Notifications
You must be signed in to change notification settings - Fork 2
/
Mandelbrotr.pro
62 lines (52 loc) · 1.97 KB
/
Mandelbrotr.pro
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
#QT -= gui
CONFIG += c++11 console
CONFIG -= app_bundle
# The following define makes your compiler emit warnings if you use
# any feature of Qt which as been marked deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
# added glm headers & it totally mangled this file. Just adding them to git and not
# worrying about them in here...
SOURCES += \
main.cpp \
window.cpp \
cuda_utils.cpp
# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target
HEADERS += \
window.h \
vertex.h \
glm\glm.hpp \
cuda_utils.h
DISTFILES += \
README.md \
shaders/basic_frag.glsl \
shaders/basic_vert.glsl \
images/side1.png
RESOURCES += \
resources.qrc
# CUDA
# Path to cuda toolkit install
CUDA_DIR = /usr/local/cuda
# GPU architecture (ADJUST FOR YOUR GPU)
CUDA_GENCODE = arch=compute_60,code=sm_60
# manually add CUDA sources (ADJUST MANUALLY)
CUDA_SOURCES += mandelbrot.cu
# Path to header and libs files
INCLUDEPATH += $$CUDA_DIR/include
# libs used in your code
LIBS += -L $$CUDA_DIR/lib64 -lcudart -lcuda
cuda.commands = $$CUDA_DIR/bin/nvcc -c -gencode $$CUDA_GENCODE -o ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
cuda.dependency_type = TYPE_C
cuda.depend_command = $$CUDA_DIR/bin/nvcc -M ${QMAKE_FILE_NAME}
cuda.input = CUDA_SOURCES
cuda.output = ${QMAKE_FILE_BASE}_cuda.o
# Tell Qt that we want add more stuff to the Makefile
QMAKE_EXTRA_COMPILERS += cuda