summaryrefslogtreecommitdiff
path: root/site_scons
diff options
context:
space:
mode:
authorMark Benvenuto <mark.benvenuto@mongodb.com>2017-05-12 10:34:39 -0400
committerMark Benvenuto <mark.benvenuto@mongodb.com>2017-05-12 10:34:39 -0400
commit107b0bdf954bed554cf74a69a3fec268ac00886b (patch)
tree5d104e40d1c605b88a86d0ce77498cd372ed4414 /site_scons
parent164d4720b9d81ca5f9deea702b66438a6fa8072c (diff)
downloadmongo-107b0bdf954bed554cf74a69a3fec268ac00886b.tar.gz
SERVER-29081 Add toBSON to IDL generated classes
Diffstat (limited to 'site_scons')
-rwxr-xr-xsite_scons/site_tools/idl_tool.py18
1 files changed, 11 insertions, 7 deletions
diff --git a/site_scons/site_tools/idl_tool.py b/site_scons/site_tools/idl_tool.py
index 6584c797773..9606ce0c405 100755
--- a/site_scons/site_tools/idl_tool.py
+++ b/site_scons/site_tools/idl_tool.py
@@ -37,13 +37,6 @@ def idlc_emitter(target, source, env):
IDLCAction = SCons.Action.Action('$IDLCCOM', '$IDLCCOMSTR')
-# TODO: create a scanner for imports when imports are implemented
-IDLCBuilder = SCons.Builder.Builder(
- action=IDLCAction,
- emitter=idlc_emitter,
- srcsuffx=".idl",
- suffix=".cpp"
- )
def idl_scanner(node, env, path):
# Use the import scanner mode of the IDL compiler to file imported files
@@ -58,8 +51,19 @@ def idl_scanner(node, env, path):
return nodes_deps_list
+
idl_scanner = SCons.Scanner.Scanner(function=idl_scanner, skeys=['.idl'])
+# TODO: create a scanner for imports when imports are implemented
+IDLCBuilder = SCons.Builder.Builder(
+ action=IDLCAction,
+ emitter=idlc_emitter,
+ srcsuffx=".idl",
+ suffix=".cpp",
+ source_scanner = idl_scanner
+ )
+
+
def generate(env):
bld = IDLCBuilder