CMakePresets.json 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. {
  2. "version": 3,
  3. "configurePresets": [
  4. {
  5. "name": "base",
  6. "generator": "Ninja",
  7. "binaryDir": "${sourceDir}/build",
  8. "hidden": true
  9. },
  10. {
  11. "name": "default",
  12. "displayName": "RelWithDebInfo",
  13. "description": "Enables optimizations (-Og or -O2) with debug information",
  14. "cacheVariables": {
  15. "CMAKE_BUILD_TYPE": "RelWithDebInfo"
  16. },
  17. "inherits": [
  18. "base"
  19. ]
  20. },
  21. {
  22. "name": "debug",
  23. "displayName": "Debug",
  24. "description": "Disables optimizations (-O0), enables debug information",
  25. "cacheVariables": {
  26. "CMAKE_BUILD_TYPE": "Debug"
  27. },
  28. "inherits": [
  29. "base"
  30. ]
  31. },
  32. {
  33. "name": "release",
  34. "displayName": "Release",
  35. "description": "Same as RelWithDebInfo, but disables debug information",
  36. "cacheVariables": {
  37. "CMAKE_BUILD_TYPE": "Release"
  38. },
  39. "inherits": [
  40. "base"
  41. ]
  42. },
  43. {
  44. "name": "windows-default",
  45. "displayName": "Windows x64 RelWithDebInfo",
  46. "description": "Sets Ninja generator, enables optimizations with debug information for x64",
  47. "generator": "Ninja",
  48. "cacheVariables": {
  49. "CMAKE_BUILD_TYPE": "RelWithDebInfo"
  50. },
  51. "architecture": {
  52. "value": "x64",
  53. "strategy": "external"
  54. },
  55. "vendor": {
  56. "microsoft.com/VisualStudioSettings/CMake/1.0": {
  57. "hostOS": [
  58. "Windows"
  59. ]
  60. }
  61. },
  62. "condition": {
  63. "type": "equals",
  64. "lhs": "${hostSystemName}",
  65. "rhs": "Windows"
  66. },
  67. "inherits": [
  68. "base"
  69. ]
  70. }
  71. ],
  72. "buildPresets": [
  73. {
  74. "name": "default",
  75. "configurePreset": "default"
  76. },
  77. {
  78. "name": "debug",
  79. "configurePreset": "debug"
  80. },
  81. {
  82. "name": "release",
  83. "configurePreset": "release"
  84. },
  85. {
  86. "name": "windows-default",
  87. "configurePreset": "windows-default",
  88. "condition": {
  89. "type": "equals",
  90. "lhs": "${hostSystemName}",
  91. "rhs": "Windows"
  92. }
  93. }
  94. ]
  95. }