forked from protocolbuffers/protobuf
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update cc_dist_library() to include transitive sources
The cc_dist_library() rule originally included only the sources from direct dependencies. This resulted in a less than ideal developer experience, because if you ever added a new cc_library() then you would have to carefully update the necessary cc_dist_library() targets to ensure that the change was correctly reflected in the CMake build. This commit addresses that issue by making cc_dist_library() include transitive sources. We have to be careful to avoid introducing ODR violations (e.g. from libprotoc duplicating sources from libprotobuf), so we introduce a new dist_deps attribute on cc_dist_library(). Anything in dist_deps is assumed to be covered by a separate cc_dist_library() and is not included. We also make sure to exclude anything that's not part of our repo (i.e. Abseil and zlib).
- Loading branch information
Showing
3 changed files
with
88 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters