Skip to content

RFC: Don't use GLOB in CMake files #4442

@amitdo

Description

@amitdo

https://cmake.org/cmake/help/latest/command/file.html#glob

Note We do not recommend using GLOB to collect a list of source files from your source tree. If no CMakeLists.txt file changes when a source is added or removed then the generated build system cannot know when to ask CMake to regenerate. The CONFIGURE_DEPENDS flag may not work reliably on all generators, or if a new generator is added in the future that cannot support it, projects using it will be stuck. Even if CONFIGURE_DEPENDS works reliably, there is still a cost to perform the check on every rebuild.

https://github.com/search?q=repo%3Atesseract-ocr%2Ftesseract+glob+language%3Acmake&type=code

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions