mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-01-14 12:57:59 +08:00
[exiv2] Update to 0.28 (#33126)
* [exiv2] Update to 0.28 * Fix static build usage
This commit is contained in:
parent
7dbb5af43b
commit
81947d1b54
17
ports/exiv2/dont-find-python.patch
Normal file
17
ports/exiv2/dont-find-python.patch
Normal file
@ -0,0 +1,17 @@
|
||||
diff --git a/cmake/findDependencies.cmake b/cmake/findDependencies.cmake
|
||||
index 664522c2a..cbfa5d908 100644
|
||||
--- a/cmake/findDependencies.cmake
|
||||
+++ b/cmake/findDependencies.cmake
|
||||
@@ -30,10 +30,12 @@ endif()
|
||||
|
||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/")
|
||||
|
||||
+if(EXIV2_BUILD_UNIT_TESTS)
|
||||
find_package (Python3 COMPONENTS Interpreter)
|
||||
if (NOT Python3_Interpreter_FOUND)
|
||||
message(WARNING "Python3 was not found. Python tests under the 'tests' folder will not be executed")
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
find_package(Filesystem REQUIRED)
|
||||
|
27
ports/exiv2/fix-brotli.patch
Normal file
27
ports/exiv2/fix-brotli.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff --git a/cmake/findDependencies.cmake b/cmake/findDependencies.cmake
|
||||
index bec2128a5..664522c2a 100644
|
||||
--- a/cmake/findDependencies.cmake
|
||||
+++ b/cmake/findDependencies.cmake
|
||||
@@ -47,7 +47,7 @@ if( EXIV2_ENABLE_PNG )
|
||||
endif( )
|
||||
|
||||
if( EXIV2_ENABLE_BMFF AND EXIV2_ENABLE_BROTLI )
|
||||
- find_package( Brotli REQUIRED )
|
||||
+ find_package( BROTLI NAMES unofficial-brotli CONFIG REQUIRED )
|
||||
endif( )
|
||||
|
||||
if( EXIV2_ENABLE_WEBREADY )
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index 15bab8c8a..3db5bdd08 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -240,8 +240,7 @@ if( EXIV2_ENABLE_PNG )
|
||||
endif()
|
||||
|
||||
if( EXIV2_ENABLE_BMFF AND BROTLI_FOUND )
|
||||
- target_link_libraries( exiv2lib PRIVATE ${Brotli_LIBRARIES})
|
||||
- target_include_directories(exiv2lib PRIVATE ${Brotli_INCLUDE_DIRS})
|
||||
+ target_link_libraries( exiv2lib PRIVATE unofficial::brotli::brotlidec)
|
||||
list(APPEND requires_private_list "libbrotlidec")
|
||||
endif()
|
||||
|
28
ports/exiv2/fix-expat.patch
Normal file
28
ports/exiv2/fix-expat.patch
Normal file
@ -0,0 +1,28 @@
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index 41a672e8..1311c856 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -182,7 +182,7 @@ target_include_directories(exiv2lib SYSTEM PRIVATE
|
||||
)
|
||||
|
||||
if (EXIV2_ENABLE_XMP OR EXIV2_ENABLE_EXTERNAL_XMP)
|
||||
target_include_directories(exiv2lib PRIVATE ${EXPAT_INCLUDE_DIR})
|
||||
- target_link_libraries(exiv2lib PRIVATE EXPAT::EXPAT)
|
||||
+ target_link_libraries(exiv2lib PRIVATE expat::expat)
|
||||
list(APPEND requires_private_list "expat")
|
||||
endif()
|
||||
|
||||
if (EXIV2_ENABLE_XMP)
|
||||
diff --git a/xmpsdk/CMakeLists.txt b/xmpsdk/CMakeLists.txt
|
||||
index 9c148a61..0fed7cde 100644
|
||||
--- a/xmpsdk/CMakeLists.txt
|
||||
+++ b/xmpsdk/CMakeLists.txt
|
||||
@@ -28,7 +28,7 @@ add_library(exiv2-xmp OBJECT
|
||||
|
||||
target_link_libraries(exiv2-xmp
|
||||
PRIVATE
|
||||
- EXPAT::EXPAT
|
||||
+ expat::expat
|
||||
)
|
||||
|
||||
target_include_directories(exiv2-xmp SYSTEM
|
32
ports/exiv2/fix-inih.patch
Normal file
32
ports/exiv2/fix-inih.patch
Normal file
@ -0,0 +1,32 @@
|
||||
diff --git a/cmake/findDependencies.cmake b/cmake/findDependencies.cmake
|
||||
index 1075c3031..bec2128a5 100644
|
||||
--- a/cmake/findDependencies.cmake
|
||||
+++ b/cmake/findDependencies.cmake
|
||||
@@ -77,7 +77,7 @@ if( ICONV_FOUND )
|
||||
endif()
|
||||
|
||||
if( EXIV2_ENABLE_INIH )
|
||||
- find_package(inih)
|
||||
+ find_package(unofficial-inih CONFIG REQUIRED)
|
||||
message ( "-- inih_INCLUDE_DIRS : " ${inih_INCLUDE_DIRS} )
|
||||
message ( "-- inih_LIBRARIES : " ${inih_LIBRARIES} )
|
||||
message ( "-- inih_inireader_INCLUDE_DIRS : " ${inih_inireader_INCLUDE_DIRS} )
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index dba7af99c..15bab8c8a 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -263,10 +263,10 @@ if( Iconv_FOUND AND Iconv_LIBRARIES )
|
||||
endif()
|
||||
|
||||
if( EXIV2_ENABLE_INIH )
|
||||
- target_link_libraries( exiv2lib_int PRIVATE inih::libinih )
|
||||
- target_link_libraries( exiv2lib_int PRIVATE inih::inireader )
|
||||
- target_link_libraries( exiv2lib PRIVATE inih::libinih )
|
||||
- target_link_libraries( exiv2lib PRIVATE inih::inireader )
|
||||
+ target_link_libraries( exiv2lib_int PRIVATE unofficial::inih::libinih )
|
||||
+ target_link_libraries( exiv2lib_int PRIVATE unofficial::inih::inireader )
|
||||
+ target_link_libraries( exiv2lib PRIVATE unofficial::inih::libinih )
|
||||
+ target_link_libraries( exiv2lib PRIVATE unofficial::inih::inireader )
|
||||
list(APPEND requires_private_list "INIReader")
|
||||
endif()
|
||||
|
@ -2,15 +2,18 @@ vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO Exiv2/exiv2
|
||||
REF "v${VERSION}"
|
||||
SHA512 7d7121770a9394efd31acb74709583e587351fc48c485a2f684cacce4ed19a2d07a6cb1cea986c16bf64851fd53b22a7277c1e1ae1a6cd69a5761afae3c5c731
|
||||
SHA512 35e483c6123f099167ed8647fae7c6e5512434c24d0afe684180ba6a5114068d5678280a01c8e6cfee0d1e555e1dc2a1606989d46950ce3ef1a3859caeed4dad
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
fix-find_expat.patch
|
||||
fix-inih.patch
|
||||
fix-brotli.patch
|
||||
fix-expat.patch
|
||||
dont-find-python.patch
|
||||
)
|
||||
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
unicode EXIV2_ENABLE_WIN_UNICODE
|
||||
xmp EXIV2_ENABLE_XMP
|
||||
video EXIV2_ENABLE_VIDEO
|
||||
png EXIV2_ENABLE_PNG
|
||||
@ -31,12 +34,10 @@ vcpkg_cmake_configure(
|
||||
-DEXIV2_BUILD_SAMPLES=OFF
|
||||
-DEXIV2_BUILD_DOC=OFF
|
||||
-DEXIV2_ENABLE_EXTERNAL_XMP=OFF
|
||||
-DEXIV2_ENABLE_PRINTUCS2=OFF
|
||||
-DEXIV2_ENABLE_LENSDATA=ON
|
||||
-DEXIV2_ENABLE_DYNAMIC_RUNTIME=${EXIV2_CRT_DYNAMIC}
|
||||
-DEXIV2_ENABLE_WEBREADY=OFF
|
||||
-DEXIV2_ENABLE_CURL=OFF
|
||||
-DEXIV2_ENABLE_SSH=OFF
|
||||
-DEXIV2_TEAM_EXTRA_WARNINGS=OFF
|
||||
-DEXIV2_TEAM_WARNINGS_AS_ERRORS=OFF
|
||||
-DEXIV2_TEAM_PACKAGING=OFF
|
||||
@ -64,3 +65,5 @@ file(REMOVE_RECURSE
|
||||
)
|
||||
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
|
||||
|
||||
configure_file("${CMAKE_CURRENT_LIST_DIR}/usage" "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" COPYONLY)
|
4
ports/exiv2/usage
Normal file
4
ports/exiv2/usage
Normal file
@ -0,0 +1,4 @@
|
||||
exiv2 provides CMake targets:
|
||||
|
||||
find_package(exiv2 CONFIG REQUIRED)
|
||||
target_link_libraries(main PRIVATE exiv2lib)
|
@ -7,12 +7,25 @@ if("@VCPKG_LIBRARY_LINKAGE@" STREQUAL "static")
|
||||
if("@EXIV2_ENABLE_NLS@")
|
||||
find_package(Intl REQUIRED)
|
||||
endif()
|
||||
if("@EXIV2_ENABLE_BMFF@")
|
||||
find_package(unofficial-brotli CONFIG REQUIRED)
|
||||
endif()
|
||||
if("@EXIV2_ENABLE_XMP@")
|
||||
find_package(expat CONFIG REQUIRED)
|
||||
endif()
|
||||
if("@EXIV2_ENABLE_PNG@")
|
||||
find_package( ZLIB REQUIRED )
|
||||
endif()
|
||||
find_package(unofficial-inih CONFIG REQUIRED)
|
||||
if(TARGET exiv2lib)
|
||||
if(NOT "@VCPKG_TARGET_IS_WINDOWS@")
|
||||
set_property(TARGET exiv2lib APPEND PROPERTY INTERFACE_LINK_LIBRARIES Iconv::Iconv)
|
||||
endif()
|
||||
if("@EXIV2_ENABLE_NLS@")
|
||||
set_property(TARGET exiv2lib APPEND PROPERTY INTERFACE_LINK_LIBRARIES ${Intl_LIBRARIES})
|
||||
set_property(TARGET exiv2lib APPEND PROPERTY INTERFACE_LINK_LIBRARIES
|
||||
"\$<\$<NOT:\$<CONFIG:DEBUG>>:${Intl_LIBRARY_RELEASE}>"
|
||||
"\$<\$<CONFIG:DEBUG>:${Intl_LIBRARY_DEBUG}>"
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "exiv2",
|
||||
"version": "0.27.6",
|
||||
"port-version": 3,
|
||||
"version": "0.28.0",
|
||||
"description": "Image metadata library and tools",
|
||||
"homepage": "https://exiv2.org",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"supports": "!uwp & !xbox",
|
||||
"dependencies": [
|
||||
"inih",
|
||||
{
|
||||
"name": "libiconv",
|
||||
"platform": "!windows"
|
||||
@ -22,7 +22,10 @@
|
||||
],
|
||||
"features": {
|
||||
"bmff": {
|
||||
"description": "Support for BMFF files (e.g., CR3, HEIF, HEIC, AVIF, and JPEG XL)"
|
||||
"description": "Support for BMFF files (e.g., CR3, HEIF, HEIC, AVIF, and JPEG XL)",
|
||||
"dependencies": [
|
||||
"brotli"
|
||||
]
|
||||
},
|
||||
"nls": {
|
||||
"description": "Build native language support",
|
||||
@ -44,10 +47,6 @@
|
||||
"zlib"
|
||||
]
|
||||
},
|
||||
"unicode": {
|
||||
"description": "Compile with Unicode support on Windows",
|
||||
"supports": "windows"
|
||||
},
|
||||
"video": {
|
||||
"description": "Build video support into library"
|
||||
},
|
||||
|
@ -2405,8 +2405,8 @@
|
||||
"port-version": 7
|
||||
},
|
||||
"exiv2": {
|
||||
"baseline": "0.27.6",
|
||||
"port-version": 3
|
||||
"baseline": "0.28.0",
|
||||
"port-version": 0
|
||||
},
|
||||
"expat": {
|
||||
"baseline": "2.5.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "8d3de5f93cf2b1fa2e4a6c3b9ef5b6a30087bb22",
|
||||
"version": "0.28.0",
|
||||
"port-version": 0
|
||||
},
|
||||
{
|
||||
"git-tree": "3966c9ebea089fea43d1730cc2b1b21bd5703d3e",
|
||||
"version": "0.27.6",
|
||||
|
Loading…
x
Reference in New Issue
Block a user