mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-30 12:51:39 +08:00
938a5b44ba
LuaFileSystem (https://keplerproject.github.io/luafilesystem/) is a library that provides a portable way to access directory structure and file attributes from lua.
22 lines
553 B
CMake
22 lines
553 B
CMake
cmake_minimum_required(VERSION 3.0)
|
|
project(luafilesystem)
|
|
|
|
if(NOT WIN32)
|
|
message(FATAL_ERROR "Written for windows only")
|
|
endif()
|
|
|
|
find_path(LUA_INCLUDE_DIR lua.h PATH_SUFFIXES lua)
|
|
find_library(LUA_LIBRARY lua)
|
|
set(LFS_INCLUDES ${LUA_INCLUDE_DIR})
|
|
set(LFS_LIBRARIES ${LUA_LIBRARY})
|
|
|
|
add_library( lfs src/lfs.h src/lfs.c src/lfs.def)
|
|
|
|
target_include_directories(lfs PRIVATE ${LFS_INCLUDES})
|
|
target_link_libraries(lfs PRIVATE ${LFS_LIBRARIES})
|
|
|
|
install(TARGETS lfs
|
|
RUNTIME DESTINATION bin
|
|
LIBRARY DESTINATION lib
|
|
ARCHIVE DESTINATION lib)
|