early-access version 2853
This commit is contained in:
50
externals/vcpkg/ports/libusbmuxd/CMakeLists.txt
vendored
Executable file
50
externals/vcpkg/ports/libusbmuxd/CMakeLists.txt
vendored
Executable file
@@ -0,0 +1,50 @@
|
||||
cmake_minimum_required(VERSION 3.0)
|
||||
project(libusbmuxd C)
|
||||
|
||||
# find dependencies
|
||||
find_path(libplist_INCLUDES plist.h PATH_SUFFIXES plist)
|
||||
set(libplist_INCLUDES ${libplist_INCLUDES}/../)
|
||||
find_library(libplist NAMES plist libplist plist-2.0 libplist-2.0 REQUIRED)
|
||||
|
||||
# ready to create library
|
||||
file(GLOB_RECURSE IDVCACTV_TOOLS_HDR common/*.h)
|
||||
file(GLOB_RECURSE IDVCACTV_TOOLS_SRC common/*.c)
|
||||
|
||||
file(GLOB_RECURSE IDVCACTV_PUBLIC_HDR include/*.h)
|
||||
file(GLOB_RECURSE IDVCACTV_SRC src/*.c)
|
||||
|
||||
add_library(libusbmuxd ${IDVCACTV_TOOLS_HDR} ${IDVCACTV_TOOLS_SRC} ${IDVCACTV_SRC} ${IDVCACTV_PUBLIC_HDR})
|
||||
target_include_directories(libusbmuxd PRIVATE ${libplist_INCLUDES} include common)
|
||||
target_compile_definitions(libusbmuxd PRIVATE -DPACKAGE_STRING="1.2.77")
|
||||
if (WIN32)
|
||||
target_compile_definitions(libusbmuxd PRIVATE -DWIN32)
|
||||
target_link_libraries(libusbmuxd PRIVATE Ws2_32)
|
||||
endif()
|
||||
target_link_libraries(libusbmuxd PRIVATE ${libplist})
|
||||
|
||||
# install
|
||||
install(
|
||||
TARGETS libusbmuxd
|
||||
RUNTIME DESTINATION bin
|
||||
ARCHIVE DESTINATION lib
|
||||
LIBRARY DESTINATION lib
|
||||
)
|
||||
|
||||
set(LIBPLIST_VERSION 2.0)
|
||||
set(PACKAGE_NAME libusbmuxd)
|
||||
set(PACKAGE_VERSION 2.0)
|
||||
set(prefix ${CMAKE_INSTALL_PREFIX})
|
||||
set(exec_prefix \${prefix})
|
||||
set(libdir \${prefix}/lib)
|
||||
set(includedir \${prefix}/../include)
|
||||
configure_file(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/src/libusbmuxd-2.0.pc.in
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libusbmuxd-2.0.pc
|
||||
@ONLY
|
||||
)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libusbmuxd-2.0.pc
|
||||
DESTINATION lib/pkgconfig
|
||||
)
|
||||
|
||||
install(FILES ${IDVCACTV_PUBLIC_HDR} DESTINATION include)
|
||||
20
externals/vcpkg/ports/libusbmuxd/fix-win-build.patch
vendored
Executable file
20
externals/vcpkg/ports/libusbmuxd/fix-win-build.patch
vendored
Executable file
@@ -0,0 +1,20 @@
|
||||
diff --git a/src/libusbmuxd.c b/src/libusbmuxd.c
|
||||
index e85cf4a..35ed1b5 100644
|
||||
--- a/src/libusbmuxd.c
|
||||
+++ b/src/libusbmuxd.c
|
||||
@@ -86,6 +86,15 @@ static char* stpncpy(char *dst, const char *src, size_t len)
|
||||
}
|
||||
#endif
|
||||
|
||||
+#ifdef WIN32
|
||||
+int strcasecmp(char *s1, char *s2)
|
||||
+{
|
||||
+ while (toupper((unsigned char)*s1) == toupper((unsigned char)*s2++))
|
||||
+ if (*s1++ == '\0') return 0;
|
||||
+ return(toupper((unsigned char)*s1) - toupper((unsigned char)*--s2));
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
#include <plist/plist.h>
|
||||
#define PLIST_CLIENT_VERSION_STRING PACKAGE_STRING
|
||||
#define PLIST_LIBUSBMUX_VERSION 3
|
||||
24
externals/vcpkg/ports/libusbmuxd/portfile.cmake
vendored
Executable file
24
externals/vcpkg/ports/libusbmuxd/portfile.cmake
vendored
Executable file
@@ -0,0 +1,24 @@
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO libimobiledevice-win32/libusbmuxd
|
||||
REF ac86b23f57879b8b702f3712ba66729008d059a3 # v1.2.219
|
||||
SHA512 ced85088bc6ebb416ccb635d6b4e79662fb34f427d869b64b61847e5fde7b4ae094cebb1f7916d9387c314aeb84106a618fbd7497dc4b36151b236dcb55bd0e4
|
||||
HEAD_REF msvc-master
|
||||
PATCHES fix-win-build.patch
|
||||
)
|
||||
|
||||
configure_file(${CURRENT_PORT_DIR}/CMakeLists.txt ${SOURCE_PATH}/CMakeLists.txt COPYONLY)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
vcpkg_copy_pdbs()
|
||||
vcpkg_fixup_pkgconfig()
|
||||
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
|
||||
# Handle copyright
|
||||
file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
|
||||
10
externals/vcpkg/ports/libusbmuxd/vcpkg.json
vendored
Executable file
10
externals/vcpkg/ports/libusbmuxd/vcpkg.json
vendored
Executable file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"name": "libusbmuxd",
|
||||
"version": "1.2.219",
|
||||
"port-version": 2,
|
||||
"description": "A client library to multiplex connections from and to iOS devices",
|
||||
"supports": "!(uwp | linux | osx)",
|
||||
"dependencies": [
|
||||
"libplist"
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user