lidavidm commented on code in PR #2449:
URL: https://github.com/apache/arrow-adbc/pull/2449#discussion_r1915835597


##########
c/cmake_modules/GoUtils.cmake:
##########
@@ -87,10 +87,10 @@ function(add_go_lib GO_MOD_DIR GO_LIBNAME)
   separate_arguments(GO_BUILD_FLAGS NATIVE_COMMAND
                      "${GO_BUILD_FLAGS} $<$<CONFIG:DEBUG>:-gcflags=\"-N -l\">")
 
-  # if we're building debug mode then change the default CGO_CFLAGS and 
CGO_CXXFLAGS from "-g O2" to "-g3"
-  set(GO_ENV_VARS
-      "CGO_ENABLED=1 $<$<CONFIG:DEBUG>:CGO_CFLAGS=-g3> 
$<$<CONFIG:DEBUG>:CGO_CXXFLAGS=-g3>"
-  )
+  # if we're building debug mode then change the default and CGO_CXXFLAGS from 
"-g O2" to "-g3"
+  # We can't add CGO_CFLAGS=-g3 because it will result in no longer inlining 
the ArrowArray* helper
+  # functions used internally within the cdata Go package, causing linker 
errors of missing symbols.
+  set(GO_ENV_VARS "CGO_ENABLED=1 $<$<CONFIG:DEBUG>:CGO_CXXFLAGS=-g3>")

Review Comment:
   
https://stackoverflow.com/questions/62374711/c-inline-function-generates-undefined-symbols-error
   
   It looks like they should all be `static inline`



-- 
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: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to