OSDN Git Service

fixed by @santarh
[meshio/meshio.git] / lua / premake4.lua
1 newoption {
2     --[[ usage: premake4 --static gmake ]]--
3     trigger     = "static",
4     description = "build static library"
5 }
6
7 solution "lmeshio"
8
9 configurations { "Debug", "Release" }
10
11 if _OPTIONS["static"] then
12     kind "StaticLib"
13     libdirs {
14     }
15     links {
16         "tolua++", "lua",
17         "meshio",
18     }
19     project "lmeshio_static"
20 else
21     kind "SharedLib"
22     defines {
23         --"TOLUA_API='__declspec(dllexport)'",
24     }
25     libdirs {
26         "/x86_64-w64-mingw32/local/bin",
27     }
28     links {
29         "tolua++", "lua51",
30         "meshio",
31     }
32     project "lmeshio"
33 end
34
35 language "C++"
36 files {
37     "lmeshio_bind.cpp",
38 }
39 prebuildcommands {
40     "make -f tolua.make",
41 }
42 buildoptions {
43     "-std=c++0x",
44 }
45 defines {
46 }
47 includedirs {
48     "../src",
49 }
50 linkoptions {
51 }
52
53 configuration "Debug"
54 do
55     defines { "DEBUG" }
56     flags { "Symbols" }
57     targetdir "../debug"
58     libdirs { "../debug" }
59 end
60 configuration "Release"
61 do
62     defines { "NDEBUG" }
63     flags { "Optimize" }
64     targetdir "../release"
65     libdirs { "../release" }
66 end
67