From aaddcb1afb3b2db595ba9d6cab5ddf0e9450a7c2 Mon Sep 17 00:00:00 2001 From: paul-reilly Date: Thu, 6 Feb 2020 19:07:19 +0000 Subject: Add post-build usage info for Lua port. (#9934) * Add post-build usage info for Lua port. * Fix CMake command that moves info file * Update Lua package version number --- ports/lua/CONTROL | 2 +- ports/lua/portfile.cmake | 2 ++ ports/lua/usage | 9 +++++++++ 3 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 ports/lua/usage (limited to 'ports/lua') diff --git a/ports/lua/CONTROL b/ports/lua/CONTROL index eeb26e412..9e22f3ea2 100644 --- a/ports/lua/CONTROL +++ b/ports/lua/CONTROL @@ -1,5 +1,5 @@ Source: lua -Version: 5.3.5-2 +Version: 5.3.5-3 Homepage: https://www.lua.org Description: a powerful, fast, lightweight, embeddable scripting language diff --git a/ports/lua/portfile.cmake b/ports/lua/portfile.cmake index b107c6cf9..42dea0b98 100644 --- a/ports/lua/portfile.cmake +++ b/ports/lua/portfile.cmake @@ -51,4 +51,6 @@ vcpkg_copy_tool_dependencies(${CURRENT_PACKAGES_DIR}/tools/lua) # Handle copyright file(COPY ${CMAKE_CURRENT_LIST_DIR}/COPYRIGHT DESTINATION ${CURRENT_PACKAGES_DIR}/share/lua/copyright) +# Handle post-build CMake instructions +file(INSTALL ${CMAKE_CURRENT_LIST_DIR}/usage DESTINATION ${CURRENT_PACKAGES_DIR}/share/lua) vcpkg_copy_pdbs() diff --git a/ports/lua/usage b/ports/lua/usage new file mode 100644 index 000000000..8a11e20b9 --- /dev/null +++ b/ports/lua/usage @@ -0,0 +1,9 @@ +Use this package via the module FindLua that comes with CMake. To use in your CMakeLists.txt: + + include(FindLua) + find_package(lua REQUIRED) + target_link_libraries(main PRIVATE ${LUA_LIBRARIES}) + target_include_directories(main PRIVATE ${LUA_INCLUDE_DIR}) + +For more information about the variables set by this module, please see: + https://cmake.org/cmake/help/latest/module/FindLua.html \ No newline at end of file -- cgit v1.2.3