Skip to content

Commit

Permalink
Merge pull request #952 from IntelPython/fix-compilation-warning-in-g…
Browse files Browse the repository at this point in the history
…en-docs

Use -O0 alongside -ggdb3 to address compiler warning
  • Loading branch information
oleksandr-pavlyk authored Oct 26, 2022
2 parents 9e934b2 + 0750d65 commit fcca59e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libsyclinterface/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -114,10 +114,10 @@ if(WIN32)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${WARNING_FLAGS}")
set(CMAKE_C_FLAGS_DEBUG
"${CMAKE_C_FLAGS_DEBUG} ${WARNING_FLAGS} -ggdb3 -DDEBUG"
"${CMAKE_C_FLAGS_DEBUG} ${WARNING_FLAGS} -O0 -ggdb3 -DDEBUG"
)
set(CMAKE_CXX_FLAGS_DEBUG
"${CMAKE_CXX_FLAGS_DEBUG} ${WARNING_FLAGS} -ggdb3 -DDEBUG"
"${CMAKE_CXX_FLAGS_DEBUG} ${WARNING_FLAGS} -O0 -ggdb3 -DDEBUG"
)
elseif(UNIX)
string(CONCAT WARNING_FLAGS
Expand Down Expand Up @@ -152,10 +152,10 @@ elseif(UNIX)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CFLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXXFLAGS}")
set(CMAKE_C_FLAGS_DEBUG
"${CMAKE_C_FLAGS_DEBUG} ${CFLAGS} -ggdb3 -DDEBUG"
"${CMAKE_C_FLAGS_DEBUG} ${CFLAGS} -O0 -ggdb3 -DDEBUG"
)
set(CMAKE_CXX_FLAGS_DEBUG
"${CMAKE_CXX_FLAGS_DEBUG} ${CXXFLAGS} -ggdb3 -DDEBUG"
"${CMAKE_CXX_FLAGS_DEBUG} ${CXXFLAGS} -O0 -ggdb3 -DDEBUG"
)
else()
message(FATAL_ERROR "Unsupported system.")
Expand Down

0 comments on commit fcca59e

Please sign in to comment.