Slow cmake glob checks

Open
#46 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
cmake, cpp

Research direction

Start with CMakeLists.txt around line 26 in Boost.Assert and inspect how CONFIGURE_DEPENDS is applied to globbed files. Reproduce the "Re-checking globbed directories..." delay in a CMake project using Boost through add_subdirectory, then verify that dependency builds no longer incur the costly re-check while normal glob behavior remains correct.

Written by the indexing model from the issue text.

Description

On a cmake project that makes use of boost via add_subdirectory, the "Re-checking globbed directories..." stage at the start of the build will occasionally take several tens of seconds. This traces down to the use of CONFIGURE_DEPENDS on Boost.Assert and other Boost libraries.

https://github.com/boostorg/assert/blob/af15ced8d04907345a0211dab46557e085960eb7/CMakeLists.txt#L26

Consider disabling CONFIGURE_DEPENDS when Boost is used as a dependency, as glob results shouldn't change and re-checking can be costly.

Dominant language
C++
Stars
35
Forks
77
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from boostorg/assert

All issues in boostorg/assert

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.