From 76d153790caf0592fce8fc4484aa6db18c7d00d4 Mon Sep 17 00:00:00 2001 From: Cheney Wang <38240633+Cheney-W@users.noreply.github.com> Date: Fri, 27 Sep 2024 23:41:02 +0800 Subject: [PATCH] [luafilesystem] Fixes header file lfs.h not found (#41193) --- ports/luafilesystem/CMakeLists.txt | 3 +++ ports/luafilesystem/portfile.cmake | 5 +---- ports/luafilesystem/vcpkg.json | 2 +- versions/baseline.json | 2 +- versions/l-/luafilesystem.json | 5 +++++ 5 files changed, 11 insertions(+), 6 deletions(-) diff --git a/ports/luafilesystem/CMakeLists.txt b/ports/luafilesystem/CMakeLists.txt index 2637172faa6b93..4ff75b9e1745b6 100644 --- a/ports/luafilesystem/CMakeLists.txt +++ b/ports/luafilesystem/CMakeLists.txt @@ -10,6 +10,7 @@ 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}) +target_include_directories(lfs INTERFACE $) install(TARGETS lfs EXPORT "unofficial-${PROJECT_NAME}-targets" @@ -32,6 +33,8 @@ write_basic_package_version_file( COMPATIBILITY SameMajorVersion ) +install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/src/lfs.h" DESTINATION "include/luafilesystem") + install( FILES "${CMAKE_CURRENT_BINARY_DIR}/unofficial-${PROJECT_NAME}-config.cmake" DESTINATION "share/unofficial-${PROJECT_NAME}" diff --git a/ports/luafilesystem/portfile.cmake b/ports/luafilesystem/portfile.cmake index d0fe0cb51dede8..251280cf5acbe3 100644 --- a/ports/luafilesystem/portfile.cmake +++ b/ports/luafilesystem/portfile.cmake @@ -29,8 +29,5 @@ file(REMOVE_RECURSE ) # Handle copyright -file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") - -# Allow empty include directory -set(VCPKG_POLICY_EMPTY_INCLUDE_FOLDER enabled) diff --git a/ports/luafilesystem/vcpkg.json b/ports/luafilesystem/vcpkg.json index f741726f42295c..d26128707af220 100644 --- a/ports/luafilesystem/vcpkg.json +++ b/ports/luafilesystem/vcpkg.json @@ -1,7 +1,7 @@ { "name": "luafilesystem", "version": "1.8.0", - "port-version": 6, + "port-version": 7, "description": "LuaFileSystem is a Lua library developed to complement the set of functions related to file systems offered by the standard Lua distribution.", "homepage": "https://github.com/keplerproject/luafilesystem", "supports": "!uwp", diff --git a/versions/baseline.json b/versions/baseline.json index b58ece55f185df..3c95f95dc94f1d 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -5606,7 +5606,7 @@ }, "luafilesystem": { "baseline": "1.8.0", - "port-version": 6 + "port-version": 7 }, "luajit": { "baseline": "2023-01-04", diff --git a/versions/l-/luafilesystem.json b/versions/l-/luafilesystem.json index d2eb13406e7495..97566514fca1dd 100644 --- a/versions/l-/luafilesystem.json +++ b/versions/l-/luafilesystem.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "00b7638338af5a3a2d95c3c9b1ed870ed0cfb9fc", + "version": "1.8.0", + "port-version": 7 + }, { "git-tree": "4b474bdcc3f49eef949ba79ad3294556e39af778", "version": "1.8.0",