You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
1.0 KiB
45 lines
1.0 KiB
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=TESTDIR; src = J('test', '*'); recurse = true };
|
|
})
|
|
|
|
target('test', install, function()
|
|
-- run_test('test_register_llthreads.lua')
|
|
run_test('test_join_timeout.lua')
|
|
run_test('test_llthreads.lua')
|
|
run_test('test_table_copy.lua')
|
|
run_test('test_threads.lua')
|
|
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')
|
|
|
|
if not test_summary() then
|
|
quit("test fail")
|
|
end
|
|
end)
|
|
|
|
|