Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[lunasvg] Add new port #23867

Merged
merged 10 commits into from
Apr 5, 2022
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions ports/lunasvg/fix-install.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
CMakeLists.txt | 15 ++-------------
1 file changed, 2 insertions(+), 13 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9916c67..159f3a6 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -24,16 +24,5 @@ if(LUNASVG_BUILD_EXAMPLES)
add_subdirectory(example)
endif()

-set(LUNASVG_LIBDIR ${CMAKE_INSTALL_PREFIX}/lib)
-set(LUNASVG_INCDIR ${CMAKE_INSTALL_PREFIX}/include)
-
-install(FILES
- include/lunasvg.h
- DESTINATION ${LUNASVG_INCDIR}
-)
-
-install(TARGETS lunasvg
- LIBRARY DESTINATION ${LUNASVG_LIBDIR}
- ARCHIVE DESTINATION ${LUNASVG_LIBDIR}
- INCLUDES DESTINATION ${LUNASVG_INCDIR}
-)
+set_target_properties(lunasvg PROPERTIES PUBLIC_HEADER "include/lunasvg.h")
+install(TARGETS lunasvg RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib PUBLIC_HEADER DESTINATION include)
24 changes: 24 additions & 0 deletions ports/lunasvg/portfile.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO sammycage/lunasvg
REF e612abda858b53160041381a23422cd2b4f42fbd #2.3.1
SHA512 44f5d013d918cb5af90114a12857bdd2c204caff761516ef98b12b08d8b6215e91f6d963c281500c386f287b9d0ecd5b3d986d4c8c33423c0c34d539d744e09d
HEAD_REF master
PATCHES
fix-install.patch
)

vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DLUNASVG_BUILD_EXAMPLES=OFF
-DBUILD_SHARED_LIBS=OFF
)

vcpkg_cmake_install()
vcpkg_copy_pdbs()

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")

# Handle copyright
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
17 changes: 17 additions & 0 deletions ports/lunasvg/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"name": "lunasvg",
"version": "2.3.1",
"description": "lunasvg is a standalone SVG rendering library in C++",
"homepage": "https://github.com/sammycage/lunasvg",
"supports": "!uwp",
JonLiu1993 marked this conversation as resolved.
Show resolved Hide resolved
"dependencies": [
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
]
}
4 changes: 4 additions & 0 deletions versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4288,6 +4288,10 @@
"baseline": "2020-09-14",
"port-version": 2
},
"lunasvg": {
"baseline": "2.3.1",
"port-version": 0
},
"lv2": {
"baseline": "1.18.2",
"port-version": 1
Expand Down
9 changes: 9 additions & 0 deletions versions/l-/lunasvg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"versions": [
{
"git-tree": "21eb4e9b6cb5106d010be467d209312971e8c716",
"version": "2.3.1",
"port-version": 0
}
]
}