WillAyd commented on code in PR #483:
URL: https://github.com/apache/arrow-nanoarrow/pull/483#discussion_r1635088660


##########
src/nanoarrow/meson.build:
##########
@@ -147,4 +166,38 @@ if get_option('tests')
                                        include_directories: incdir)
   test('c_data_integration test', c_data_integration_test)
 
+  if get_option('ipc')
+      zlib_dep = dependency('zlib')
+      ipc_test_files = {
+          'nanoarrow-ipc-decoder': {
+              'deps': [nanoarrow_dep, flatcc_dep, arrow_dep, gtest_dep],
+          },
+          'nanoarrow-ipc-reader': {
+              'deps': [nanoarrow_dep, flatcc_dep, arrow_dep, gtest_dep],
+          },
+          'nanoarrow-ipc-files': {
+              'deps': [
+                  nanoarrow_dep,
+                  flatcc_dep,
+                  zlib_dep,
+                  arrow_dep,
+                  gtest_dep,
+                  nlohmann_json_dep
+              ],
+          },
+          'nanoarrow-ipc-hpp': {
+              'deps': [nanoarrow_dep, flatcc_dep, gtest_dep],
+          },
+      }
+
+      foreach name, config : ipc_test_files
+          exc = executable(
+              name + '-test',
+              name.replace('-', '_') + '_test.cc',
+              link_with: nanoarrow_ipc_lib,
+              dependencies: config['deps']

Review Comment:
   Not sure I understand the first question - what problem are you trying to 
solve by making that a direct link argument? The way the dependency is declared 
(see [wrapdb 
source](https://github.com/mesonbuild/wrapdb/blob/a67b90d64e63fd52d0026ec24cb9972b831c2564/subprojects/packagefiles/gtest/googletest/meson.build#L14))
 I believe Meson will take care of that linkage for you, alongside having the 
proper include and threads dependency
   
   As far as the second question goes the way I had this previously the 
dependencies were not transitive, but I've since updated the nanoarrow_ipc_dep 
to include those:
   
   ```python
   nanoarrow_ipc_dep = declare_dependency(..., dependencies: [nanoarrow_dep, 
flatcc_dep])
   ```



-- 
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]

Reply via email to