WillAyd commented on code in PR #1123:
URL: https://github.com/apache/arrow-adbc/pull/1123#discussion_r1339424296


##########
c/driver/postgresql/CMakeLists.txt:
##########
@@ -51,14 +51,15 @@ add_arrow_lib(adbc_driver_postgresql
               adbc_driver_common
               nanoarrow
               ${LIBPQ_STATIC_LIBRARIES})
-include_directories(SYSTEM ${REPOSITORY_ROOT})
-include_directories(SYSTEM ${REPOSITORY_ROOT}/c/)
-include_directories(SYSTEM ${LIBPQ_INCLUDE_DIRS})
-include_directories(SYSTEM ${REPOSITORY_ROOT}/c/vendor)
-include_directories(SYSTEM ${REPOSITORY_ROOT}/c/driver)
 
 foreach(LIB_TARGET ${ADBC_LIBRARIES})
   target_compile_definitions(${LIB_TARGET} PRIVATE ADBC_EXPORTING)
+  target_include_directories(${LIB_TARGET} SYSTEM
+                             PRIVATE ${REPOSITORY_ROOT}

Review Comment:
   We might want this to be PUBLIC but with that set you get:
   
   ```
   CMake Error in driver/postgresql/CMakeLists.txt:
     Target "adbc_driver_postgresql_shared" INTERFACE_INCLUDE_DIRECTORIES
     property contains path:
   
       "/home/willayd/clones/arrow-adbc/c/vendor"
   
     which is prefixed in the source directory.
   
   
   CMake Error in driver/postgresql/CMakeLists.txt:
     Target "adbc_driver_postgresql_shared" INTERFACE_INCLUDE_DIRECTORIES
     property contains path:
   
       "/home/willayd/clones/arrow-adbc/c/driver"
   
     which is prefixed in the source directory.
   
   
   CMake Error in driver/postgresql/CMakeLists.txt:
     Target "adbc_driver_postgresql_static" INTERFACE_INCLUDE_DIRECTORIES
     property contains path:
   
       "/home/willayd/clones/arrow-adbc/c/vendor"
   
     which is prefixed in the source directory.
   
   
   CMake Error in driver/postgresql/CMakeLists.txt:
     Target "adbc_driver_postgresql_static" INTERFACE_INCLUDE_DIRECTORIES
     property contains path:
   
       "/home/willayd/clones/arrow-adbc/c/driver"
   
     which is prefixed in the source directory.
   ```
   
   I think there is more info here but didn't follow all the way through for 
this repo: 
https://github.com/arvidn/libtorrent/issues/3101#issuecomment-396195787



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