Skip to content

Commit

Permalink
Moves compiler flags to relevant preset to avoid CMake warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
MattBolitho committed Jan 3, 2025
1 parent 22aac94 commit 3bba11e
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions enzyme/CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,34 +49,34 @@
"cacheVariables": {
"CMAKE_C_COMPILER": "clang",
"CMAKE_CXX_COMPILER": "clang++",
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer",
"CMAKE_CXX_FLAGS_RELEASE": "-O2",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch"
}
},
{
"name": "x64-linux-clang-debug",
"displayName": "Clang x64 Linux Debug",
"inherits": "x64-linux-clang",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug"
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer"
}
},
{
"name": "x64-linux-clang-release",
"displayName": "Clang x64 Linux Release",
"inherits": "x64-linux-clang",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release"
"CMAKE_BUILD_TYPE": "Release",
"CMAKE_CXX_FLAGS_RELEASE": "-O2"
}
},
{
"name": "x64-linux-clang-release-with-debug-info",
"displayName": "Clang x64 Linux Release with Debug Info",
"inherits": "x64-linux-clang",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "RelWithDebInfo"
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
}
},
{
Expand All @@ -90,34 +90,34 @@
"cacheVariables": {
"CMAKE_C_COMPILER": "gcc",
"CMAKE_CXX_COMPILER": "g++",
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch -Wno-comment",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer",
"CMAKE_CXX_FLAGS_RELEASE": "-O2",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch -Wno-comment"
}
},
{
"name": "x64-linux-gcc-debug",
"displayName": "GCC x64 Linux Debug",
"inherits": "x64-linux-gcc",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug"
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer"
}
},
{
"name": "x64-linux-gcc-release",
"displayName": "GCC x64 Linux Release",
"inherits": "x64-linux-gcc",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release"
"CMAKE_BUILD_TYPE": "Release",
"CMAKE_CXX_FLAGS_RELEASE": "-O2"
}
},
{
"name": "x64-linux-gcc-release-with-debug-info",
"displayName": "GCC x64 Linux Release with Debug Info",
"inherits": "x64-linux-gcc",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "RelWithDebInfo"
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
}
},
{
Expand All @@ -131,34 +131,34 @@
"cacheVariables": {
"CMAKE_C_COMPILER": "icx",
"CMAKE_CXX_COMPILER": "icpx",
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch -Wno-comment",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer",
"CMAKE_CXX_FLAGS_RELEASE": "-O2",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
"CMAKE_CXX_FLAGS": "-Wall -fno-rtti -Werror=unused-variable -Werror=dangling-else -Werror=unused-but-set-variable -Werror=return-type -Werror=nonnull -Werror=unused-result -Werror=reorder -Werror=switch -Wno-comment"
}
},
{
"name": "x64-linux-intel-debug",
"displayName": "Intel x64 Linux Debug",
"inherits": "x64-linux-intel",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug"
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_CXX_FLAGS_DEBUG": "-O0 -g -ggdb -fno-omit-frame-pointer"
}
},
{
"name": "x64-linux-intel-release",
"displayName": "Intel x64 Linux Release",
"inherits": "x64-linux-intel",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release"
"CMAKE_BUILD_TYPE": "Release",
"CMAKE_CXX_FLAGS_RELEASE": "-O2"
}
},
{
"name": "x64-linux-intel-release-with-debug-info",
"displayName": "Intel x64 Linux Release with Debug Info",
"inherits": "x64-linux-intel",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "RelWithDebInfo"
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
"CMAKE_CXX_FLAGS_RELWITHDEBINFO": "-O2 -g -ggdb"
}
}
],
Expand Down

0 comments on commit 3bba11e

Please sign in to comment.