summaryrefslogtreecommitdiffstats
path: root/lib/lua/CMakeLists.txt
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-01-16 19:37:46 +0100
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-01-16 19:37:46 +0100
commit3373daca2675617117ac60abb7dd3f6511916d2c (patch)
tree6339eb1d6f6682869dd96e46e392b43dfbe6209c /lib/lua/CMakeLists.txt
parentOBSOLETE'd obsolete functions (diff)
parentMerge pull request #548 from worktycho/documention (diff)
downloadcuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar.gz
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar.bz2
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar.lz
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar.xz
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.tar.zst
cuberite-3373daca2675617117ac60abb7dd3f6511916d2c.zip
Diffstat (limited to '')
-rw-r--r--lib/lua/CMakeLists.txt14
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/lua/CMakeLists.txt b/lib/lua/CMakeLists.txt
index 9052da194..02c20388d 100644
--- a/lib/lua/CMakeLists.txt
+++ b/lib/lua/CMakeLists.txt
@@ -22,11 +22,17 @@ endif()
if (WIN32)
add_library(lua SHARED ${SOURCE})
set(LIBRARY_OUTPUT_PATH ${CMAKE_SOURCE_DIR}/MCServer)
- if (MSVC)
- # MSVC generator adds a "Debug" or "Release" postfixes to the LIBRARY_OUTPUT_PATH, we need to cancel them:
- SET_TARGET_PROPERTIES(lua PROPERTIES PREFIX "../")
- SET_TARGET_PROPERTIES(lua PROPERTIES IMPORT_PREFIX "../")
+ # Output the executable into the $/MCServer folder, so that MCServer can find it:
+ set(EXECUTABLE_OUTPUT_PATH ${CMAKE_SOURCE_DIR}/MCServer)
+ SET_TARGET_PROPERTIES(${EXECUTABLE} PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY_DEBUG ${CMAKE_SOURCE_DIR}/MCServer
+ RUNTIME_OUTPUT_DIRECTORY_RELEASE ${CMAKE_SOURCE_DIR}/MCServer
+ RUNTIME_OUTPUT_DIRECTORY_DEBUGPROFILE ${CMAKE_SOURCE_DIR}/MCServer
+ RUNTIME_OUTPUT_DIRECTORY_RELEASEPROFILE ${CMAKE_SOURCE_DIR}/MCServer
+ )
+
+ if (MSVC)
# Remove SCL warnings, we expect this library to have been tested safe
SET_TARGET_PROPERTIES(
lua PROPERTIES COMPILE_FLAGS "-D_CRT_SECURE_NO_WARNINGS"