Last change
on this file was 988, checked in by Silvan Scherrer, 9 years ago |
Samba Server: update vendor to version 4.4.3
|
File size:
1.2 KB
|
Line | |
---|
1 | import os
|
---|
2 | from samba_utils import os_path_relpath
|
---|
3 |
|
---|
4 | def build_test_headers(task):
|
---|
5 | '''symlink a header in the build tree'''
|
---|
6 | tgt = task.outputs[0].bldpath(task.env)
|
---|
7 | f = open(tgt, mode='w')
|
---|
8 | f.write('/* generated header test */\n')
|
---|
9 | hlist = task.env.public_headers_list[:]
|
---|
10 | hlist.sort()
|
---|
11 |
|
---|
12 | for h in hlist:
|
---|
13 | f.write('#include "%s"\n' % os.path.normpath(h))
|
---|
14 | f.close()
|
---|
15 |
|
---|
16 | relpath1 = os_path_relpath(bld.srcnode.abspath(), bld.curdir)
|
---|
17 | public_headers = []
|
---|
18 | for h in bld.env.public_headers_list:
|
---|
19 | public_headers.append(os.path.join(relpath1, bld.env.build_public_headers, h))
|
---|
20 |
|
---|
21 | bld.SAMBA_GENERATOR('test_headers.h',
|
---|
22 | group='main',
|
---|
23 | rule=build_test_headers,
|
---|
24 | source=public_headers,
|
---|
25 | target='test_headers.h')
|
---|
26 |
|
---|
27 | if bld.env.DEVELOPER_MODE:
|
---|
28 | bld.SAMBA_BINARY('test_headers',
|
---|
29 | source='test_headers.c',
|
---|
30 | includes="#include/public",
|
---|
31 | pyembed=True,
|
---|
32 | local_include=True,
|
---|
33 | global_include=False,
|
---|
34 | use_global_deps=False,
|
---|
35 | install=False,
|
---|
36 | deps='talloc tdb ldb tevent popt')
|
---|
Note:
See
TracBrowser
for help on using the repository browser.