]> git.decadent.org.uk Git - ion3.git/blob - build/mkpreload.lua
[svn-inject] Installing original source of ion3
[ion3.git] / build / mkpreload.lua
1
2 io.stdout:write([[
3 /* Automatically generated. */
4                   
5 #include <ioncore/modules.h>
6
7 ]]);
8
9 for _, v in ipairs(arg) do
10     io.stdout:write(string.format([[
11 extern bool %s_init();
12 extern void %s_deinit();
13 ]], v, v));
14
15 end
16
17 io.stdout:write([[
18
19 WStaticModuleInfo ioncore_static_modules[]={
20 ]])
21
22 for _, v in ipairs(arg) do
23     io.stdout:write(string.format(
24         '    {"%s", %s_init, %s_deinit, FALSE},\n',
25         v, v, v));                          
26 end
27
28 io.stdout:write([[
29     {NULL, NULL, NULL, FALSE}
30 };
31 ]])        
32