~neon/kmouth/master

637 by Laurent Montel
Add cmake preset support
1
{
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
2
    "version": 3,
637 by Laurent Montel
Add cmake preset support
3
    "configurePresets": [
4
        {
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
5
            "name": "base",
6
            "displayName": "base preset",
7
            "generator": "Ninja",
8
            "binaryDir": "${sourceDir}/build-${presetName}",
9
            "installDir": "$env{KF6}",
10
            "hidden": true,
11
            "cacheVariables": {
12
                "BUILD_QCH": "ON"
13
            }
14
        },
15
        {
16
            "name": "dev-mold",
17
            "displayName": "Build as debug + using mold linker",
18
            "cacheVariables": {
19
                "CMAKE_BUILD_TYPE": "Debug",
20
                "CMAKE_EXPORT_COMPILE_COMMANDS": "ON",
21
                "CMAKE_SHARED_LINKER_FLAGS": "-fuse-ld=mold"
22
            },
23
            "inherits": [
24
                "base"
25
            ]
26
        },
27
        {
637 by Laurent Montel
Add cmake preset support
28
            "name": "dev",
29
            "displayName": "Build as debug",
30
            "cacheVariables": {
31
                "CMAKE_BUILD_TYPE": "Debug",
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
32
                "CMAKE_EXPORT_COMPILE_COMMANDS": "ON"
33
            },
34
            "inherits": [
35
                "base"
36
            ]
637 by Laurent Montel
Add cmake preset support
37
        },
38
        {
39
            "name": "asan",
40
            "displayName": "Build with Asan support.",
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
41
            "cacheVariables": {
42
                "CMAKE_BUILD_TYPE": "Debug",
43
                "ECM_ENABLE_SANITIZERS" : "'address;undefined'"
44
            },
45
            "inherits": [
46
                "base"
47
            ]
48
        },
49
        {
50
            "name": "dev-clang",
51
            "displayName": "dev-clang",
52
            "cacheVariables": {
53
                "CMAKE_BUILD_TYPE": "Debug",
54
                "CMAKE_EXPORT_COMPILE_COMMANDS": "ON"
55
            },
56
            "environment": {
57
                "CXX": "clang++",
58
                "CCACHE_DISABLE": "ON"
59
            },
60
            "inherits": [
61
                "base"
62
            ]
637 by Laurent Montel
Add cmake preset support
63
        },
64
        {
65
            "name": "unity",
66
            "displayName": "Build with CMake unity support.",
67
            "cacheVariables": {
68
                "CMAKE_BUILD_TYPE": "Debug",
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
69
                "USE_UNITY_CMAKE_SUPPORT": "ON"
70
            },
71
            "inherits": [
72
                "base"
73
            ]
637 by Laurent Montel
Add cmake preset support
74
        },
75
        {
76
            "name": "release",
77
            "displayName": "Build as release mode.",
78
            "cacheVariables": {
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
79
                "CMAKE_BUILD_TYPE": "Release",
80
                "BUILD_TESTING": "OFF"
81
            },
82
            "inherits": [
83
                "base"
84
            ]
637 by Laurent Montel
Add cmake preset support
85
        },
86
        {
87
            "name": "profile",
88
            "displayName": "profile",
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
89
            "cacheVariables": {
90
                "CMAKE_BUILD_TYPE": "RelWithDebInfo"
91
            },
92
            "inherits": [
93
                "base"
94
            ]
95
        },
96
        {
97
            "name": "coverage",
98
            "displayName": "coverage",
99
            "cacheVariables": {
100
                "CMAKE_BUILD_TYPE": "Debug",
101
                "USE_UNITY_CMAKE_SUPPORT": "OFF",
102
                "BUILD_COVERAGE": "ON"
103
            },
104
            "inherits": [
105
                "base"
106
            ]
107
        },
640 by Laurent Montel
Add clazy + build support
108
        {
109
            "name": "clazy",
110
            "displayName": "clazy",
111
            "cacheVariables": {
112
                "CMAKE_BUILD_TYPE": "Debug"
113
            },
114
            "environment": {
115
                "CXX": "clazy",
116
                "CCACHE_DISABLE": "ON"
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
117
            },
118
            "inherits": [
119
                "base"
120
            ]
121
        },
122
        {
123
            "name": "pch",
124
            "displayName": "pch",
125
            "cacheVariables": {
126
                "CMAKE_BUILD_TYPE": "Debug",
127
                "USE_PRECOMPILED_HEADERS": "ON",
128
                "BUILD_COVERAGE": "ON"
129
            },
130
            "inherits": [
131
                "base"
132
            ]
640 by Laurent Montel
Add clazy + build support
133
        }
134
    ],
135
    "buildPresets": [
136
        {
137
            "name": "dev",
138
            "configurePreset": "dev"
139
        },
140
        {
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
141
            "name": "dev-mold",
142
            "configurePreset": "dev-mold"
143
        },
144
        {
145
            "name": "dev-clang",
146
            "configurePreset": "dev-clang"
147
        },
148
        {
149
            "name": "pch",
150
            "configurePreset": "pch"
151
        },
152
        {
153
            "name": "release",
154
            "configurePreset": "release"
155
        },
156
        {
157
            "name": "unity",
158
            "configurePreset": "unity"
159
        },
160
        {
161
            "name": "coverage",
162
            "configurePreset": "coverage"
163
        },
164
        {
165
            "name": "asan",
166
            "configurePreset": "asan"
167
        },
168
        {
640 by Laurent Montel
Add clazy + build support
169
            "name": "clazy",
170
            "configurePreset": "clazy",
171
            "environment": {
172
                "CLAZY_CHECKS" : "level0,level1,detaching-member,ifndef-define-typo,isempty-vs-count,qrequiredresult-candidates,reserve-candidates,signal-with-return-value,unneeded-cast,function-args-by-ref,function-args-by-value,returning-void-expression,no-ctor-missing-parent-argument,isempty-vs-count,qhash-with-char-pointer-key,raw-environment-function,qproperty-type-mismatch,old-style-connect,qstring-allocations,container-inside-loop,heap-allocated-small-trivial-type,inefficient-qlist,qstring-varargs,level2,detaching-member,heap-allocated-small-trivial-type,isempty-vs-count,qstring-varargs,qvariant-template-instantiation,raw-environment-function,reserve-candidates,signal-with-return-value,thread-with-slots,no-ctor-missing-parent-argument,no-missing-typeinfo",
173
                "CCACHE_DISABLE" : "ON"
174
            }
175
        }
815 by Laurent Montel
GIT_SILENT: Update CMakePresets.json
176
    ],
177
    "testPresets": [
178
    {
179
      "name": "dev",
180
      "configurePreset": "dev",
181
      "output": {"outputOnFailure": true},
182
      "execution": {"noTestsAction": "error", "stopOnFailure": false}
183
    },
184
    {
185
      "name": "asan",
186
      "configurePreset": "asan",
187
      "output": {"outputOnFailure": true},
188
      "execution": {"noTestsAction": "error", "stopOnFailure": true}
189
    },
190
    {
191
      "name": "unity",
192
      "configurePreset": "unity",
193
      "output": {"outputOnFailure": true},
194
      "execution": {"noTestsAction": "error", "stopOnFailure": true}
195
    },
196
    {
197
      "name": "coverage",
198
      "configurePreset": "coverage",
199
      "output": {"outputOnFailure": true},
200
      "execution": {"noTestsAction": "error", "stopOnFailure": true}
201
    }
202
  ]
637 by Laurent Montel
Add cmake preset support
203
}