Skip to content

Commit

Permalink
Prevent building of lua executables
Browse files Browse the repository at this point in the history
Co-Authored-By: Foe <[email protected]>
  • Loading branch information
Niam5 and Foereaper committed Aug 18, 2024
1 parent 0028ca1 commit 07cc694
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions dep/lualib/lua/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -122,30 +122,30 @@ elseif (UNIX)
set_target_properties(lualib_static PROPERTIES OUTPUT_NAME ${LUA_VERSION})
endif()

add_executable(lua_interpreter ${LUA_SOURCE_FOLDER}/lua.c)
target_link_libraries(lua_interpreter lualib_static)
target_compile_definitions(lua_interpreter PRIVATE _CRT_SECURE_NO_WARNINGS)
set_target_properties(lua_interpreter PROPERTIES OUTPUT_NAME ${LUA_VERSION}_interpreter)
if (WIN32)
install(TARGETS lua_interpreter DESTINATION "${CMAKE_INSTALL_PREFIX}")
install(FILES $<TARGET_PDB_FILE:lua_interpreter> DESTINATION "${CMAKE_INSTALL_PREFIX}" OPTIONAL)
else()
install(TARGETS lua_interpreter DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
endif()
#add_executable(lua_interpreter ${LUA_SOURCE_FOLDER}/lua.c)
#target_link_libraries(lua_interpreter lualib_static)
#target_compile_definitions(lua_interpreter PRIVATE _CRT_SECURE_NO_WARNINGS)
#set_target_properties(lua_interpreter PROPERTIES OUTPUT_NAME ${LUA_VERSION}_interpreter)
#if (WIN32)
# install(TARGETS lua_interpreter DESTINATION "${CMAKE_INSTALL_PREFIX}")
# install(FILES $<TARGET_PDB_FILE:lua_interpreter> DESTINATION "${CMAKE_INSTALL_PREFIX}" OPTIONAL)
#else()
# install(TARGETS lua_interpreter DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
#endif()
#install(TARGETS lualib
# DESTINATION "${CMAKE_INSTALL_PREFIX}"
# LIBRARY DESTINATION "${CMAKE_INSTALL_PREFIX}/lua/lib"
# RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/lua/lib"
# ARCHIVE DESTINATION "${CMAKE_INSTALL_PREFIX}/lua/lib"
#)

add_executable(lua_compiler ${LUA_SOURCE_FOLDER}/luac.c)
target_link_libraries(lua_compiler lualib_static)
target_compile_definitions(lua_compiler PRIVATE _CRT_SECURE_NO_WARNINGS)
set_target_properties(lua_compiler PROPERTIES OUTPUT_NAME ${LUA_VERSION}_compiler)
if (WIN32)
install(TARGETS lua_compiler DESTINATION "${CMAKE_INSTALL_PREFIX}")
install(FILES $<TARGET_PDB_FILE:lua_compiler> DESTINATION "${CMAKE_INSTALL_PREFIX}" OPTIONAL)
else()
install(TARGETS lua_compiler DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
endif()
#add_executable(lua_compiler ${LUA_SOURCE_FOLDER}/luac.c)
#target_link_libraries(lua_compiler lualib_static)
#target_compile_definitions(lua_compiler PRIVATE _CRT_SECURE_NO_WARNINGS)
#set_target_properties(lua_compiler PROPERTIES OUTPUT_NAME ${LUA_VERSION}_compiler)
#if (WIN32)
# install(TARGETS lua_compiler DESTINATION "${CMAKE_INSTALL_PREFIX}")
# install(FILES $<TARGET_PDB_FILE:lua_compiler> DESTINATION "${CMAKE_INSTALL_PREFIX}" OPTIONAL)
#else()
# install(TARGETS lua_compiler DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
#endif()

0 comments on commit 07cc694

Please sign in to comment.