Skip to content

GH-49789: [C++] Use CMAKE_INSTALL_DOCDIR instead of static share/doc/${PROJECT_NAME}#49802

Closed
Swaroop883 wants to merge 1 commit intoapache:mainfrom
Swaroop883:fix/cmake-install-docdir
Closed

GH-49789: [C++] Use CMAKE_INSTALL_DOCDIR instead of static share/doc/${PROJECT_NAME}#49802
Swaroop883 wants to merge 1 commit intoapache:mainfrom
Swaroop883:fix/cmake-install-docdir

Conversation

@Swaroop883
Copy link
Copy Markdown

@Swaroop883 Swaroop883 commented Apr 20, 2026

Rationale for this change

ARROW_DOC_DIR was hardcoded as "share/doc/${PROJECT_NAME}"
which does not respect system-specific documentation directory
conventions. All other install directories in this file already
use GNUInstallDirs variables (e.g. CMAKE_INSTALL_DATADIR,
CMAKE_INSTALL_LIBDIR). This change makes ARROW_DOC_DIR
consistent with that pattern.

What changes are included in this PR?

  • Replaced set(ARROW_DOC_DIR "share/doc/${PROJECT_NAME}") with
    set(ARROW_DOC_DIR "${CMAKE_INSTALL_DOCDIR}") in
    cpp/CMakeLists.txt.

Are these changes tested?

No new tests are needed. This is a build system change that affects
only the install path of documentation files (LICENSE.txt, NOTICE.txt,
README.md). The behavior is identical on standard systems where
CMAKE_INSTALL_DOCDIR defaults to share/doc/${PROJECT_NAME}.

Are there any user-facing changes?

No. On standard Linux/macOS systems the install path remains
share/doc/arrow. Users who explicitly override CMAKE_INSTALL_DOCDIR
will now have their setting respected, which is the correct behavior.

@Swaroop883
Copy link
Copy Markdown
Author

Closing this as the fix has already been merged in #49790.
Thanks for the quick response!

@Swaroop883 Swaroop883 closed this Apr 20, 2026
@Swaroop883 Swaroop883 deleted the fix/cmake-install-docdir branch April 20, 2026 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant