1# Copyright 2019 The Pigweed Authors
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may not
4# use this file except in compliance with the License. You may obtain a copy of
5# the License at
6#
7#     https://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations under
13# the License.
14
15import("//build_overrides/pigweed.gni")
16
17import("$dir_pw_docgen/docs.gni")
18
19pw_doc_group("core_docs") {
20  inputs = [
21    "images/pw_env_setup_demo.gif",
22    "images/pw_status_test.png",
23    "images/pw_watch_build_demo.gif",
24    "images/pw_watch_on_device_demo.gif",
25    "images/pw_watch_test_demo.gif",
26    "images/stm32f429i-disc1_connected.jpg",
27  ]
28  sources = [
29    "embedded_cpp_guide.rst",
30    "faq.rst",
31    "getting_started.md",
32    "module_structure.rst",
33    "style_guide.rst",
34  ]
35}
36
37# Documentation for upstream Pigweed targets.
38group("target_docs") {
39  deps = [
40    "$dir_pigweed/targets/arduino:target_docs",
41    "$dir_pigweed/targets/docs:target_docs",
42    "$dir_pigweed/targets/host:target_docs",
43    "$dir_pigweed/targets/lm3s6965evb-qemu:target_docs",
44    "$dir_pigweed/targets/stm32f429i-disc1:target_docs",
45  ]
46}
47
48group("module_docs") {
49  deps = [
50    "$dir_docker:docs",
51    "$dir_pw_allocator:docs",
52    "$dir_pw_arduino_build:docs",
53    "$dir_pw_assert:docs",
54    "$dir_pw_assert_basic:docs",
55    "$dir_pw_assert_log:docs",
56    "$dir_pw_base64:docs",
57    "$dir_pw_bloat:docs",
58    "$dir_pw_blob_store:docs",
59    "$dir_pw_boot_armv7m:docs",
60    "$dir_pw_build:docs",
61    "$dir_pw_bytes:docs",
62    "$dir_pw_checksum:docs",
63    "$dir_pw_chrono:docs",
64    "$dir_pw_chrono_embos:docs",
65    "$dir_pw_chrono_freertos:docs",
66    "$dir_pw_chrono_stl:docs",
67    "$dir_pw_chrono_threadx:docs",
68    "$dir_pw_cli:docs",
69    "$dir_pw_containers:docs",
70    "$dir_pw_cpu_exception:docs",
71    "$dir_pw_cpu_exception_cortex_m:docs",
72    "$dir_pw_docgen:docs",
73    "$dir_pw_doctor:docs",
74    "$dir_pw_env_setup:docs",
75    "$dir_pw_fuzzer:docs",
76    "$dir_pw_hdlc:docs",
77    "$dir_pw_hex_dump:docs",
78    "$dir_pw_interrupt:docs",
79    "$dir_pw_interrupt_cortex_m:docs",
80    "$dir_pw_kvs:docs",
81    "$dir_pw_log:docs",
82    "$dir_pw_log_basic:docs",
83    "$dir_pw_log_multisink:docs",
84    "$dir_pw_log_null:docs",
85    "$dir_pw_log_rpc:docs",
86    "$dir_pw_log_sink:docs",
87    "$dir_pw_log_tokenized:docs",
88    "$dir_pw_metric:docs",
89    "$dir_pw_minimal_cpp_stdlib:docs",
90    "$dir_pw_module:docs",
91    "$dir_pw_multisink:docs",
92    "$dir_pw_package:docs",
93    "$dir_pw_persistent_ram:docs",
94    "$dir_pw_polyfill:docs",
95    "$dir_pw_preprocessor:docs",
96    "$dir_pw_presubmit:docs",
97    "$dir_pw_protobuf:docs",
98    "$dir_pw_protobuf_compiler:docs",
99    "$dir_pw_random:docs",
100    "$dir_pw_result:docs",
101    "$dir_pw_ring_buffer:docs",
102    "$dir_pw_router:docs",
103    "$dir_pw_rpc:docs",
104    "$dir_pw_span:docs",
105    "$dir_pw_status:docs",
106    "$dir_pw_stream:docs",
107    "$dir_pw_string:docs",
108    "$dir_pw_sync:docs",
109    "$dir_pw_sync_baremetal:docs",
110    "$dir_pw_sync_embos:docs",
111    "$dir_pw_sync_freertos:docs",
112    "$dir_pw_sync_stl:docs",
113    "$dir_pw_sync_threadx:docs",
114    "$dir_pw_sys_io:docs",
115    "$dir_pw_sys_io_arduino:docs",
116    "$dir_pw_sys_io_baremetal_stm32f429:docs",
117    "$dir_pw_sys_io_stdio:docs",
118    "$dir_pw_target_runner:docs",
119    "$dir_pw_thread:docs",
120    "$dir_pw_thread_embos:docs",
121    "$dir_pw_thread_freertos:docs",
122    "$dir_pw_thread_stl:docs",
123    "$dir_pw_thread_threadx:docs",
124    "$dir_pw_tokenizer:docs",
125    "$dir_pw_toolchain:docs",
126    "$dir_pw_trace:docs",
127    "$dir_pw_trace_tokenized:docs",
128    "$dir_pw_unit_test:docs",
129    "$dir_pw_varint:docs",
130    "$dir_pw_watch:docs",
131    "$dir_pw_web_ui:docs",
132  ]
133}
134
135pw_doc_gen("docs") {
136  conf = "conf.py"
137  sources = [
138    "../CODE_OF_CONDUCT.md",
139    "../CONTRIBUTING.md",
140    "../README.md",
141    "build_system.rst",
142    "index.rst",
143    "module_guides.rst",
144    "python_build.rst",
145    "targets.rst",
146  ]
147  output_directory = target_gen_dir
148  deps = [
149    ":core_docs",
150    ":module_docs",
151    ":target_docs",
152    "$dir_pw_env_setup:python.install",
153  ]
154}
155