CMake forces -Werror and -Wthread-safety for all project if adding leveldb as subdirectory with clang
Open
- Dominant language
- C++
- Stars
- 39.4k
- Forks
- 8.2k
- PR merge metrics
- No merged PRs in 30d
Description
[Here](https://github.com/google/leveldb/blob/4fb146810cd265ffefa7f9905c016ae965ad36c8/CMakeLists.txt#L266) 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
Contributor guide
Assessment
This issue has not been assessed yet.