OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "tools/gn/variables.h" | 5 #include "tools/gn/variables.h" |
6 | 6 |
7 namespace variables { | 7 namespace variables { |
8 | 8 |
9 // Built-in variables ---------------------------------------------------------- | 9 // Built-in variables ---------------------------------------------------------- |
10 | 10 |
(...skipping 1534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1545 const char kPublic[] = "public"; | 1545 const char kPublic[] = "public"; |
1546 const char kPublic_HelpShort[] = | 1546 const char kPublic_HelpShort[] = |
1547 "public: [file list] Declare public header files for a target."; | 1547 "public: [file list] Declare public header files for a target."; |
1548 const char kPublic_Help[] = | 1548 const char kPublic_Help[] = |
1549 R"(public: Declare public header files for a target. | 1549 R"(public: Declare public header files for a target. |
1550 | 1550 |
1551 A list of files that other targets can include. These permissions are checked | 1551 A list of files that other targets can include. These permissions are checked |
1552 via the "check" command (see "gn help check"). | 1552 via the "check" command (see "gn help check"). |
1553 | 1553 |
1554 If no public files are declared, other targets (assuming they have visibility | 1554 If no public files are declared, other targets (assuming they have visibility |
1555 to depend on this target can include any file in the sources list. If this | 1555 to depend on this target) can include any file in the sources list. If this |
1556 variable is defined on a target, dependent targets may only include files on | 1556 variable is defined on a target, dependent targets may only include files on |
1557 this whitelist. | 1557 this whitelist. |
1558 | 1558 |
1559 Header file permissions are also subject to visibility. A target must be | 1559 Header file permissions are also subject to visibility. A target must be |
1560 visible to another target to include any files from it at all and the public | 1560 visible to another target to include any files from it at all and the public |
1561 headers indicate which subset of those files are permitted. See "gn help | 1561 headers indicate which subset of those files are permitted. See "gn help |
1562 visibility" for more. | 1562 visibility" for more. |
1563 | 1563 |
1564 Public files are inherited through the dependency tree. So if there is a | 1564 Public files are inherited through the dependency tree. So if there is a |
1565 dependency A -> B -> C, then A can include C's public headers. However, the | 1565 dependency A -> B -> C, then A can include C's public headers. However, the |
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1934 INSERT_VARIABLE(Testonly) | 1934 INSERT_VARIABLE(Testonly) |
1935 INSERT_VARIABLE(Visibility) | 1935 INSERT_VARIABLE(Visibility) |
1936 INSERT_VARIABLE(WriteRuntimeDeps) | 1936 INSERT_VARIABLE(WriteRuntimeDeps) |
1937 } | 1937 } |
1938 return info_map; | 1938 return info_map; |
1939 } | 1939 } |
1940 | 1940 |
1941 #undef INSERT_VARIABLE | 1941 #undef INSERT_VARIABLE |
1942 | 1942 |
1943 } // namespace variables | 1943 } // namespace variables |
OLD | NEW |