fix artefacts
This commit is contained in:
parent
c6cbf941a2
commit
42253fc58a
@ -2,6 +2,8 @@ cmake_minimum_required(VERSION 3.21)
|
|||||||
cmake_policy(SET CMP0171 NEW)
|
cmake_policy(SET CMP0171 NEW)
|
||||||
project(twnlua LANGUAGES C)
|
project(twnlua LANGUAGES C)
|
||||||
|
|
||||||
|
option(TWN_OUT_DIR "Artifact destination" ${CMAKE_SOURCE_DIR})
|
||||||
|
|
||||||
if(NOT CMAKE_BUILD_TYPE)
|
if(NOT CMAKE_BUILD_TYPE)
|
||||||
set(CMAKE_BUILD_TYPE Debug)
|
set(CMAKE_BUILD_TYPE Debug)
|
||||||
endif()
|
endif()
|
||||||
@ -39,5 +41,5 @@ set(SOURCE_FILES
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/luabind.c
|
${CMAKE_CURRENT_SOURCE_DIR}/luabind.c
|
||||||
)
|
)
|
||||||
|
|
||||||
cmake_path(GET CMAKE_SOURCE_DIR STEM LAST_ONLY GAME_PROJECT_NAME)
|
cmake_path(GET TWN_OUT_DIR STEM LAST_ONLY GAME_PROJECT_NAME)
|
||||||
use_townengine(${GAME_PROJECT_NAME} "${SOURCE_FILES}" ${CMAKE_SOURCE_DIR})
|
use_townengine(${GAME_PROJECT_NAME} "${SOURCE_FILES}" ${TWN_OUT_DIR})
|
||||||
|
@ -24,7 +24,7 @@ if "--release" in argv:
|
|||||||
cmake += ["-DCMAKE_BUILD_TYPE=Release"]
|
cmake += ["-DCMAKE_BUILD_TYPE=Release"]
|
||||||
# pass arbitrary arguments over
|
# pass arbitrary arguments over
|
||||||
if "--" in argv:
|
if "--" in argv:
|
||||||
cmake += argv[argv.find("--"):]
|
cmake += argv[argv.index("--")+1:]
|
||||||
|
|
||||||
# if no root cmake file is present, infer it from `twn.toml:game.interpreter`
|
# if no root cmake file is present, infer it from `twn.toml:game.interpreter`
|
||||||
if not Path("CMakeLists.txt").is_file():
|
if not Path("CMakeLists.txt").is_file():
|
||||||
|
Loading…
Reference in New Issue
Block a user