Skip to content

Commit

Permalink
add lua source code to cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-lysiuk committed Aug 6, 2023
1 parent a6e9229 commit 4ee6379
Showing 1 changed file with 60 additions and 1 deletion.
61 changes: 60 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,64 @@ set(COMMON_SOURCES
Quake/miniz.h
)

set(LUA_DIR Quake/lua)

set(LUA_SOURCES
${LUA_DIR}/lapi.c
${LUA_DIR}/lapi.h
${LUA_DIR}/lauxlib.c
${LUA_DIR}/lauxlib.h
${LUA_DIR}/lbaselib.c
${LUA_DIR}/lcode.c
${LUA_DIR}/lcode.h
${LUA_DIR}/lctype.c
${LUA_DIR}/lctype.h
${LUA_DIR}/ldebug.c
${LUA_DIR}/ldebug.h
${LUA_DIR}/ldo.c
${LUA_DIR}/ldo.h
${LUA_DIR}/ldump.c
${LUA_DIR}/lfunc.c
${LUA_DIR}/lfunc.h
${LUA_DIR}/lgc.c
${LUA_DIR}/lgc.h
${LUA_DIR}/ljumptab.h
${LUA_DIR}/llex.c
${LUA_DIR}/llex.h
${LUA_DIR}/llimits.h
${LUA_DIR}/lmathlib.c
${LUA_DIR}/lmem.c
${LUA_DIR}/lmem.h
${LUA_DIR}/lobject.c
${LUA_DIR}/lobject.h
${LUA_DIR}/lopcodes.c
${LUA_DIR}/lopcodes.h
${LUA_DIR}/lparser.c
${LUA_DIR}/lparser.h
${LUA_DIR}/lprefix.h
${LUA_DIR}/lstate.c
${LUA_DIR}/lstate.h
${LUA_DIR}/lstring.c
${LUA_DIR}/lstring.h
${LUA_DIR}/lstrlib.c
${LUA_DIR}/ltable.c
${LUA_DIR}/ltable.h
${LUA_DIR}/ltablib.c
${LUA_DIR}/ltm.c
${LUA_DIR}/ltm.h
${LUA_DIR}/lua.h
${LUA_DIR}/luaconf.h
${LUA_DIR}/lualib.h
${LUA_DIR}/lundump.c
${LUA_DIR}/lundump.h
${LUA_DIR}/lvm.c
${LUA_DIR}/lvm.h
${LUA_DIR}/lzio.c
${LUA_DIR}/lzio.h
)

source_group("Source Files\\Lua" FILES ${LUA_SOURCES})

set(POSIX_SOURCES
Quake/net_bsd.c
Quake/net_udp.c
Expand Down Expand Up @@ -233,7 +291,7 @@ else()
endif()
endif()

target_include_directories(${PROJECT_NAME} PRIVATE Quake)
target_include_directories(${PROJECT_NAME} PRIVATE Quake ${LUA_DIR})

if(APPLE)
if(NOT QUAKE_MACOS_MOUSE_ACCELERATION)
Expand Down Expand Up @@ -314,6 +372,7 @@ endif()

target_sources(${PROJECT_NAME} PRIVATE
${COMMON_SOURCES}
${LUA_SOURCES}
${PLATFORM_SOURCE}
${OTHER_FILES}
)
Expand Down

0 comments on commit 4ee6379

Please sign in to comment.