Skip to content

GH-55583: [C++] Export arrow_bundled_dependencies with install(TARGETS) - #55620

Open
AnuragRaut08 wants to merge 1 commit into
apache:mainfrom
AnuragRaut08:fix/55583-export-bundled-dependencies
Open

AnuragRaut08 wants to merge 1 commit into
apache:mainfrom
AnuragRaut08:fix/55583-export-bundled-dependencies

Conversation

@AnuragRaut08

@AnuragRaut08 AnuragRaut08 commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Rationale for this change

Currently, Arrow creates the arrow_bundled_dependencies and arrow_gcs_bundled_dependencies imported targets manually in the installed CMake package configuration files.

This makes the bundled dependency archives harder to manage through CMake's standard install and export mechanisms.

This change exports these archives as regular CMake targets using install(TARGETS).

What changes are included in this PR?

  • Replace the manually created imported bundled dependency targets with regular static library targets.
  • Update arrow_create_merged_static_lib() to create a real static library target and merge dependency archives using a post-build command.
  • Export and install Arrow and Arrow GCS bundled dependency targets through their respective CMake exports.
  • Propagate external link requirements from the bundled dependencies through their installed target interfaces.
  • Move platform-specific AWS CRT link requirements for Apple and Windows into the aws-c-common target.
  • Remove the manual bundled dependency target creation from ArrowConfig.cmake.in and ArrowGcsConfig.cmake.in.

Are these changes tested?

Tested locally on Linux:

  • Built and installed Arrow with bundled mimalloc, uriparser, and simdjson.
  • Verified that the merged libarrow_bundled_dependencies.a archive contains 48 members.
  • Built and ran a downstream Arrow-only CMake consumer that performs a memory allocation using the mimalloc backend.
  • Built and installed Arrow with GCS enabled and bundled google-cloud-cpp.
  • Built and ran a downstream GCS CMake consumer successfully.
  • Verified that the installed GCS targets do not contain nlohmann_json references.
  • Verified that the installed GCS package discovers CURL and OpenSSL as system dependencies.
  • Ran the cmake-format pre-commit hook successfully.
  • Ran git diff --check.

Not tested:

  • macOS and Windows builds.
  • Bundled Abseil configuration.
  • S3 and Flight bundled dependency configurations.
  • R packaging build. The R configure scripts and bundled archive references were reviewed, but the packaging build was not run.

Are there any user-facing changes?

No. These changes affect the CMake build, installation, and package export behavior. There are no intended changes to Arrow's public APIs.

PR code and description written by:

  • Human
  • AI

Reviewed before submission by:

  • Human
  • AI
  • Not reviewed

@github-actions

Copy link
Copy Markdown

⚠️ GitHub issue #55583 has been automatically assigned in GitHub to PR creator.

@kou

kou commented Nov 15, 2026

Copy link
Copy Markdown
Member

Is this correct?


PR code and description written by:

  • Human
  • AI

Reviewed before submission by:

  • Human
  • AI
  • Not reviewed

Could you check CI failures?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants