aboutsummaryrefslogtreecommitdiffhomepage
path: root/templates
diff options
context:
space:
mode:
authorGravatar murgatroid99 <mlumish@google.com>2015-11-05 10:35:04 -0800
committerGravatar murgatroid99 <mlumish@google.com>2015-11-05 10:35:04 -0800
commit879bc4f24e524e53477e6954d254a79eeb92d267 (patch)
tree0f2358cf6f3c4c3034f87717d544da4d5d1929b2 /templates
parentd67b35635eca097abc5a3543a87754ddd9173a3d (diff)
Generate all file lists and build target lists in binding.gyp from build.yaml
Diffstat (limited to 'templates')
-rw-r--r--templates/binding.gyp.template25
1 files changed, 11 insertions, 14 deletions
diff --git a/templates/binding.gyp.template b/templates/binding.gyp.template
index 52070cf6e9..be80750eb7 100644
--- a/templates/binding.gyp.template
+++ b/templates/binding.gyp.template
@@ -89,8 +89,9 @@
]
},
'targets': [
+ % for module in node_modules:
% for lib in libs:
- % if lib.name == 'gpr' or lib.name == 'grpc':
+ % if lib.name in module.transitive_deps:
{
'target_name': '${lib.name}',
'product_prefix': 'lib',
@@ -142,22 +143,18 @@
}
}]
],
- "target_name": "grpc_node",
+ "target_name": "${module.name}",
"sources": [
- "src/node/ext/byte_buffer.cc",
- "src/node/ext/call.cc",
- "src/node/ext/call_credentials.cc",
- "src/node/ext/channel.cc",
- "src/node/ext/channel_credentials.cc",
- "src/node/ext/completion_queue_async_worker.cc",
- "src/node/ext/node_grpc.cc",
- "src/node/ext/server.cc",
- "src/node/ext/server_credentials.cc",
- "src/node/ext/timeval.cc"
+ % for source in module.src:
+ "${source}",
+ % endfor
],
"dependencies": [
- "grpc"
+ % for dep in getattr(module, 'deps', []):
+ "${dep}",
+ % endfor
]
- }
+ },
+ % endfor
]
}