vcpkg/ports/exiv2/iconv.patch

37 lines
1.0 KiB
Diff
Raw Normal View History

2018-06-13 01:32:58 +08:00
--- a/cmake/findDependencies.cmake
+++ b/cmake/findDependencies.cmake
@@ -36,5 +36,5 @@
if (EXIV2_ENABLE_NLS)
- find_package(Intl REQUIRED)
+ find_package(unofficial-gettext CONFIG)
2018-06-13 01:32:58 +08:00
endif( )
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 91469b6..4c51068 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -208,14 +208,14 @@
endif()
if( EXIV2_ENABLE_NLS )
- target_link_libraries(exiv2lib PRIVATE ${Intl_LIBRARIES})
- target_include_directories(exiv2lib PRIVATE ${Intl_INCLUDE_DIRS})
+ target_link_libraries(exiv2lib PRIVATE unofficial::gettext::libintl)
# Definition needed for translations
target_compile_definitions(exiv2lib PUBLIC EXV_LOCALEDIR="/../${CMAKE_INSTALL_LOCALEDIR}")
2018-06-13 01:32:58 +08:00
endif()
-if( ICONV_FOUND )
- target_link_libraries( exiv2lib PRIVATE Iconv::Iconv )
-endif()
+if(NOT TARGET unofficial::iconv::libiconv)
+ find_package(unofficial-iconv CONFIG)
+endif()
+target_link_libraries( exiv2lib PRIVATE unofficial::iconv::libiconv )
2018-06-13 01:32:58 +08:00
2018-06-13 01:32:58 +08:00