blob: f23b1b86b25c137fd78e5453b78038f70335899b [file] [log] [blame]
Mirko Bonadei90490372018-10-26 11:17:471# This is supposed to be a complete list of top-level directories,
2# excepting only api/ itself.
kjellander@webrtc.org94a23f02016-03-17 11:05:363include_rules = [
Mirko Bonadeia418e672018-10-24 11:57:254 "-audio",
5 "-base",
6 "-build",
7 "-buildtools",
8 "-build_overrides",
9 "-call",
10 "-common_audio",
11 "-common_video",
12 "-data",
13 "-examples",
Mirko Bonadei583d6d92018-10-24 13:53:3314 "-ios",
Mirko Bonadeia418e672018-10-24 11:57:2515 "-infra",
16 "-logging",
17 "-media",
18 "-modules",
19 "-out",
20 "-p2p",
21 "-pc",
22 "-resources",
23 "-rtc_base",
24 "-rtc_tools",
25 "-sdk",
26 "-stats",
27 "-style-guide",
28 "-system_wrappers",
29 "-test",
30 "-testing",
31 "-third_party",
32 "-tools",
33 "-tools_webrtc",
34 "-video",
35 "-external/webrtc/webrtc", # Android platform build.
36 "-libyuv",
37 "-common_types.h",
38 "-WebRTC",
kjellander@webrtc.org94a23f02016-03-17 11:05:3639]
40
41specific_include_rules = {
Mirko Bonadeia418e672018-10-24 11:57:2542 # Some internal headers are allowed even in API headers:
43 ".*\.h": [
44 "+rtc_base/checks.h",
45 "+rtc_base/system/rtc_export.h",
Sebastian Jansson72bba622018-11-19 10:17:1246 "+rtc_base/units/unit_base.h",
Sebastian Jansson11e55ee2019-03-06 15:58:1847 "+rtc_base/deprecation.h",
Mirko Bonadeia418e672018-10-24 11:57:2548 ],
49
50 "array_view\.h": [
51 "+rtc_base/type_traits.h",
52 ],
53
kwiberg96da0112017-06-30 11:23:2254 # Needed because AudioEncoderOpus is in the wrong place for
55 # backwards compatibilty reasons. See
56 # https://bugs.chromium.org/p/webrtc/issues/detail?id=7847
57 "audio_encoder_opus\.h": [
Mirko Bonadei92ea95e2017-09-15 04:47:3158 "+modules/audio_coding/codecs/opus/audio_encoder_opus.h",
kwiberg96da0112017-06-30 11:23:2259 ],
60
Steve Anton10542f22019-01-11 17:11:0061 "async_resolver_factory\.h": [
62 "+rtc_base/async_resolver_interface.h",
Mirko Bonadeia418e672018-10-24 11:57:2563 ],
64
65 "candidate\.h": [
66 "+rtc_base/network_constants.h",
Steve Anton10542f22019-01-11 17:11:0067 "+rtc_base/socket_address.h",
Mirko Bonadeia418e672018-10-24 11:57:2568 ],
69
Steve Anton10542f22019-01-11 17:11:0070 "data_channel_interface\.h": [
71 "+rtc_base/copy_on_write_buffer.h",
72 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:2573 ],
74
Bjorn A Mellem05497f22019-08-01 17:48:2075 "data_channel_transport_interface\.h": [
76 "+rtc_base/copy_on_write_buffer.h",
77 ],
78
Steve Anton10542f22019-01-11 17:11:0079 "dtls_transport_interface\.h": [
80 "+rtc_base/ref_count.h",
Harald Alvestrand7061e512019-04-10 15:20:4281 "+rtc_base/ssl_certificate.h",
Harald Alvestrandad88c882018-11-28 15:47:4682 ],
83
Steve Anton10542f22019-01-11 17:11:0084 "dtmf_sender_interface\.h": [
85 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:2586 ],
87
88 "fec_controller\.h": [
89 "+modules/include/module_fec_types.h",
90 ],
91
Harald Alvestrand98462622019-01-30 13:57:0392 "ice_transport_interface\.h": [
93 "+rtc_base/ref_count.h",
94 ],
95
Mirko Bonadeia418e672018-10-24 11:57:2596 "jsep\.h": [
Steve Anton10542f22019-01-11 17:11:0097 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:2598 ],
99
Steve Anton10542f22019-01-11 17:11:00100 "jsep_ice_candidate\.h": [
101 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 11:57:25102 ],
103
Steve Anton10542f22019-01-11 17:11:00104 "jsep_session_description\.h": [
105 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 11:57:25106 ],
107
Steve Anton10542f22019-01-11 17:11:00108 "media_stream_interface\.h": [
Mirko Bonadeia418e672018-10-24 11:57:25109 "+modules/audio_processing/include/audio_processing_statistics.h",
Steve Anton10542f22019-01-11 17:11:00110 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25111 ],
112
Bjorn Mellem1f6aa9f2018-10-30 22:15:00113 "media_transport_interface\.h": [
Steve Anton10542f22019-01-11 17:11:00114 "+rtc_base/copy_on_write_buffer.h", # As used by datachannelinterface.h
115 "+rtc_base/network_route.h",
Bjorn Mellem1f6aa9f2018-10-30 22:15:00116 ],
117
Patrik Höglund662e31f2019-09-05 12:35:04118 "packet_socket_factory\.h": [
119 "+rtc_base/proxy_info.h",
120 "+rtc_base/async_packet_socket.h",
121 ],
122
Steve Anton10542f22019-01-11 17:11:00123 "peer_connection_factory_proxy\.h": [
Mirko Bonadeia418e672018-10-24 11:57:25124 "+rtc_base/bind.h",
125 ],
126
Steve Anton10542f22019-01-11 17:11:00127 "peer_connection_interface\.h": [
Steve Anton10542f22019-01-11 17:11:00128 "+media/base/media_config.h",
Steve Anton10542f22019-01-11 17:11:00129 "+media/base/media_engine.h",
130 "+p2p/base/port_allocator.h",
Steve Antonbba675d2018-12-27 19:15:19131 "+rtc_base/network.h",
Steve Anton10542f22019-01-11 17:11:00132 "+rtc_base/rtc_certificate.h",
133 "+rtc_base/rtc_certificate_generator.h",
134 "+rtc_base/socket_address.h",
135 "+rtc_base/ssl_certificate.h",
136 "+rtc_base/ssl_stream_adapter.h",
Steve Antonbba675d2018-12-27 19:15:19137 ],
138
Yves Gerey3e707812018-11-28 15:47:49139 "proxy\.h": [
Steve Antonbba675d2018-12-27 19:15:19140 "+rtc_base/event.h",
Steve Anton10542f22019-01-11 17:11:00141 "+rtc_base/message_handler.h", # Inherits from it.
142 "+rtc_base/message_queue.h", # Inherits from MessageData.
143 "+rtc_base/ref_counted_object.h",
Steve Antonbba675d2018-12-27 19:15:19144 "+rtc_base/thread.h",
Yves Gerey3e707812018-11-28 15:47:49145 ],
146
Steve Anton10542f22019-01-11 17:11:00147 "ref_counted_base\.h": [
148 "+rtc_base/constructor_magic.h",
149 "+rtc_base/ref_count.h",
150 "+rtc_base/ref_counter.h",
Mirko Bonadeia418e672018-10-24 11:57:25151 ],
152
Steve Anton10542f22019-01-11 17:11:00153 "rtc_error\.h": [
Mirko Bonadeia418e672018-10-24 11:57:25154 "+rtc_base/logging.h",
155 ],
Niels Möllerd8b9ed72019-05-08 11:53:51156 "rtc_event_log_output_file.h": [
Niels Möllerd8b9ed72019-05-08 11:53:51157 # For private member and constructor.
158 "+rtc_base/system/file_wrapper.h",
159 ],
Steve Anton10542f22019-01-11 17:11:00160 "rtp_receiver_interface\.h": [
161 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25162 ],
163
Steve Anton10542f22019-01-11 17:11:00164 "rtp_sender_interface\.h": [
165 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25166 ],
167
Steve Anton10542f22019-01-11 17:11:00168 "rtp_transceiver_interface\.h": [
169 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25170 ],
171
Harald Alvestrandc85328f2019-02-28 06:51:00172 "sctp_transport_interface\.h": [
173 "+rtc_base/ref_count.h",
174 ],
175
Steve Anton10542f22019-01-11 17:11:00176 "set_remote_description_observer_interface\.h": [
177 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25178 ],
179
Steve Anton10542f22019-01-11 17:11:00180 "stats_types\.h": [
181 "+rtc_base/constructor_magic.h",
182 "+rtc_base/ref_count.h",
Steve Anton10542f22019-01-11 17:11:00183 "+rtc_base/string_encode.h",
Mirko Bonadeia418e672018-10-24 11:57:25184 "+rtc_base/thread_checker.h",
185 ],
186
Steve Anton10542f22019-01-11 17:11:00187 "uma_metrics\.h": [
188 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25189 ],
190
191 "audio_frame\.h": [
Steve Anton10542f22019-01-11 17:11:00192 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 11:57:25193 ],
194
195 "audio_mixer\.h": [
Steve Anton10542f22019-01-11 17:11:00196 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25197 ],
198
199 "audio_decoder\.h": [
200 "+rtc_base/buffer.h",
Steve Anton10542f22019-01-11 17:11:00201 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 11:57:25202 ],
203
204 "audio_decoder_factory\.h": [
Steve Anton10542f22019-01-11 17:11:00205 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25206 ],
207
208 "audio_decoder_factory_template\.h": [
Steve Anton10542f22019-01-11 17:11:00209 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 11:57:25210 ],
211
212 "audio_encoder\.h": [
213 "+rtc_base/buffer.h",
Mirko Bonadeia418e672018-10-24 11:57:25214 ],
215
216 "audio_encoder_factory\.h": [
Steve Anton10542f22019-01-11 17:11:00217 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25218 ],
219
220 "audio_encoder_factory_template\.h": [
Steve Anton10542f22019-01-11 17:11:00221 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 11:57:25222 ],
223
Steve Anton10542f22019-01-11 17:11:00224 "frame_decryptor_interface\.h": [
225 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25226 ],
227
Steve Anton10542f22019-01-11 17:11:00228 "frame_encryptor_interface\.h": [
229 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25230 ],
231
Steve Anton10542f22019-01-11 17:11:00232 "rtc_stats_collector_callback\.h": [
233 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25234 ],
235
Steve Anton10542f22019-01-11 17:11:00236 "rtc_stats_report\.h": [
237 "+rtc_base/ref_count.h",
238 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 11:57:25239 ],
240
241 "audioproc_float\.h": [
242 "+modules/audio_processing/include/audio_processing.h",
243 ],
244
245 "fake_frame_decryptor\.h": [
Steve Anton10542f22019-01-11 17:11:00246 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 11:57:25247 ],
248
249 "fake_frame_encryptor\.h": [
Steve Anton10542f22019-01-11 17:11:00250 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 11:57:25251 ],
252
Mirko Bonadeia418e672018-10-24 11:57:25253 "mock.*\.h": [
254 "+test/gmock.h",
255 ],
256
257 "simulated_network\.h": [
Steve Anton10542f22019-01-11 17:11:00258 "+rtc_base/critical_section.h",
Mirko Bonadeia418e672018-10-24 11:57:25259 "+rtc_base/random.h",
260 "+rtc_base/thread_annotations.h",
261 ],
262
263 "test_dependency_factory\.h": [
264 "+rtc_base/thread_checker.h",
265 ],
266
267 "videocodec_test_fixture\.h": [
268 "+modules/video_coding/include/video_codec_interface.h"
269 ],
270
Mirko Bonadeia418e672018-10-24 11:57:25271 "video_encoder_config\.h": [
Steve Anton10542f22019-01-11 17:11:00272 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 11:57:25273 ],
274
Mirko Bonadei90490372018-10-26 11:17:47275 # .cc files in api/ should not be restricted in what they can #include,
276 # so we re-add all the top-level directories here. (That's because .h
277 # files leak their #includes to whoever's #including them, but .cc files
278 # do not since no one #includes them.)
kwiberg087bd342017-02-10 16:15:44279 ".*\.cc": [
Mirko Bonadeia418e672018-10-24 11:57:25280 "+audio",
281 "+call",
282 "+common_audio",
283 "+common_video",
284 "+examples",
285 "+logging",
286 "+media",
287 "+modules",
288 "+p2p",
289 "+pc",
290 "+rtc_base",
291 "+rtc_tools",
292 "+sdk",
293 "+stats",
294 "+system_wrappers",
295 "+test",
296 "+tools",
297 "+tools_webrtc",
298 "+video",
299 "+third_party",
kwiberg1e4e8cb2017-01-31 09:48:08300 ],
kjellander@webrtc.org94a23f02016-03-17 11:05:36301}