Skip to content

CMake forces -Werror and -Wthread-safety for all project if adding leveldb as subdirectory with clang #1002

Open
@lostystyg

Description

@lostystyg

Here target_compile_options are set with PUBLIC. If leveldb is inlined to source code of a project and added with add_subdirectory with subsequent target_link_libraries(myproject leveldb), this project is forced to be compiled with -Werror and -Wthread-safety.
Probably add these flags as PRIVATE for each leveldb, leveldbutil and tests targets so the underlying project could control compile options itself

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions