-
Notifications
You must be signed in to change notification settings - Fork 22
/
lakefile
55 lines (46 loc) · 1.48 KB
/
lakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
PROJECT = 'llthreads'
INITLAKEFILE()
DEFINES = L{DEFINES,
IF(WINDOWS, 'DLL_EXPORT', '');
IF(not MSVC, 'USE_PTHREAD', '');
}
core = c.shared{PROJECT,
base = 'src',
src = '*.c',
needs = LUA_NEED,
defines = DEFINES,
dynamic = DYNAMIC,
strip = true,
libs = IF(not MSVC, 'pthread');
}
target('build', core)
install = target('install', {
file.group{odir=LIBDIR; src = core };
file.group{odir=J(LIBDIR, PROJECT); src = J('src', 'lua', 'llthreads2'); recurse = true };
file.group{odir=TESTDIR; src = J('test', '*'); recurse = true };
})
target('test', install, function()
-- run_test('test_register_llthreads.lua')
run_test('test_version.lua')
run_test('test_join_timeout.lua')
run_test('test_llthreads.lua')
run_test('test_table_copy.lua')
run_test('test_threads.lua 10')
run_test('test_join_timeout.lua')
run_test('test_join_detach.lua')
run_test('test_join_error.lua')
run_test('test_register_ffi.lua')
run_test('test_logger.lua')
run_test('test_pass_cfunction.lua')
run_test('test_alive.lua')
run_test('test_threads_ex.lua 10')
run_test('test_threads_ex_arg.lua')
run_test('test_threads_ex_opt.lua')
run_test('test_threads_ex_opt_2.lua')
run_test('test_threads_attr.lua')
run_test('test_interrupt.lua')
run_test('test_error.lua')
if not test_summary() then
quit("test fail")
end
end)