-
Notifications
You must be signed in to change notification settings - Fork 4
/
CMakePresets.json
163 lines (163 loc) · 4.38 KB
/
CMakePresets.json
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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
{
"version": 7,
"cmakeMinimumRequired": {
"major": 3,
"minor": 27,
"patch": 0
},
"configurePresets": [
{
"name": "Default",
"description": "Default preset for all platforms. Uses the default generator/compiler combo for the platform."
},
{
"name": "visual-studio-17-2022",
"displayName": "Visual Studio 2022",
"description": "Generate using visual studio 2022 x64. Windows only",
"generator": "Visual Studio 17 2022",
"binaryDir": "build/${presetName}",
"architecture": {
"value": "x64",
"strategy": "set"
},
"toolset": {
"value": "host=x64",
"strategy": "set"
},
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
},
"cacheVariables":
{
"CMAKE_CXX_FLAGS_DEBUG": "-DZ_DEBUG /MDd /Zi /Ob0 /Od /RTC1",
"CMAKE_C_FLAGS_DEBUG": "-DZ_DEBUG /MDd /Zi /Ob0 /Od /RTC1",
"CMAKE_CXX_FLAGS_RELEASE": "-DZ_RELEASE /MD /O2 /Ob2 /DNDEBUG",
"CMAKE_C_FLAGS_RELEASE": "-DZ_RELEASE /MD /O2 /Ob2 /DNDEBUG"
}
},
{
"name": "Ninja-MSVC",
"displayName": "Ninja MSVC",
"description": "Generate using Ninja multi-config, build using MSVC17 x64",
"generator": "Ninja Multi-Config",
"binaryDir": "build/${presetName}",
"architecture": {
"value": "x64",
"strategy": "external"
},
"toolset": {
"value": "host=x64",
"strategy": "external"
},
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
},
"cacheVariables": {
"CMAKE_C_COMPILER": "cl.exe",
"CMAKE_CXX_COMPILER": "cl.exe",
"CMAKE_CXX_FLAGS_DEBUG": "-DZ_DEBUG /MDd /Zi /Ob0 /Od /RTC1",
"CMAKE_C_FLAGS_DEBUG": "-DZ_DEBUG /MDd /Zi /Ob0 /Od /RTC1",
"CMAKE_CXX_FLAGS_RELEASE": "-DZ_RELEASE /MD /O2 /Ob2 /DNDEBUG",
"CMAKE_C_FLAGS_RELEASE": "-DZ_RELEASE /MD /O2 /Ob2 /DNDEBUG"
}
},
{
"name": "Ninja-GCC",
"description": "Generate using Ninja multi-config, build using gcc and g++",
"generator": "Ninja Multi-Config",
"binaryDir": "build/${presetName}",
"cacheVariables": {
"CMAKE_C_COMPILER": "gcc",
"CMAKE_CXX_COMPILER": "g++",
"CMAKE_CXX_FLAGS_DEBUG": "-DZ_DEBUG -g3 -ggdb -O0",
"CMAKE_C_FLAGS_DEBUG": "-DZ_DEBUG -g3 -ggdb -O0",
"CMAKE_CXX_FLAGS_RELEASE": "-DZ_RELEASE -g0 -O3",
"CMAKE_C_FLAGS_RELEASE": "-DZ_RELEASE -g0 -O3"
}
},
{
"name": "Ninja-Clang",
"description": "Generate using Ninja multi-config, build using clang and clang++",
"generator": "Ninja Multi-Config",
"binaryDir": "build/${presetName}",
"cacheVariables": {
"CMAKE_C_COMPILER": "clang",
"CMAKE_CXX_COMPILER": "clang++",
"CMAKE_CXX_FLAGS_DEBUG": "-DZ_DEBUG -g3 -ggdb -O0",
"CMAKE_C_FLAGS_DEBUG": "-DZ_DEBUG -g3 -ggdb -O0",
"CMAKE_CXX_FLAGS_RELEASE": "-DZ_RELEASE -g0 -O3",
"CMAKE_C_FLAGS_RELEASE": "-DZ_RELEASE -g0 -O3"
}
}
],
"buildPresets": [
{
"name": "vs-msvc-release",
"configurePreset": "visual-studio-17-2022",
"displayName": "Release",
"configuration": "Release",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "vs-msvc-debug",
"configurePreset": "visual-studio-17-2022",
"displayName": "Debug",
"configuration": "Debug",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "Ninja-msvc-release",
"configurePreset": "Ninja-MSVC",
"displayName": "Release",
"configuration": "Release",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "Ninja-msvc-debug",
"configurePreset": "Ninja-MSVC",
"displayName": "Debug",
"configuration": "Debug",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "g++-Release",
"displayName": "Release",
"configurePreset": "Ninja-GCC",
"configuration": "Release",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "g++-Debug",
"displayName": "Debug",
"configurePreset": "Ninja-GCC",
"configuration": "Debug",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "clang++-Release",
"displayName": "Release",
"configurePreset": "Ninja-Clang",
"configuration": "Release",
"verbose": false,
"targets": [ "Spirit", "Test" ]
},
{
"name": "clang++-Debug",
"displayName": "Debug",
"configurePreset": "Ninja-Clang",
"configuration": "Debug",
"verbose": false,
"targets": [ "Spirit", "Test" ]
}
]
}