Skip to content

[libc][cmake] Reduce entrypoint list duplication #169077

@michaelrj-google

Description

@michaelrj-google

Currently the list of entrypoints defined for a given platform is listed exclusively in the entrypoints.txt for that platform (e.g. for x86_64/linux: https://github.com/llvm/llvm-project/blob/3ccf8ef715574ae9d2fd041cd9b438dd04a7a002/libc/config/linux/x86_64/entrypoints.txt).

Most of these lists for the same OS target should be the same, but they often drift out of sync. We should change the way entrypoints.txt is handle to better match how config.json is handled: There's a top level definition for every linux target (for example) and then each more specific target can include or exclude individual entrypoints.

To implement this there will need to be a significant refactoring in the main CMake file:

if(EXISTS "${LIBC_CONFIG_PATH}/entrypoints.txt")
.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions