blob: 0b8a70eabf003cd62f0a25cffb3724bbde2ce502 [file] [log] [blame]
Mirko Bonadei90490372018-10-26 13:17:47 +02001# This is supposed to be a complete list of top-level directories,
2# excepting only api/ itself.
kjellander@webrtc.org94a23f02016-03-17 12:05:36 +01003include_rules = [
Mirko Bonadeia418e672018-10-24 13:57:25 +02004 "-audio",
5 "-base",
6 "-build",
7 "-buildtools",
8 "-build_overrides",
9 "-call",
10 "-common_audio",
11 "-common_video",
12 "-data",
13 "-examples",
Artem Titov6512af02021-03-01 17:30:29 +010014 "-g3doc",
Mirko Bonadei583d6d92018-10-24 15:53:33 +020015 "-ios",
Mirko Bonadeia418e672018-10-24 13:57:25 +020016 "-infra",
17 "-logging",
18 "-media",
Victor Boivie7d3c49a2021-03-25 13:11:03 +010019 "-net",
Mirko Bonadeia418e672018-10-24 13:57:25 +020020 "-modules",
21 "-out",
22 "-p2p",
23 "-pc",
24 "-resources",
25 "-rtc_base",
26 "-rtc_tools",
27 "-sdk",
28 "-stats",
29 "-style-guide",
30 "-system_wrappers",
31 "-test",
32 "-testing",
33 "-third_party",
34 "-tools",
35 "-tools_webrtc",
36 "-video",
37 "-external/webrtc/webrtc", # Android platform build.
38 "-libyuv",
39 "-common_types.h",
40 "-WebRTC",
kjellander@webrtc.org94a23f02016-03-17 12:05:36 +010041]
42
43specific_include_rules = {
Mirko Bonadeia418e672018-10-24 13:57:25 +020044 # Some internal headers are allowed even in API headers:
Vojin Ilic504fc192021-05-31 14:02:28 +020045
46 "call_factory_interface\.h": [
47 "+call/rtp_transport_controller_send_factory_interface.h",
48 ],
49
Mirko Bonadeia418e672018-10-24 13:57:25 +020050 ".*\.h": [
51 "+rtc_base/checks.h",
52 "+rtc_base/system/rtc_export.h",
Mirko Bonadei054f1852019-11-04 16:31:08 +010053 "+rtc_base/system/rtc_export_template.h",
Sebastian Jansson72bba622018-11-19 11:17:12 +010054 "+rtc_base/units/unit_base.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +020055 ],
56
57 "array_view\.h": [
58 "+rtc_base/type_traits.h",
59 ],
60
kwiberg96da0112017-06-30 04:23:22 -070061 # Needed because AudioEncoderOpus is in the wrong place for
62 # backwards compatibilty reasons. See
63 # https://bugs.chromium.org/p/webrtc/issues/detail?id=7847
64 "audio_encoder_opus\.h": [
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020065 "+modules/audio_coding/codecs/opus/audio_encoder_opus.h",
kwiberg96da0112017-06-30 04:23:22 -070066 ],
67
Steve Anton10542f22019-01-11 09:11:00 -080068 "async_resolver_factory\.h": [
69 "+rtc_base/async_resolver_interface.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +020070 ],
71
Harald Alvestrande6e2f282021-03-24 12:13:28 +000072 "async_dns_resolver\.h": [
73 "+rtc_base/socket_address.h",
74 ],
75
Mirko Bonadeia418e672018-10-24 13:57:25 +020076 "candidate\.h": [
77 "+rtc_base/network_constants.h",
Steve Anton10542f22019-01-11 09:11:00 -080078 "+rtc_base/socket_address.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +020079 ],
80
Steve Anton10542f22019-01-11 09:11:00 -080081 "data_channel_interface\.h": [
82 "+rtc_base/copy_on_write_buffer.h",
83 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +020084 ],
85
Bjorn A Mellem05497f22019-08-01 10:48:20 -070086 "data_channel_transport_interface\.h": [
87 "+rtc_base/copy_on_write_buffer.h",
88 ],
89
Steve Anton10542f22019-01-11 09:11:00 -080090 "dtls_transport_interface\.h": [
91 "+rtc_base/ref_count.h",
Harald Alvestrand7061e512019-04-10 17:20:42 +020092 "+rtc_base/ssl_certificate.h",
Harald Alvestrandad88c882018-11-28 16:47:46 +010093 ],
94
Steve Anton10542f22019-01-11 09:11:00 -080095 "dtmf_sender_interface\.h": [
96 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +020097 ],
98
99 "fec_controller\.h": [
100 "+modules/include/module_fec_types.h",
101 ],
102
Marina Cioceae3e07bf2020-02-27 16:28:51 +0100103 "frame_transformer_interface\.h": [
104 "+rtc_base/ref_count.h",
105 ],
106
Harald Alvestrand98462622019-01-30 14:57:03 +0100107 "ice_transport_interface\.h": [
108 "+rtc_base/ref_count.h",
109 ],
110
Mirko Bonadeia418e672018-10-24 13:57:25 +0200111 "jsep\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800112 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200113 ],
114
Steve Anton10542f22019-01-11 09:11:00 -0800115 "jsep_ice_candidate\.h": [
116 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200117 ],
118
Steve Anton10542f22019-01-11 09:11:00 -0800119 "jsep_session_description\.h": [
120 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200121 ],
122
Steve Anton10542f22019-01-11 09:11:00 -0800123 "media_stream_interface\.h": [
Mirko Bonadeia418e672018-10-24 13:57:25 +0200124 "+modules/audio_processing/include/audio_processing_statistics.h",
Steve Anton10542f22019-01-11 09:11:00 -0800125 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200126 ],
127
Patrik Höglund662e31f2019-09-05 14:35:04 +0200128 "packet_socket_factory\.h": [
129 "+rtc_base/proxy_info.h",
130 "+rtc_base/async_packet_socket.h",
131 ],
132
Steve Anton10542f22019-01-11 09:11:00 -0800133 "peer_connection_interface\.h": [
Vojin Ilic504fc192021-05-31 14:02:28 +0200134 "+call/rtp_transport_controller_send_factory_interface.h",
Steve Anton10542f22019-01-11 09:11:00 -0800135 "+media/base/media_config.h",
Steve Anton10542f22019-01-11 09:11:00 -0800136 "+media/base/media_engine.h",
Harald Alvestrandf33f7a22021-05-09 14:58:57 +0000137 "+p2p/base/port.h",
Steve Anton10542f22019-01-11 09:11:00 -0800138 "+p2p/base/port_allocator.h",
Harald Alvestrandf33f7a22021-05-09 14:58:57 +0000139 "+rtc_base/network.h",
140 "+rtc_base/network_constants.h",
Taylor Brandstetter239ac8a2020-07-31 16:07:52 -0700141 "+rtc_base/network_monitor_factory.h",
Harald Alvestrandf33f7a22021-05-09 14:58:57 +0000142 "+rtc_base/ref_count.h",
Steve Anton10542f22019-01-11 09:11:00 -0800143 "+rtc_base/rtc_certificate.h",
144 "+rtc_base/rtc_certificate_generator.h",
145 "+rtc_base/socket_address.h",
146 "+rtc_base/ssl_certificate.h",
147 "+rtc_base/ssl_stream_adapter.h",
Harald Alvestrandf33f7a22021-05-09 14:58:57 +0000148 "+rtc_base/thread.h",
Steve Antonbba675d2018-12-27 11:15:19 -0800149 ],
150
Yves Gerey3e707812018-11-28 16:47:49 +0100151 "proxy\.h": [
Steve Antonbba675d2018-12-27 11:15:19 -0800152 "+rtc_base/event.h",
Steve Anton10542f22019-01-11 09:11:00 -0800153 "+rtc_base/message_handler.h", # Inherits from it.
Steve Anton10542f22019-01-11 09:11:00 -0800154 "+rtc_base/ref_counted_object.h",
Steve Antonbba675d2018-12-27 11:15:19 -0800155 "+rtc_base/thread.h",
Yves Gerey3e707812018-11-28 16:47:49 +0100156 ],
157
Steve Anton10542f22019-01-11 09:11:00 -0800158 "ref_counted_base\.h": [
159 "+rtc_base/constructor_magic.h",
160 "+rtc_base/ref_count.h",
161 "+rtc_base/ref_counter.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200162 ],
163
Steve Anton10542f22019-01-11 09:11:00 -0800164 "rtc_error\.h": [
Mirko Bonadeia418e672018-10-24 13:57:25 +0200165 "+rtc_base/logging.h",
166 ],
Niels Möllerd8b9ed72019-05-08 13:53:51 +0200167 "rtc_event_log_output_file.h": [
Niels Möllerd8b9ed72019-05-08 13:53:51 +0200168 # For private member and constructor.
169 "+rtc_base/system/file_wrapper.h",
170 ],
Niels Möllerbb57de22022-01-11 15:40:22 +0100171 "rtp_packet_infos\.h": [
172 "+rtc_base/ref_counted_object.h",
173 ],
Steve Anton10542f22019-01-11 09:11:00 -0800174 "rtp_receiver_interface\.h": [
175 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200176 ],
177
Steve Anton10542f22019-01-11 09:11:00 -0800178 "rtp_sender_interface\.h": [
179 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200180 ],
181
Steve Anton10542f22019-01-11 09:11:00 -0800182 "rtp_transceiver_interface\.h": [
183 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200184 ],
185
Harald Alvestrandc85328f2019-02-28 07:51:00 +0100186 "sctp_transport_interface\.h": [
187 "+rtc_base/ref_count.h",
188 ],
189
Henrik Boström831ae4e2020-07-29 12:04:00 +0200190 "set_local_description_observer_interface\.h": [
191 "+rtc_base/ref_count.h",
192 ],
Steve Anton10542f22019-01-11 09:11:00 -0800193 "set_remote_description_observer_interface\.h": [
194 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200195 ],
196
Steve Anton10542f22019-01-11 09:11:00 -0800197 "stats_types\.h": [
198 "+rtc_base/constructor_magic.h",
199 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200200 "+rtc_base/thread_checker.h",
201 ],
202
Steve Anton10542f22019-01-11 09:11:00 -0800203 "uma_metrics\.h": [
204 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200205 ],
206
207 "audio_frame\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800208 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200209 ],
210
211 "audio_mixer\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800212 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200213 ],
214
215 "audio_decoder\.h": [
216 "+rtc_base/buffer.h",
Steve Anton10542f22019-01-11 09:11:00 -0800217 "+rtc_base/constructor_magic.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200218 ],
219
220 "audio_decoder_factory\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800221 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200222 ],
223
224 "audio_decoder_factory_template\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800225 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200226 ],
227
228 "audio_encoder\.h": [
229 "+rtc_base/buffer.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200230 ],
231
232 "audio_encoder_factory\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800233 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200234 ],
235
236 "audio_encoder_factory_template\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800237 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200238 ],
239
Steve Anton10542f22019-01-11 09:11:00 -0800240 "frame_decryptor_interface\.h": [
241 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200242 ],
243
Steve Anton10542f22019-01-11 09:11:00 -0800244 "frame_encryptor_interface\.h": [
245 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200246 ],
247
Steve Anton10542f22019-01-11 09:11:00 -0800248 "rtc_stats_collector_callback\.h": [
249 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200250 ],
251
Steve Anton10542f22019-01-11 09:11:00 -0800252 "rtc_stats_report\.h": [
253 "+rtc_base/ref_count.h",
254 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200255 ],
256
257 "audioproc_float\.h": [
258 "+modules/audio_processing/include/audio_processing.h",
259 ],
260
Sam Zackrissonb0bd0702020-05-12 10:48:19 +0200261 "echo_detector_creator\.h": [
262 "+modules/audio_processing/include/audio_processing.h",
263 ],
264
Mirko Bonadeia418e672018-10-24 13:57:25 +0200265 "fake_frame_decryptor\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800266 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200267 ],
268
269 "fake_frame_encryptor\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800270 "+rtc_base/ref_counted_object.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200271 ],
272
Mirko Bonadeia418e672018-10-24 13:57:25 +0200273 "mock.*\.h": [
274 "+test/gmock.h",
275 ],
276
Florent Castelli0fc787b2021-07-16 17:36:52 +0200277 "mock_peerconnectioninterface\.h": [
278 "+rtc_base/ref_counted_object.h",
279 ],
280
Florent Castelli63cc46c2021-07-17 01:32:40 +0200281 "mock_video_track\.h": [
282 "+rtc_base/ref_counted_object.h",
283 ],
284
Mirko Bonadeia418e672018-10-24 13:57:25 +0200285 "simulated_network\.h": [
Mirko Bonadeia418e672018-10-24 13:57:25 +0200286 "+rtc_base/random.h",
287 "+rtc_base/thread_annotations.h",
288 ],
289
290 "test_dependency_factory\.h": [
291 "+rtc_base/thread_checker.h",
292 ],
293
Sebastian Janssonfc8279d2020-01-16 11:45:59 +0100294 "time_controller\.h": [
295 "+rtc_base/thread.h",
296 ],
297
Mirko Bonadeia418e672018-10-24 13:57:25 +0200298 "videocodec_test_fixture\.h": [
299 "+modules/video_coding/include/video_codec_interface.h"
300 ],
301
Mirko Bonadeia418e672018-10-24 13:57:25 +0200302 "video_encoder_config\.h": [
Steve Anton10542f22019-01-11 09:11:00 -0800303 "+rtc_base/ref_count.h",
Mirko Bonadeia418e672018-10-24 13:57:25 +0200304 ],
305
Artem Titovb586d822021-02-04 15:06:50 +0100306 "sequence_checker\.h": [
307 "+rtc_base/synchronization/sequence_checker_internal.h",
308 "+rtc_base/thread_annotations.h",
309 ],
310
Harald Alvestrand985310e2021-10-01 15:11:17 +0000311 "wrapping_async_dns_resolver\.h": [
312 "+rtc_base/async_resolver.h",
313 "+rtc_base/async_resolver_interface.h",
314 "+rtc_base/socket_address.h",
315 "+rtc_base/third_party/sigslot/sigslot.h",
316 "+rtc_base/thread_annotations.h",
317 ],
318
Mirko Bonadei90490372018-10-26 13:17:47 +0200319 # .cc files in api/ should not be restricted in what they can #include,
320 # so we re-add all the top-level directories here. (That's because .h
321 # files leak their #includes to whoever's #including them, but .cc files
322 # do not since no one #includes them.)
kwiberg087bd342017-02-10 08:15:44 -0800323 ".*\.cc": [
Mirko Bonadeia418e672018-10-24 13:57:25 +0200324 "+audio",
325 "+call",
326 "+common_audio",
327 "+common_video",
328 "+examples",
329 "+logging",
330 "+media",
331 "+modules",
332 "+p2p",
333 "+pc",
334 "+rtc_base",
335 "+rtc_tools",
336 "+sdk",
337 "+stats",
338 "+system_wrappers",
339 "+test",
340 "+tools",
341 "+tools_webrtc",
342 "+video",
343 "+third_party",
kwiberg1e4e8cb2017-01-31 01:48:08 -0800344 ],
kjellander@webrtc.org94a23f02016-03-17 12:05:36 +0100345}