lidavidm commented on code in PR #1609:
URL: https://github.com/apache/arrow-adbc/pull/1609#discussion_r1522101837
##########
c/cmake_modules/AdbcDefines.cmake:
##########
@@ -92,6 +92,17 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang"
-Werror
-Wno-unused-parameter)
set(ADBC_C_CXX_FLAGS_PRODUCTION -Wall)
+
+ string(APPEND C_DEBUG_FLAGS " -Og -ggdb")
+ string(APPEND CXX_DEBUG_FLAGS " -Og -ggdb")
+ string(APPEND C_RELWITHDEBINFO_FLAGS " -Og -ggdb")
+ string(APPEND CXX_RELWITHDEBINFO_FLAGS " -Og -ggdb")
+
+ if("${_lower_build_type}" STREQUAL "debug" AND "${CMAKE_CXX_FLAGS}" MATCHES
"-O2")
+ # Activate scripts for Conda compilers set CXXFLAGS etc. with -O2.
+ message(WARNING "This is a debug build, but your CXXFLAGS have -O2. This
is common in Conda environments.\nReset your CFLAGS, CPPFLAGS, and CXXFLAGS to
-Og for debugging."
Review Comment:
I'll give this a shot, thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]