68141f6193e762715bd22becb65679233674a05c
[kai/samba-autobuild/.git] / source4 / librpc / wscript_build
1 #!/usr/bin/env python
2
3 bld.RECURSE('../../librpc/idl')
4 bld.RECURSE('../../librpc/tools')
5 bld.RECURSE('idl')
6
7
8 bld.SAMBA_SUBSYSTEM('NDR_WINSTATION',
9         source='gen_ndr/ndr_winstation.c',
10         public_deps='ndr'
11         )
12
13
14 bld.SAMBA_SUBSYSTEM('NDR_IRPC',
15         source='gen_ndr/ndr_irpc.c',
16         public_deps='ndr NDR_SECURITY NDR_NBT'
17         )
18
19
20 bld.SAMBA_SUBSYSTEM('NDR_SASL_HELPERS',
21         source='gen_ndr/ndr_sasl_helpers.c',
22         public_deps='ndr'
23         )
24
25
26
27 bld.SAMBA_SUBSYSTEM('NDR_NFS4ACL',
28         source='gen_ndr/ndr_nfs4acl.c',
29         public_deps='ndr NDR_SECURITY'
30         )
31
32
33
34 bld.SAMBA_SUBSYSTEM('NDR_WINSIF',
35         source='gen_ndr/ndr_winsif.c',
36         public_deps='ndr'
37         )
38
39
40 bld.SAMBA_SUBSYSTEM('NDR_OPENDB',
41         source='gen_ndr/ndr_opendb.c',
42         public_deps='ndr'
43         )
44
45
46 bld.SAMBA_SUBSYSTEM('NDR_NTP_SIGND',
47         source='gen_ndr/ndr_ntp_signd.c',
48         public_deps='ndr'
49         )
50
51
52 bld.SAMBA_SUBSYSTEM('NDR_WINSREPL',
53         source='gen_ndr/ndr_winsrepl.c',
54         public_deps='ndr NDR_NBT'
55         )
56
57
58 bld.SAMBA_SUBSYSTEM('NDR_WINBIND',
59         source='gen_ndr/ndr_winbind.c',
60         public_deps='NDR_IDMAP ndr ndr-standard'
61         )
62
63 # create a grouping library to consolidate our samba4 specific NDR code
64 bld.SAMBA_LIBRARY('ndr-samba4',
65         source=[],
66         deps='NDR_WINBIND NDR_IRPC NDR_NFS4ACL NDR_OPENDB ndr-table',
67         private_library=True,
68         grouping_library=True
69         )
70
71 # a grouping library for RPC_NDR subsystems that may be used by more than one target
72 bld.SAMBA_LIBRARY('dcerpc-samba4',
73         source=[],
74         deps='RPC_NDR_WINBIND',
75         private_library=True,
76         grouping_library=True
77         )
78
79
80 bld.SAMBA_PIDL_TABLES('GEN_NDR_TABLES', 'gen_ndr/tables.c')
81
82 bld.SAMBA_SUBSYSTEM('ndr-table',
83         source='../../librpc/ndr/ndr_table.c gen_ndr/tables.c',
84         public_deps='''ndr-standard NDR_AUDIOSRV NDR_DSBACKUP NDR_EFS
85         NDR_DRSUAPI NDR_POLICYAGENT NDR_UNIXINFO NDR_SPOOLSS NDR_EPMAPPER
86         NDR_DBGIDL NDR_DSSETUP NDR_MSGSVC NDR_WINSIF NDR_MGMT
87         NDR_OXIDRESOLVER NDR_REMACT NDR_WZCSVC
88         NDR_BROWSER NDR_W32TIME NDR_SCERPC NDR_TRKWKS NDR_KEYSVC ndr-krb5pac
89         NDR_XATTR NDR_SCHANNEL NDR_ROT NDR_DRSBLOBS NDR_NBT NDR_WINSREPL
90         NDR_SECURITY NDR_DNSSERVER NDR_WINSTATION NDR_IRPC NDR_OPENDB
91         NDR_SASL_HELPERS NDR_NOTIFY NDR_WINBIND NDR_FRSRPC NDR_FRSAPI
92         NDR_FRSTRANS NDR_NFS4ACL NDR_NTP_SIGND NDR_DCOM NDR_WMI
93         NDR_NAMED_PIPE_AUTH NDR_NTLMSSP NDR_DFSBLOBS NDR_DNSP
94         NDR_NTPRINTING NDR_DNS NDR_BACKUPKEY NDR_PREG NDR_WBINT''',
95         depends_on='GEN_NDR_TABLES'
96         )
97
98
99 bld.SAMBA_SUBSYSTEM('RPC_NDR_IRPC',
100         source='gen_ndr/ndr_irpc_c.c',
101         public_deps='dcerpc NDR_IRPC'
102         )
103
104 bld.SAMBA_SUBSYSTEM('RPC_NDR_WINBIND',
105         source='gen_ndr/ndr_winbind_c.c',
106         public_deps='dcerpc NDR_WINBIND'
107         )
108
109
110 bld.SAMBA_LIBRARY('dcerpc-samr',
111         source='',
112         pc_files='dcerpc_samr.pc',
113         vnum='0.0.1',
114         public_deps='dcerpc ndr-standard RPC_NDR_SAMR',
115         public_headers='../../librpc/gen_ndr/ndr_samr_c.h',
116         header_path='gen_ndr'
117         )
118
119
120 bld.SAMBA_LIBRARY('dcerpc-atsvc',
121         source='',
122         pc_files='dcerpc_atsvc.pc',
123         vnum='0.0.1',
124         public_deps='dcerpc ndr-standard RPC_NDR_ATSVC',
125         public_headers='../../librpc/gen_ndr/ndr_atsvc_c.h',
126         header_path='gen_ndr'
127         )
128
129
130 bld.SAMBA_SUBSYSTEM('RPC_NDR_WINSIF',
131         source='gen_ndr/ndr_winsif_c.c',
132         public_deps='dcerpc NDR_WINSIF'
133         )
134
135
136 bld.SAMBA_LIBRARY('dcerpc',
137         source='''rpc/dcerpc.c rpc/dcerpc_auth.c rpc/dcerpc_schannel.c
138         rpc/dcerpc_util.c rpc/dcerpc_smb.c rpc/dcerpc_smb2.c rpc/dcerpc_sock.c
139         rpc/dcerpc_connect.c rpc/dcerpc_secondary.c''',
140         pc_files='dcerpc.pc',
141         deps='samba_socket LIBCLI_RESOLVE LIBCLI_SMB LIBCLI_SMB2 ndr NDR_DCERPC RPC_NDR_EPMAPPER NDR_SCHANNEL RPC_NDR_NETLOGON RPC_NDR_MGMT gensec LIBCLI_AUTH cli_raw LP_RESOLVE UTIL_TEVENT rpccommon',
142         autoproto='rpc/dcerpc_proto.h',
143         public_deps='credentials tevent talloc',
144         public_headers='''rpc/dcerpc.h ../../librpc/gen_ndr/mgmt.h
145         ../../librpc/gen_ndr/ndr_mgmt.h ../../librpc/gen_ndr/ndr_mgmt_c.h
146         ../../librpc/gen_ndr/epmapper.h ../../librpc/gen_ndr/ndr_epmapper.h
147         ../../librpc/gen_ndr/ndr_epmapper_c.h ../../librpc/rpc/rpc_common.h''',
148         # It's very important to keep this form of construction
149         # it force the sambawaf extension to put everything that match the first element
150         # (*gen_ndr*) into the dir named by the second element (gen_ndr).
151         # If we just put header_path = 'gen_ndr' then all the public_headers will go
152         # in 'gen_ndr' and for dcerpc.h (at least) it will cause a problem as
153         # we have already a dcerpc.h installed by librpc/wscript_build
154         # and one will overright the other which is not what we expect.
155         header_path=[ ('*gen_ndr*', 'gen_ndr') ],
156         vnum='0.0.1'
157         )
158
159 bld.SAMBA_SUBSYSTEM('pyrpc_util',
160         source='rpc/pyrpc_util.c',
161         public_deps='pytalloc-util pyparam_util dcerpc',
162         pyext=True,
163         )
164
165
166 bld.SAMBA_PYTHON('python_dcerpc',
167         source='rpc/pyrpc.c',
168         public_deps='LIBCLI_SMB samba-util samba-hostconfig dcerpc-samr RPC_NDR_LSA DYNCONFIG pyrpc_util',
169         realname='samba/dcerpc/base.so'
170         )
171
172 bld.SAMBA_PYTHON('python_srvsvc',
173     source='../../librpc/gen_ndr/py_srvsvc.c',
174     deps='RPC_NDR_SRVSVC pytalloc-util pyrpc_util',
175     realname='samba/dcerpc/srvsvc.so'
176     )
177
178 bld.SAMBA_PYTHON('python_echo',
179         source='../../librpc/gen_ndr/py_echo.c',
180         deps='RPC_NDR_ECHO pytalloc-util pyrpc_util',
181         realname='samba/dcerpc/echo.so'
182         )
183
184 bld.SAMBA_PYTHON('python_auth',
185         source='../../librpc/gen_ndr/py_auth.c',
186         deps='NDR_AUTH pytalloc-util pyrpc_util',
187         realname='samba/dcerpc/auth.so'
188         )
189
190 bld.SAMBA_PYTHON('python_krb5pac',
191         source='../../librpc/gen_ndr/py_krb5pac.c',
192         deps='ndr-krb5pac pytalloc-util pyrpc_util',
193         realname='samba/dcerpc/krb5pac.so'
194         )
195
196 bld.SAMBA_PYTHON('python_winreg',
197         source='../../librpc/gen_ndr/py_winreg.c',
198         deps='RPC_NDR_WINREG pytalloc-util pyrpc_util',
199         realname='samba/dcerpc/winreg.so'
200         )
201
202
203 bld.SAMBA_PYTHON('python_dcerpc_misc',
204         source='../../librpc/gen_ndr/py_misc.c',
205         deps='pytalloc-util pyrpc_util ndr-krb5pac',
206         realname='samba/dcerpc/misc.so'
207         )
208
209
210 bld.SAMBA_PYTHON('python_initshutdown',
211         source='../../librpc/gen_ndr/py_initshutdown.c',
212         deps='RPC_NDR_INITSHUTDOWN pytalloc-util pyrpc_util',
213         realname='samba/dcerpc/initshutdown.so'
214         )
215
216
217 bld.SAMBA_PYTHON('python_epmapper',
218         source='../../librpc/gen_ndr/py_epmapper.c',
219         deps='dcerpc pytalloc-util pyrpc_util',
220         realname='samba/dcerpc/epmapper.so'
221         )
222
223
224 bld.SAMBA_PYTHON('python_mgmt',
225         source='../../librpc/gen_ndr/py_mgmt.c',
226         deps='pytalloc-util dcerpc pyrpc_util',
227         realname='samba/dcerpc/mgmt.so'
228         )
229
230
231 bld.SAMBA_PYTHON('python_atsvc',
232         source='../../librpc/gen_ndr/py_atsvc.c',
233         deps='dcerpc-atsvc pytalloc-util pyrpc_util',
234         realname='samba/dcerpc/atsvc.so'
235         )
236
237
238 bld.SAMBA_PYTHON('python_dcerpc_nbt',
239         source='../../librpc/gen_ndr/py_nbt.c',
240         deps='NDR_NBT RPC_NDR_NBT pytalloc-util pyrpc_util',
241         realname='samba/dcerpc/nbt.so'
242         )
243
244
245 bld.SAMBA_PYTHON('python_samr',
246         source='../../librpc/gen_ndr/py_samr.c',
247         deps='dcerpc-samr pytalloc-util pyrpc_util',
248         realname='samba/dcerpc/samr.so'
249         )
250
251
252 bld.SAMBA_PYTHON('python_svcctl',
253         source='../../librpc/gen_ndr/py_svcctl.c',
254         deps='RPC_NDR_SVCCTL pytalloc-util pyrpc_util',
255         realname='samba/dcerpc/svcctl.so'
256         )
257
258
259 bld.SAMBA_PYTHON('python_lsa',
260         source='../../librpc/gen_ndr/py_lsa.c',
261         deps='RPC_NDR_LSA pytalloc-util pyrpc_util',
262         realname='samba/dcerpc/lsa.so'
263         )
264
265
266 bld.SAMBA_PYTHON('python_wkssvc',
267         source='../../librpc/gen_ndr/py_wkssvc.c',
268         deps='RPC_NDR_WKSSVC pytalloc-util pyrpc_util',
269         realname='samba/dcerpc/wkssvc.so'
270         )
271
272
273 bld.SAMBA_PYTHON('python_dfs',
274         source='../../librpc/gen_ndr/py_dfs.c',
275         deps='RPC_NDR_DFS pytalloc-util pyrpc_util',
276         realname='samba/dcerpc/dfs.so'
277         )
278
279
280 bld.SAMBA_PYTHON('python_unixinfo',
281         source='../../librpc/gen_ndr/py_unixinfo.c',
282         deps='RPC_NDR_UNIXINFO pytalloc-util pyrpc_util',
283         realname='samba/dcerpc/unixinfo.so'
284         )
285
286
287 bld.SAMBA_PYTHON('python_irpc',
288         source='gen_ndr/py_irpc.c',
289         deps='RPC_NDR_IRPC pytalloc-util pyrpc_util',
290         realname='samba/dcerpc/irpc.so'
291         )
292
293 bld.SAMBA_PYTHON('python_winbind',
294         source='gen_ndr/py_winbind.c',
295         deps='RPC_NDR_WINBIND pytalloc-util pyrpc_util python_netlogon',
296         realname='samba/dcerpc/winbind.so'
297         )
298
299 bld.SAMBA_PYTHON('python_idmap',
300         source='../../librpc/gen_ndr/py_idmap.c',
301         deps='NDR_IDMAP pytalloc-util pyrpc_util',
302         realname='samba/dcerpc/idmap.so'
303         )
304
305
306 bld.SAMBA_PYTHON('python_drsuapi',
307         source='../../librpc/gen_ndr/py_drsuapi.c',
308         deps='RPC_NDR_DRSUAPI pytalloc-util pyrpc_util',
309         realname='samba/dcerpc/drsuapi.so'
310         )
311
312 bld.SAMBA_PYTHON('python_dcerpc_security',
313         source='../../librpc/gen_ndr/py_security.c',
314         deps='pytalloc-util pyrpc_util NDR_SECURITY',
315         realname='samba/dcerpc/security.so'
316         )
317
318 bld.SAMBA_PYTHON('python_dcerpc_drsblobs',
319         source='../../librpc/gen_ndr/py_drsblobs.c',
320         deps='pytalloc-util pyrpc_util NDR_SECURITY RPC_NDR_DRSBLOBS',
321         realname='samba/dcerpc/drsblobs.so'
322         )
323
324 bld.SAMBA_PYTHON('python_dcerpc_dnsp',
325         source='../../librpc/gen_ndr/py_dnsp.c',
326         deps='pytalloc-util pyrpc_util NDR_SECURITY RPC_NDR_DNSP',
327         realname='samba/dcerpc/dnsp.so'
328         )
329
330
331 bld.SAMBA_PYTHON('python_dcerpc_xattr',
332         source='../../librpc/gen_ndr/py_xattr.c',
333         deps='pytalloc-util pyrpc_util RPC_NDR_XATTR',
334         realname='samba/dcerpc/xattr.so'
335         )
336
337 bld.SAMBA_PYTHON('python_netlogon',
338         source='../../librpc/gen_ndr/py_netlogon.c',
339         deps='RPC_NDR_NETLOGON pytalloc-util pyrpc_util',
340         realname='samba/dcerpc/netlogon.so'
341         )
342
343 bld.SAMBA_SCRIPT('python_dcerpc_init',
344                  pattern='rpc/dcerpc.py',
345                  installdir='python/samba/dcerpc',
346                  installname='__init__.py')
347
348 bld.INSTALL_FILES('${PYTHONARCHDIR}/samba/dcerpc', 'rpc/dcerpc.py', destname='__init__.py')