build: neater way to find libreplace and start on tevent waf build
[samba.git] / lib / tevent / wscript
1 VERSION = '0.9.8'
2
3 srcdir = '.'
4 blddir = 'build'
5
6 LIBREPLACE_DIR='../replace'
7
8 def set_options(opt):
9     opt.recurse(LIBREPLACE_DIR)
10
11 def configure(conf):
12     conf.sub_config(LIBREPLACE_DIR)
13
14     conf.CHECK_HEADERS('sys/epoll.h')
15     conf.CHECK_FUNCS('epoll_create')
16
17     conf.SAMBA_CONFIG_H()
18
19 def build(bld):
20     bld.add_subdirs(LIBREPLACE_DIR)
21
22     SRC = '''tevent.c tevent_debug.c tevent_epoll.c tevent_fd.c tevent_immediate.c
23              tevent_queue.c tevent_req.c tevent_select.c
24              tevent_signal.c tevent_standard.c tevent_timed.c tevent_util.c tevent_wakeup.c'''
25
26
27     bld.SAMBA_LIBRARY('tevent',
28                       SRC,
29                       libdeps='replace talloc',
30                       vnum=VERSION)