summaryrefslogtreecommitdiffstats
path: root/ppapi/generators
diff options
context:
space:
mode:
authorjvoung@google.com <jvoung@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-01 01:58:17 +0000
committerjvoung@google.com <jvoung@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-01 01:58:17 +0000
commit2069a3c0375966505dde9962977492b208a41afb (patch)
tree2efe3d063d3c835e994d429d267c918803ba1257 /ppapi/generators
parent08f1c5ed2fba3b6a60fb50135c777e4f8c9d2bed (diff)
downloadchromium_src-2069a3c0375966505dde9962977492b208a41afb.zip
chromium_src-2069a3c0375966505dde9962977492b208a41afb.tar.gz
chromium_src-2069a3c0375966505dde9962977492b208a41afb.tar.bz2
Hide private IDL files from generator behind "--include_private" flag
until all the private IDL files can generate the correct .h files. BUG= none TEST= ./generator.py && ./generator.py --wnone --cgen --range=start,end --include_private --out private/ppb_flash_fullscreen.idl R=noelallen@chromium.org,piman@chromium.org Review URL: http://codereview.chromium.org/8760016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@112373 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi/generators')
-rw-r--r--ppapi/generators/idl_parser.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/ppapi/generators/idl_parser.py b/ppapi/generators/idl_parser.py
index cae12f3..0b309e2 100644
--- a/ppapi/generators/idl_parser.py
+++ b/ppapi/generators/idl_parser.py
@@ -45,6 +45,7 @@ Option('parse_debug', 'Debug parse reduction steps.')
Option('token_debug', 'Debug token generation.')
Option('dump_tree', 'Dump the tree.')
Option('srcroot', 'Working directory.', default=os.path.join('..', 'api'))
+Option('include_private', 'Include private IDL directory in default API paths.')
#
# ERROR_REMAP
@@ -1001,7 +1002,7 @@ def TestNamespaceFiles(filter):
InfoOut.Log("Passed namespace test.")
return errs
-default_dirs = ['.', 'trusted', 'dev', 'private']
+default_dirs = ['.', 'trusted', 'dev']
def ParseFiles(filenames):
parser = IDLParser()
filenodes = []
@@ -1009,7 +1010,10 @@ def ParseFiles(filenames):
if not filenames:
filenames = []
srcroot = GetOption('srcroot')
- for dirname in default_dirs:
+ dirs = default_dirs
+ if GetOption('include_private'):
+ dirs += ['private']
+ for dirname in dirs:
srcdir = os.path.join(srcroot, dirname, '*.idl')
srcdir = os.path.normpath(srcdir)
filenames += sorted(glob.glob(srcdir))
@@ -1047,4 +1051,3 @@ def Main(args):
if __name__ == '__main__':
sys.exit(Main(sys.argv[1:]))
-