mirror of
https://github.com/cemu-project/vcpkg.git
synced 2025-02-23 02:57:09 +01:00
[exiv2] Fix FindIconv
This commit is contained in:
parent
2f25ab678a
commit
451c6a8026
@ -1,4 +1,4 @@
|
|||||||
Source: exiv2
|
Source: exiv2
|
||||||
Version: 8f5b795eaa4bc414d2d6041c1dbd1a7f7bf1fc99-1
|
Version: 8f5b795eaa4bc414d2d6041c1dbd1a7f7bf1fc99-2
|
||||||
Build-Depends: zlib, expat
|
Build-Depends: zlib, expat, libiconv
|
||||||
Description: Image metadata library and tools http://www.exiv2.org
|
Description: Image metadata library and tools http://www.exiv2.org
|
||||||
|
@ -13,6 +13,11 @@ vcpkg_configure_cmake(
|
|||||||
PREFER_NINJA
|
PREFER_NINJA
|
||||||
)
|
)
|
||||||
|
|
||||||
|
vcpkg_apply_patches(
|
||||||
|
SOURCE_PATH "${SOURCE_PATH}"
|
||||||
|
PATCHES "${CMAKE_CURRENT_LIST_DIR}/use-iconv.patch"
|
||||||
|
)
|
||||||
|
|
||||||
vcpkg_install_cmake()
|
vcpkg_install_cmake()
|
||||||
|
|
||||||
vcpkg_fixup_cmake_targets(CONFIG_PATH "share/exiv2/cmake")
|
vcpkg_fixup_cmake_targets(CONFIG_PATH "share/exiv2/cmake")
|
||||||
|
37
ports/exiv2/use-iconv.patch
Normal file
37
ports/exiv2/use-iconv.patch
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
diff --git a/config/FindIconv.cmake b/config/FindIconv.cmake
|
||||||
|
index 15a0e39..53718bf 100644
|
||||||
|
--- a/config/FindIconv.cmake
|
||||||
|
+++ b/config/FindIconv.cmake
|
||||||
|
@@ -36,12 +36,13 @@ if(NOT ICONV_INCLUDE_DIR STREQUAL "ICONV_INCLUDE_DIR-NOTFOUND")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(NOT ICONV_IN_GLIBC)
|
||||||
|
- find_library(ICONV_LIBRARY NAMES iconv)
|
||||||
|
+ find_library(ICONV_LIBRARY NAMES iconv libiconv)
|
||||||
|
set(ICONV_TEST ${ICONV_LIBRARY})
|
||||||
|
else()
|
||||||
|
set(ICONV_TEST "In glibc")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
+set(CMAKE_REQUIRED_INCLUDES ${ICONV_INCLUDE_DIR})
|
||||||
|
set(CMAKE_REQUIRED_LIBRARIES ${ICONV_LIBRARY})
|
||||||
|
check_cxx_source_compiles(
|
||||||
|
"#include <iconv.h>
|
||||||
|
@@ -59,7 +60,8 @@ else(ICONV_FOUND)
|
||||||
|
set(ICONV_LIBRARIES)
|
||||||
|
endif(ICONV_FOUND)
|
||||||
|
|
||||||
|
-if(ICONV_FOUND)
|
||||||
|
+if(ICONV_FOUND)
|
||||||
|
+ set(CMAKE_REQUIRED_INCLUDES ${ICONV_INCLUDE_DIR})
|
||||||
|
set(CMAKE_REQUIRED_LIBRARIES ${ICONV_LIBRARIES})
|
||||||
|
check_cxx_source_compiles(
|
||||||
|
"#include <iconv.h>
|
||||||
|
@@ -69,6 +71,7 @@ if(ICONV_FOUND)
|
||||||
|
}"
|
||||||
|
ICONV_ACCEPTS_NONCONST_INPUT)
|
||||||
|
|
||||||
|
+ set(CMAKE_REQUIRED_INCLUDES ${ICONV_INCLUDE_DIR})
|
||||||
|
set(CMAKE_REQUIRED_LIBRARIES ${ICONV_LIBRARIES})
|
||||||
|
check_cxx_source_compiles(
|
||||||
|
"#include <iconv.h>
|
Loading…
x
Reference in New Issue
Block a user