Skip to content

Keep a pure usage of generic.cmake #9612

@wangkuiyi

Description

@wangkuiyi

I notice new hacks in our CMakeLists.txt like the following

set(DISTRIBUTE_COMPILE_FLAGS "-Wno-non-virtual-dtor -Wno-error=non-virtual-dtor -Wno-error=delete-non-virtual-dtor")
set_source_files_properties(serde_test.cc grpc_server_test.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS})

Please remove such hack and never use them. Please make sure that CMakeLists.txt includes only calls to CMake functions defined in generic.cmake.

We used to suffer from the problem that CMake provides a very flexible language and we hack our CMakeLists.txt everywhere. This made it extremely challenging to keep our build process understandable, and it took a huge effort of the team, particular thanks to @gangliao , to clean everything up by developing generic.cmake.

Metadata

Metadata

Assignees

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