aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/purkle/build.lua
diff options
context:
space:
mode:
Diffstat (limited to 'src/purkle/build.lua')
-rwxr-xr-xsrc/purkle/build.lua22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/purkle/build.lua b/src/purkle/build.lua
new file mode 100755
index 0000000..32ff522
--- /dev/null
+++ b/src/purkle/build.lua
@@ -0,0 +1,22 @@
1#!/usr/bin/env lua
2
3local dir = ...
4
5if 'nil' == type(dir) then
6 local build, err = loadfile('../../build.lua')
7 if build then
8 setfenv(build, getfenv(2))
9 build(2)
10 else
11 print("ERROR - " .. err)
12 end
13 dir = workingDir
14end
15
16CFLAGS = CFLAGS .. ' -I../GuiLua'
17LDFLAGS = '-L ' .. dir .. ' ' .. LDFLAGS
18libs = libs .. ' -lGuiLua -lwinFang -lRunnr'
19
20removeFiles(dir, {lib_d .. '/purkle.so'})
21
22runCommand('C modules', dir, 'gcc ' .. CFLAGS .. ' -fPIC -shared -o ' .. lib_d .. '/purkle.so purkle.c')