s4:librpc: Fix code spelling
[Samba.git] / source4 / librpc / wscript_build
blobdd1494974e26dd7c1bb76fedacc60c1401f64d50
1 #!/usr/bin/env python
3 bld.RECURSE('../../librpc/idl')
4 bld.RECURSE('../../librpc/tools')
5 bld.RECURSE('idl')
8 bld.SAMBA_SUBSYSTEM('NDR_IRPC',
9 source='gen_ndr/ndr_irpc.c',
10 public_deps='ndr NDR_SECURITY ndr_nbt'
14 bld.SAMBA_SUBSYSTEM('NDR_SASL_HELPERS',
15 source='gen_ndr/ndr_sasl_helpers.c',
16 public_deps='ndr'
21 bld.SAMBA_SUBSYSTEM('NDR_WINSIF',
22 source='gen_ndr/ndr_winsif.c',
23 public_deps='ndr NDR_WINSREPL'
27 bld.SAMBA_SUBSYSTEM('NDR_OPENDB',
28 source='gen_ndr/ndr_opendb.c',
29 public_deps='ndr'
33 bld.SAMBA_SUBSYSTEM('NDR_NTP_SIGND',
34 source='gen_ndr/ndr_ntp_signd.c',
35 public_deps='ndr'
39 bld.SAMBA_SUBSYSTEM('NDR_WINSREPL',
40 source='gen_ndr/ndr_winsrepl.c',
41 public_deps='ndr ndr_nbt'
45 # create a grouping library to consolidate our samba4 specific NDR code
46 bld.SAMBA_LIBRARY('ndr-samba4',
47 source=[],
48 deps='NDR_WINBIND NDR_IRPC NDR_NFS4ACL NDR_OPENDB ndr-table',
49 private_library=True,
50 grouping_library=True
53 # a grouping library for RPC_NDR subsystems that may be used by more than one target
54 bld.SAMBA_LIBRARY('dcerpc-samba4',
55 source=[],
56 deps='RPC_NDR_WINBIND',
57 private_library=True,
58 grouping_library=True
62 bld.SAMBA_PIDL_TABLES('GEN_NDR_TABLES', 'gen_ndr/tables.c')
64 bld.SAMBA_SUBSYSTEM('ndr-table',
65 source='../../librpc/ndr/ndr_table.c gen_ndr/tables.c',
66 public_deps='''
67 ndr-standard
68 NDR_AUDIOSRV
69 NDR_DSBACKUP
70 NDR_EFS
71 NDR_DRSUAPI
72 NDR_POLICYAGENT
73 NDR_UNIXINFO
74 NDR_SPOOLSS
75 NDR_EPMAPPER
76 NDR_DBGIDL
77 NDR_DSSETUP
78 NDR_MSGSVC
79 NDR_WINSIF
80 NDR_MGMT
81 NDR_WZCSVC
82 NDR_BROWSER
83 NDR_W32TIME
84 NDR_SCERPC
85 NDR_TRKWKS
86 NDR_KEYSVC
87 ndr-krb5pac
88 NDR_SCHANNEL
89 NDR_ROT
90 NDR_DRSBLOBS
91 ndr_nbt
92 NDR_WINSREPL
93 NDR_SECURITY
94 NDR_DNSSERVER
95 NDR_WINSTATION
96 NDR_IRPC
97 NDR_OPENDB
98 NDR_SASL_HELPERS
99 NDR_NOTIFY
100 NDR_WINBIND
101 NDR_FRSRPC
102 NDR_FRSAPI
103 NDR_FRSTRANS
104 NDR_NTP_SIGND
105 NDR_NAMED_PIPE_AUTH
106 NDR_NTLMSSP
107 NDR_DFSBLOBS
108 NDR_DNSP
109 NDR_NTPRINTING
110 NDR_DNS
111 NDR_BACKUPKEY
112 NDR_PREG
113 NDR_BKUPBLOBS
114 NDR_FSCC
115 NDR_CLUSAPI
116 NDR_WINSPOOL
117 NDR_CAB
118 NDR_FSRVP_STATE
119 NDR_IOCTL
120 NDR_COMPRESSION
121 NDR_PRINTCAP
122 NDR_QUOTA
123 NDR_RAP
124 NDR_DCERPC
125 NDR_MESSAGING
126 NDR_SMB_ACL
127 NDR_PERFCOUNT
128 NDR_SECRETS
129 NDR_LEASES_DB
130 NDR_ODJ
131 NDR_ADS
132 ''',
133 depends_on='GEN_NDR_TABLES'
137 bld.SAMBA_SUBSYSTEM('RPC_NDR_IRPC',
138 source='gen_ndr/ndr_irpc_c.c',
139 public_deps='dcerpc NDR_IRPC'
142 bld.SAMBA_LIBRARY('dcerpc-samr',
143 source='',
144 pc_files='dcerpc_samr.pc',
145 vnum='0.0.1',
146 public_deps='dcerpc ndr-standard RPC_NDR_SAMR',
147 public_headers='../../librpc/gen_ndr/ndr_samr_c.h',
148 header_path='gen_ndr'
152 bld.SAMBA_LIBRARY('dcerpc',
153 source='''rpc/dcerpc.c rpc/dcerpc_auth.c rpc/dcerpc_schannel.c
154 rpc/dcerpc_util.c rpc/dcerpc_smb.c rpc/dcerpc_sock.c
155 rpc/dcerpc_roh_channel_in.c rpc/dcerpc_roh_channel_out.c rpc/dcerpc_roh.c
156 rpc/dcerpc_connect.c rpc/dcerpc_secondary.c''',
157 pc_files='dcerpc.pc',
158 deps='''
159 samba_socket
160 LIBCLI_RESOLVE
161 LIBCLI_SMB
162 LIBCLI_SMB2
164 NDR_DCERPC
165 RPC_NDR_EPMAPPER
166 NDR_SCHANNEL
167 RPC_NDR_NETLOGON
168 RPC_NDR_MGMT
169 gensec
170 LIBCLI_AUTH
171 smbclient-raw
172 LP_RESOLVE
173 tevent-util
174 dcerpc-binding
175 dcerpc-pkt-auth
176 param_options
177 http''',
178 autoproto='rpc/dcerpc_proto.h',
179 public_deps='samba-credentials tevent talloc',
180 public_headers='''rpc/dcerpc.h''',
181 # It's very important to keep this form of construction
182 # it force the sambawaf extension to put everything that match the first element
183 # (*gen_ndr*) into the dir named by the second element (gen_ndr).
184 # If we just put header_path = 'gen_ndr' then all the public_headers will go
185 # in 'gen_ndr' and for dcerpc.h (at least) it will cause a problem as
186 # we have already a dcerpc.h installed by librpc/wscript_build
187 # and one will overwrite the other which is not what we expect.
188 header_path=[ ('*gen_ndr*', 'gen_ndr') ],
189 vnum='0.0.1'
192 gen_cflags = ''
193 if bld.CONFIG_SET('HAVE_WNO_UNUSED_FUNCTION'):
194 gen_cflags = '-Wno-unused-function'
196 pyrpc_util = bld.pyembed_libname('pyrpc_util')
197 pytalloc_util = bld.pyembed_libname('pytalloc-util')
198 pyparam_util = bld.pyembed_libname('pyparam_util')
200 bld.SAMBA_SUBSYSTEM(pyrpc_util,
201 source='rpc/pyrpc_util.c',
202 public_deps='%s %s dcerpc MESSAGING' % (pytalloc_util, pyparam_util),
203 pyext=True,
204 enabled=bld.PYTHON_BUILD_IS_ENABLED(),
207 bld.SAMBA_PYTHON('python_dcerpc',
208 source='rpc/pyrpc.c',
209 public_deps='LIBCLI_SMB samba-util samba-hostconfig dcerpc-samr RPC_NDR_LSA DYNCONFIG %s gensec' % pyrpc_util,
210 realname='samba/dcerpc/base.so',
211 cflags_end=gen_cflags
214 bld.SAMBA_PYTHON('python_dcerpc_misc',
215 source='../../librpc/gen_ndr/py_misc.c',
216 deps='%s %s ndr-krb5pac' % (pytalloc_util, pyrpc_util),
217 realname='samba/dcerpc/misc.so',
218 cflags_end=gen_cflags
221 bld.SAMBA_PYTHON('python_auth',
222 source='../../librpc/gen_ndr/py_auth.c',
223 deps='NDR_AUTH %s %s' % (pytalloc_util, pyrpc_util),
224 realname='samba/dcerpc/auth.so',
225 cflags_end=gen_cflags
228 bld.SAMBA_PYTHON('python_dcerpc_security',
229 source='../../librpc/gen_ndr/py_security.c',
230 deps='%s %s NDR_SECURITY' % (pytalloc_util, pyrpc_util),
231 realname='samba/dcerpc/security.so',
232 cflags_end=gen_cflags
235 bld.SAMBA_PYTHON('python_conditional_ace',
236 source=('../../librpc/gen_ndr/py_conditional_ace.c '
237 '../../librpc/gen_ndr/ndr_conditional_ace.c'),
238 deps='%s %s' % (pytalloc_util, pyrpc_util),
239 realname='samba/dcerpc/conditional_ace.so',
240 cflags_end=gen_cflags
243 bld.SAMBA_PYTHON('python_lsa',
244 source='../../librpc/gen_ndr/py_lsa.c',
245 deps='RPC_NDR_LSA %s %s' % (pytalloc_util, pyrpc_util),
246 realname='samba/dcerpc/lsa.so',
247 cflags_end=gen_cflags
250 bld.SAMBA_PYTHON('python_krb5pac',
251 source='../../librpc/gen_ndr/py_krb5pac.c',
252 deps='ndr-krb5pac %s %s' % (pytalloc_util, pyrpc_util),
253 realname='samba/dcerpc/krb5pac.so',
254 cflags_end=gen_cflags
257 bld.SAMBA_PYTHON('python_krb5ccache',
258 source='../../librpc/gen_ndr/py_krb5ccache.c',
259 deps='NDR_KRB5CCACHE %s %s' % (pytalloc_util, pyrpc_util),
260 realname='samba/dcerpc/krb5ccache.so',
261 cflags_end=gen_cflags
264 bld.SAMBA_PYTHON('python_claims',
265 source='../../librpc/gen_ndr/py_claims.c',
266 deps='NDR_CLAIMS %s %s' % (pytalloc_util, pyrpc_util),
267 realname='samba/dcerpc/claims.so',
268 cflags_end=gen_cflags
271 bld.SAMBA_PYTHON('python_gkdi',
272 source='../../librpc/gen_ndr/py_gkdi.c',
273 deps='RPC_NDR_GKDI %s %s' % (pytalloc_util, pyrpc_util),
274 realname='samba/dcerpc/gkdi.so',
275 cflags_end=gen_cflags
278 bld.SAMBA_PYTHON('python_gmsa',
279 source='../../librpc/gen_ndr/py_gmsa.c',
280 deps='NDR_GMSA %s %s' % (pytalloc_util, pyrpc_util),
281 realname='samba/dcerpc/gmsa.so',
282 cflags_end=gen_cflags
285 bld.SAMBA_PYTHON('python_netlogon',
286 source='../../librpc/gen_ndr/py_netlogon.c',
287 deps='RPC_NDR_NETLOGON %s %s' % (pytalloc_util, pyrpc_util),
288 realname='samba/dcerpc/netlogon.so',
289 cflags_end=gen_cflags
292 bld.SAMBA_PYTHON('python_samr',
293 source='../../librpc/gen_ndr/py_samr.c',
294 deps='dcerpc-samr %s %s' % (pytalloc_util, pyrpc_util),
295 realname='samba/dcerpc/samr.so',
296 cflags_end=gen_cflags
299 bld.SAMBA_PYTHON('python_spoolss',
300 source='../../librpc/gen_ndr/py_spoolss.c',
301 deps='RPC_NDR_SPOOLSS %s %s' % (pytalloc_util, pyrpc_util),
302 realname='samba/dcerpc/spoolss.so'
305 bld.SAMBA_PYTHON('python_winspool',
306 source='../../librpc/gen_ndr/py_winspool.c',
307 deps='RPC_NDR_WINSPOOL %s %s' % (pytalloc_util, pyrpc_util),
308 realname='samba/dcerpc/winspool.so'
311 bld.SAMBA_PYTHON('python_witness',
312 source='../../librpc/gen_ndr/py_witness.c',
313 deps='RPC_NDR_WITNESS %s %s' % (pytalloc_util, pyrpc_util),
314 realname='samba/dcerpc/witness.so'
317 bld.SAMBA_PYTHON('python_dcerpc_nbt',
318 source='../../librpc/gen_ndr/py_nbt.c',
319 deps='ndr_nbt %s %s' % (pytalloc_util, pyrpc_util),
320 realname='samba/dcerpc/nbt.so',
321 cflags_end=gen_cflags
324 bld.SAMBA_PYTHON('python_dcerpc_drsblobs',
325 source='../../librpc/gen_ndr/py_drsblobs.c',
326 deps='%s %s NDR_SECURITY NDR_DRSBLOBS' % (pytalloc_util, pyrpc_util),
327 realname='samba/dcerpc/drsblobs.so',
328 cflags_end=gen_cflags
331 bld.SAMBA_PYTHON('python_dcerpc_ntlmssp',
332 source='../../librpc/gen_ndr/py_ntlmssp.c',
333 deps='%s %s NDR_NTLMSSP' % (pytalloc_util, pyrpc_util),
334 realname='samba/dcerpc/ntlmssp.so',
335 cflags_end=gen_cflags
338 bld.SAMBA_PYTHON('python_srvsvc',
339 source='../../librpc/gen_ndr/py_srvsvc.c',
340 deps='RPC_NDR_SRVSVC %s %s' % (pytalloc_util, pyrpc_util),
341 realname='samba/dcerpc/srvsvc.so',
342 cflags_end=gen_cflags
345 bld.SAMBA_PYTHON('python_echo',
346 source='../../librpc/gen_ndr/py_echo.c',
347 deps='RPC_NDR_ECHO %s %s' % (pytalloc_util, pyrpc_util),
348 realname='samba/dcerpc/echo.so',
349 cflags_end=gen_cflags
352 bld.SAMBA_PYTHON('python_dns',
353 source='../../librpc/gen_ndr/py_dns.c',
354 deps='NDR_DNS %s %s' % (pytalloc_util, pyrpc_util),
355 realname='samba/dcerpc/dns.so',
356 cflags_end=gen_cflags
359 bld.SAMBA_PYTHON('python_winreg',
360 source='../../librpc/gen_ndr/py_winreg.c',
361 deps='RPC_NDR_WINREG %s %s' % (pytalloc_util, pyrpc_util),
362 realname='samba/dcerpc/winreg.so',
363 cflags_end=gen_cflags
366 bld.SAMBA_PYTHON('python_preg',
367 source='../../librpc/gen_ndr/py_preg.c',
368 deps='NDR_PREG %s %s' % (pytalloc_util, pyrpc_util),
369 realname='samba/dcerpc/preg.so',
370 cflags_end=gen_cflags
373 bld.SAMBA_PYTHON('python_initshutdown',
374 source='../../librpc/gen_ndr/py_initshutdown.c',
375 deps='RPC_NDR_INITSHUTDOWN %s %s' % (pytalloc_util, pyrpc_util),
376 realname='samba/dcerpc/initshutdown.so',
377 cflags_end=gen_cflags
381 bld.SAMBA_PYTHON('python_epmapper',
382 source='../../librpc/gen_ndr/py_epmapper.c',
383 deps='dcerpc %s %s' % (pytalloc_util, pyrpc_util),
384 realname='samba/dcerpc/epmapper.so',
385 cflags_end=gen_cflags
389 bld.SAMBA_PYTHON('python_mgmt',
390 source='../../librpc/gen_ndr/py_mgmt.c',
391 deps='dcerpc %s %s' % (pytalloc_util, pyrpc_util),
392 realname='samba/dcerpc/mgmt.so',
393 cflags_end=gen_cflags
397 bld.SAMBA_PYTHON('python_atsvc',
398 source='../../librpc/gen_ndr/py_atsvc.c',
399 deps='RPC_NDR_ATSVC %s %s' % (pytalloc_util, pyrpc_util),
400 realname='samba/dcerpc/atsvc.so',
401 cflags_end=gen_cflags
405 bld.SAMBA_PYTHON('python_svcctl',
406 source='../../librpc/gen_ndr/py_svcctl.c',
407 deps='RPC_NDR_SVCCTL %s %s' % (pytalloc_util, pyrpc_util),
408 realname='samba/dcerpc/svcctl.so',
409 cflags_end=gen_cflags
413 bld.SAMBA_PYTHON('python_wkssvc',
414 source='../../librpc/gen_ndr/py_wkssvc.c',
415 deps='RPC_NDR_WKSSVC %s %s' % (pytalloc_util, pyrpc_util),
416 realname='samba/dcerpc/wkssvc.so',
417 cflags_end=gen_cflags
421 bld.SAMBA_PYTHON('python_dfs',
422 source='../../librpc/gen_ndr/py_dfs.c',
423 deps='RPC_NDR_DFS %s %s' % (pytalloc_util, pyrpc_util),
424 realname='samba/dcerpc/dfs.so',
425 cflags_end=gen_cflags
428 bld.SAMBA_PYTHON('python_dcerpc_dcerpc',
429 source='../../librpc/gen_ndr/py_dcerpc.c',
430 deps='NDR_DCERPC %s %s' % (pytalloc_util, pyrpc_util),
431 realname='samba/dcerpc/dcerpc.so',
432 cflags_end=gen_cflags
435 bld.SAMBA_PYTHON('python_unixinfo',
436 source='../../librpc/gen_ndr/py_unixinfo.c',
437 deps='RPC_NDR_UNIXINFO %s %s' % (pytalloc_util, pyrpc_util),
438 realname='samba/dcerpc/unixinfo.so',
439 cflags_end=gen_cflags
443 bld.SAMBA_PYTHON('python_irpc',
444 source='gen_ndr/py_irpc.c',
445 deps='RPC_NDR_IRPC %s %s' % (pytalloc_util, pyrpc_util),
446 realname='samba/dcerpc/irpc.so',
447 cflags_end=gen_cflags
450 bld.SAMBA_PYTHON('python_server_id',
451 source='../../librpc/gen_ndr/py_server_id.c',
452 deps='NDR_SERVER_ID %s %s' % (pytalloc_util, pyrpc_util),
453 realname='samba/dcerpc/server_id.so',
454 cflags_end=gen_cflags
457 python_netlogon = 'python_netlogon'
458 bld.SAMBA_PYTHON('python_winbind',
459 source='../../librpc/gen_ndr/py_winbind.c',
460 deps='RPC_NDR_WINBIND %s %s %s' % (pytalloc_util, pyrpc_util, python_netlogon),
461 realname='samba/dcerpc/winbind.so',
462 cflags_end=gen_cflags
465 bld.SAMBA_PYTHON('python_drsuapi',
466 source='../../librpc/gen_ndr/py_drsuapi.c',
467 deps='RPC_NDR_DRSUAPI %s %s' % (pytalloc_util, pyrpc_util),
468 realname='samba/dcerpc/drsuapi.so',
469 cflags_end=gen_cflags
472 bld.SAMBA_PYTHON('python_dcerpc_dnsp',
473 source='../../librpc/gen_ndr/py_dnsp.c',
474 deps='%s %s NDR_SECURITY NDR_DNSP' % (pytalloc_util, pyrpc_util),
475 realname='samba/dcerpc/dnsp.so',
476 cflags_end=gen_cflags
480 bld.SAMBA_PYTHON('python_dcerpc_xattr',
481 source='../../librpc/gen_ndr/py_xattr.c',
482 deps='%s %s NDR_XATTR' % (pytalloc_util, pyrpc_util),
483 realname='samba/dcerpc/xattr.so',
484 cflags_end=gen_cflags
487 bld.SAMBA_PYTHON('python_dcerpc_smb3posix',
488 source='../../librpc/gen_ndr/py_smb3posix.c',
489 deps='%s %s NDR_SMB3POSIX' % (pytalloc_util, pyrpc_util),
490 realname='samba/dcerpc/smb3posix.so',
491 cflags_end=gen_cflags
494 bld.SAMBA_PYTHON('python_dcerpc_idmap',
495 source='../../librpc/gen_ndr/py_idmap.c',
496 deps='%s %s NDR_IDMAP' % (pytalloc_util, pyrpc_util),
497 realname='samba/dcerpc/idmap.so',
498 cflags_end=gen_cflags
501 bld.SAMBA_PYTHON('python_dnsserver',
502 source='../../librpc/gen_ndr/py_dnsserver.c',
503 deps='RPC_NDR_DNSSERVER %s %s' % (pytalloc_util, pyrpc_util),
504 realname='samba/dcerpc/dnsserver.so',
505 cflags_end=gen_cflags
508 bld.SAMBA_PYTHON('python_dcerpc_smb_acl',
509 source='../../librpc/gen_ndr/py_smb_acl.c',
510 deps='%s %s' % (pytalloc_util, pyrpc_util),
511 realname='samba/dcerpc/smb_acl.so',
512 cflags_end=gen_cflags
515 bld.SAMBA_PYTHON('dcerpc_python_messaging',
516 source='../../librpc/gen_ndr/py_messaging.c',
517 deps='%s %s' % (pytalloc_util, pyrpc_util),
518 realname='samba/dcerpc/messaging.so',
519 cflags_end=gen_cflags
522 bld.SAMBA_PYTHON('dcerpc_windows_event_ids',
523 source='../../librpc/gen_ndr/py_windows_event_ids.c',
524 deps='%s %s' % (pytalloc_util, pyrpc_util),
525 realname='samba/dcerpc/windows_event_ids.so',
526 cflags_end=gen_cflags
529 bld.SAMBA_PYTHON('python_mdssvc',
530 source='../../librpc/gen_ndr/py_mdssvc.c',
531 deps='RPC_NDR_MDSSVC %s %s' % (pytalloc_util, pyrpc_util),
532 realname='samba/dcerpc/mdssvc.so',
533 cflags_end=gen_cflags
536 if bld.PYTHON_BUILD_IS_ENABLED():
537 bld.SAMBA_SCRIPT('python_dcerpc_init',
538 pattern='rpc/dcerpc.py',
539 installdir='python/samba/dcerpc',
540 installname='__init__.py')
542 bld.INSTALL_FILES('${PYTHONARCHDIR}/samba/dcerpc', 'rpc/dcerpc.py', destname='__init__.py')