author | koda |
Sat, 08 Dec 2012 15:38:16 +0100 | |
changeset 8272 | 93d8c77a13e8 |
parent 7718 | 97ba379164ec |
child 8044 | 796f2653f21d |
child 8316 | 89232b2fa1d6 |
permissions | -rw-r--r-- |
7031
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
1 |
#this file is included only when system Lua library is not found |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
2 |
|
3697 | 3 |
file(GLOB lua_src *.c *.h) |
2822 | 4 |
|
7031
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
5 |
if(WIN32) |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
6 |
add_definitions(-DLUA_BUILD_AS_DLL) |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
7 |
add_library(lua SHARED ${lua_src}) |
2822 | 8 |
|
7262 | 9 |
set(LUA_LIBRARY lua.dll) |
10 |
||
7031
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
11 |
set_target_properties(lua PROPERTIES PREFIX "") |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
12 |
install(TARGETS lua RUNTIME DESTINATION ${target_dir}) |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
13 |
else(WIN32) |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
14 |
add_definitions(-DLUA_USE_LINUX) |
d5ea24399a48
when Lua is not found, fallback to compiling the one that comes bundled in our sources
koda
parents:
5171
diff
changeset
|
15 |
add_library(lua STATIC ${lua_src}) |
7704
b25add2fdfa6
slight tweak to lua linking (that will break everything, i'm sure)
koda
parents:
7262
diff
changeset
|
16 |
set(LUA_LIBRARY lua) |
2822 | 17 |
endif(WIN32) |
18 |
||
19 |
||
20 |