assignUser commented on code in PR #38970:
URL: https://github.com/apache/arrow/pull/38970#discussion_r1410034118


##########
r/configure:
##########
@@ -405,6 +405,21 @@ find_or_build_libarrow
 # Now set `PKG_LIBS`, `PKG_DIRS`, and `PKG_CFLAGS` based on that.
 if [ "$_LIBARROW_FOUND" != "false" ] && [ "$_LIBARROW_FOUND" != "" ]; then
   set_pkg_vars ${_LIBARROW_FOUND}
+
+  # If we didn't find any libraries with pkg-config, try again without 
pkg-config
+  if [ -z "`echo "$PKG_LIBS" | tr -d '[:space:]'`" ] && [ 
"$PKG_CONFIG_AVAILABLE" = "true" ]; then
+    echo "*** pkg-config failed to find libraries. Running detection without 
pkg-config."
+    if arrow_built_with ARROW_S3 || arrow_built_with ARROW_GCS; then
+      S3_LIBS="-lcurl -lssl -lcrypto"
+      GCS_LIBS="-lcurl -lssl -lcrypto"
+    fi
+    PKG_CONFIG_AVAILABLE="false"
+    set_pkg_vars ${_LIBARROW_FOUND}

Review Comment:
   > "-lcurl -lssl -lcrypto" would be better inside of one of the functions
   
   Yes actually :D was a side effect of deduplicating the flags but also 
localizes the flags to the `without_pc` function so the setting is no longer 
spread across the entire script!



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