forked from simulationcraft/simc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
simulationcraft.pri
98 lines (77 loc) · 2.17 KB
/
simulationcraft.pri
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
ORG_NAME = SimulationCraft
APP_NAME = SimulationCraft
INCLUDEPATH = ../engine
DEPENDPATH = ../engine
VPATH = ..
CONFIG += c++11
CONFIG(debug, debug|release): OBJECTS_DIR = build/debug
CONFIG(release, debug|release): OBJECTS_DIR = build/release
QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.7
# Setup some paths if DESTDIR/PREFIX are defined for Linux stuff
unix:!macx {
!isEmpty(DESTDIR): PREFIX=$$DESTDIR/$$PREFIX
isEmpty(PREFIX): PREFIX=/usr/local
isEmpty(DATADIR): DATADIR=$$PREFIX/share
isEmpty(SEARCH): SEARCH=$$DATADIR/$$ORG_NAME/$$APP_NAME
isEmpty(BINDIR): BINDIR=$$PREFIX/bin
SHAREPATH = $$DESTDIR$$PREFIX/share/$$ORG_NAME/$$APP_NAME
}
CONFIG(release, debug|release) {
DEFINES += NDEBUG
}
CONFIG(openssl) {
DEFINES += SC_USE_OPENSSL
!isEmpty(OPENSSL_INCLUDES) {
INCLUDEPATH += $$OPENSSL_INCLUDES
}
!isEmpty(OPENSSL_LIBS) {
LIBS += -L$$OPENSSL_LIBS
}
win32 {
LIBS += -lssleay32
}
}
contains(QMAKE_CXX, .+/clang\+\+)|contains(QMAKE_CXX, .+/g\+\+) {
QMAKE_CXXFLAGS += -Wextra
QMAKE_CXXFLAGS_RELEASE -= -O2
QMAKE_CXXFLAGS_RELEASE += -O3 -ffast-math -fomit-frame-pointer -Os -fPIE
!isEmpty(LTO) {
QMAKE_CXXFLAGS_RELEASE += -flto
}
}
unix|macx {
exists(.git):system(which -s git) {
DEFINES += SC_GIT_REV="\\\"$$system(git rev-parse --short HEAD)\\\""
}
}
macx {
contains(QMAKE_CXX, .+/clang\+\+) {
QMAKE_CXXFLAGS += -Wno-inconsistent-missing-override
}
LIBS += -framework Security
CONFIG(sanitize) {
QMAKE_CXXFLAGS += -fsanitize=address
QMAKE_LFLAGS += -fsanitize=address
}
}
win32 {
LIBS += -lwininet -lshell32
win32-msvc2013|win32-msvc2015 {
QMAKE_CXXFLAGS_RELEASE += /Ot /MP
QMAKE_CXXFLAGS_WARN_ON += /w44800 /w44100 /w44065
}
# TODO: Mingw might want something more unixy here?
exists(.git):system(where /q git) {
DEFINES += SC_GIT_REV="\\\"$$system(git rev-parse --short HEAD)\\\""
}
!isEmpty(PGO) {
win32-msvc2013 {
QMAKE_LFLAGS_RELEASE += /LTCG
QMAKE_CXXFLAGS_RELEASE += /GL
}
win32-msvc2015 {
QMAKE_CXXFLAGS_RELEASE += /GL
QMAKE_LFLAGS_RELEASE += /LTCG /USEPROFILE /PGD:"..\SimulationCraft.pgd"
}
}
}