OLD | NEW |
---|---|
1 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 # for details. All rights reserved. Use of this source code is governed by a | 2 # for details. All rights reserved. Use of this source code is governed by a |
3 # BSD-style license that can be found in the LICENSE file. | 3 # BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 { | 5 { |
6 'variables' : { | 6 'variables' : { |
7 'script_suffix%': '', | 7 'script_suffix%': '', |
8 }, | 8 }, |
9 'conditions' : [ | 9 'conditions' : [ |
10 ['OS=="win"', { | 10 ['OS=="win"', { |
11 'variables' : { | 11 'variables' : { |
12 'script_suffix': '.bat', | 12 'script_suffix': '.bat', |
13 }, | 13 }, |
14 }], | 14 }], |
15 ], | 15 ], |
16 'targets': [ | 16 'targets': [ |
17 { | 17 { |
18 'target_name': 'api_docs', | 18 'target_name': 'docgen', |
19 'type': 'none', | 19 'type': 'none', |
20 'dependencies': [ | 20 'dependencies': [ |
21 '../../utils/compiler/compiler.gyp:dart2js', | 21 '../../utils/compiler/compiler.gyp:dart2js', |
22 '../../runtime/dart-runtime.gyp:dart', | 22 '../../runtime/dart-runtime.gyp:dart', |
23 '../../pkg/pkg.gyp:pkg_packages', | 23 '../../pkg/pkg.gyp:pkg_packages', |
kustermann
2013/11/19 16:40:37
I'd still depend on the old apidocs target here.
Alan Knight
2013/11/19 19:14:47
Done.
| |
24 ], | 24 ], |
25 'includes': [ | 25 'includes': [ |
26 '../../sdk/lib/core/corelib_sources.gypi', | 26 '../../sdk/lib/core/corelib_sources.gypi', |
27 ], | 27 ], |
28 'actions': [ | 28 'actions': [ |
29 { | 29 { |
30 'action_name': 'run_apidoc', | 30 'action_name': 'run_docgen', |
31 # The 'inputs' list records the files whose timestamps are | 31 # The 'inputs' list records the files whose timestamps are |
32 # compared to the files listed in 'outputs'. If a file | 32 # compared to the files listed in 'outputs'. If a file |
33 # 'outputs' doesn't exist or if a file in 'inputs' is newer | 33 # 'outputs' doesn't exist or if a file in 'inputs' is newer |
34 # than a file in 'outputs', this action is executed. Notice | 34 # than a file in 'outputs', this action is executed. Notice |
35 # that the dependencies listed above has nothing to do with | 35 # that the dependencies listed above has nothing to do with |
36 # when this action is executed. You must list a file in | 36 # when this action is executed. You must list a file in |
37 # 'inputs' to make sure that it exists before the action is | 37 # 'inputs' to make sure that it exists before the action is |
38 # executed, or to make sure this action is re-run. | 38 # executed, or to make sure this action is re-run. |
39 # | 39 # |
40 # We want to build the platform documentation whenever | 40 # We want to build the platform documentation whenever |
41 # dartdoc, apidoc, or its dependency changes. This prevents | 41 # dartdoc, apidoc, or its dependency changes. This prevents |
42 # people from accidentally breaking apidoc when making | 42 # people from accidentally breaking apidoc when making |
43 # changes to the platform libraries and or when modifying | 43 # changes to the platform libraries and or when modifying |
44 # dart2js or the VM. | 44 # dart2js or the VM. |
45 # | 45 # |
46 # In addition, we want to make sure that the platform | 46 # In addition, we want to make sure that the platform |
47 # documentation is regenerated when the platform sources | 47 # documentation is regenerated when the platform sources |
48 # changes. | 48 # changes. |
49 # | 49 # |
50 # So we want this action to be re-run when a dart file | 50 # So we want this action to be re-run when a dart file |
51 # changes in this directory, or in the SDK library (we may | 51 # changes in this directory, or in the SDK library (we may |
52 # no longer need to list the files in ../../runtime/lib and | 52 # no longer need to list the files in ../../runtime/lib and |
53 # ../../runtime/bin, as most of them has moved to | 53 # ../../runtime/bin, as most of them has moved to |
54 # ../../sdk/lib). | 54 # ../../sdk/lib). |
55 # | 55 # |
56 # In addition, we want to make sure the documentation is | |
57 # regenerated when a resource file (CSS, PNG, etc) is | |
58 # updated. This is because these files are also copied to | |
59 # the output directory. | |
60 'inputs': [ | 56 'inputs': [ |
61 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)', | 57 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)', |
62 '<(SHARED_INTERMEDIATE_DIR)/utils_wrapper.dart.snapshot', | 58 '<(SHARED_INTERMEDIATE_DIR)/utils_wrapper.dart.snapshot', |
63 '<!@(["python", "../../tools/list_files.py", "\\.(css|ico|js|json|pn g|sh|txt|yaml|py)$", ".", "../../sdk/lib/_internal/dartdoc"])', | 59 '<!@(["python", "../../tools/list_files.py", "\\.(css|ico|js|json|pn g|sh|txt|yaml|py)$", ".", "../../sdk/lib/_internal/dartdoc"])', |
64 '<!@(["python", "../../tools/list_files.py", "\\.dart$", ".", "../.. /sdk/lib", "../../runtime/lib", "../../runtime/bin"])', | 60 '<!@(["python", "../../tools/list_files.py", "\\.dart$", ".", "../.. /sdk/lib", "../../runtime/lib", "../../runtime/bin"])', |
65 '../../sdk/bin/dart', | 61 '../../sdk/bin/dart', |
66 '../../sdk/bin/dart.bat', | 62 '../../sdk/bin/dart.bat', |
67 '../../sdk/bin/dart2js', | 63 '../../sdk/bin/dart2js', |
68 '../../sdk/bin/dart2js.bat', | 64 '../../sdk/bin/dart2js.bat', |
69 '../../tools/only_in_release_mode.py', | 65 '../../tools/only_in_release_mode.py', |
66 '<(PRODUCT_DIR)/api_docs/index.html', | |
kustermann
2013/11/19 16:40:37
Add a short comment, that this is used for ensurin
Alan Knight
2013/11/19 19:14:47
Done.
| |
70 ], | 67 ], |
71 'outputs': [ | 68 'outputs': [ |
72 '<(PRODUCT_DIR)/api_docs/index.html', | 69 '<(PRODUCT_DIR)/api_docs/docgen/index.json', |
73 '<(PRODUCT_DIR)/api_docs/client-static.js', | |
74 ], | 70 ], |
75 'action': [ | 71 'action': [ |
76 'python', | 72 'python', |
77 '../../tools/only_in_release_mode.py', | 73 '../../tools/only_in_release_mode.py', |
78 '<@(_outputs)', | 74 '<@(_outputs)', |
79 '--', | 75 '--', |
80 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)', | 76 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)', |
77 '--old_gen_heap_size=1024', | |
81 '--package-root=<(PRODUCT_DIR)/packages/', | 78 '--package-root=<(PRODUCT_DIR)/packages/', |
82 'apidoc.dart', | 79 '../../pkg/docgen/bin/docgen.dart', |
83 '--out=<(PRODUCT_DIR)/api_docs', | 80 '--out=<(PRODUCT_DIR)/api_docs/docgen', |
84 '--version=<!@(["python", "../../tools/print_version.py"])', | 81 '--json', |
82 '--include-sdk', | |
85 '--package-root=<(PRODUCT_DIR)/packages', | 83 '--package-root=<(PRODUCT_DIR)/packages', |
86 '--mode=static', | |
87 '--exclude-lib=analyzer', | |
88 '--exclude-lib=async_helper', | 84 '--exclude-lib=async_helper', |
89 '--exclude-lib=barback', | 85 '--exclude-lib=expect', |
90 '--exclude-lib=browser', | |
91 '--exclude-lib=dartdoc', | |
92 '--exclude-lib=docgen', | 86 '--exclude-lib=docgen', |
kustermann
2013/11/19 16:40:37
I'm wondering why you removed so many '--exclude-l
Alan Knight
2013/11/19 19:14:47
From what I could tell there were two rationales f
| |
93 '--exclude-lib=expect', | 87 '../../pkg', |
94 '--exclude-lib=http', | |
95 '--exclude-lib=oauth2', | |
96 '--exclude-lib=scheduled_test', | |
97 '--exclude-lib=stack_trace', | |
98 '--exclude-lib=watcher', | |
99 '--exclude-lib=webdriver', | |
100 '--exclude-lib=yaml', | |
101 '--include-lib=matcher', | |
102 '--extra-lib=pkg/unittest/lib/mock.dart', | |
103 ], | 88 ], |
104 'message': 'Running apidoc: <(_action)', | 89 'message': 'Running docgen: <(_action)', |
105 }, | 90 }, |
106 ], | 91 ], |
107 } | 92 } |
108 ], | 93 ], |
109 } | 94 } |
OLD | NEW |