aboutsummaryrefslogtreecommitdiff
path: root/ports/freeimage
diff options
context:
space:
mode:
authormyd7349 <myd7349@gmail.com>2019-05-27 19:15:06 +0800
committermyd7349 <myd7349@gmail.com>2019-05-27 19:15:06 +0800
commit8999734b401bb8bac9fa20ce831b2ad2a9a67add (patch)
tree3f5cf1d5abbbc4295b556ea6e27882950bdd81f3 /ports/freeimage
parenta7ac12c90afed0a13e3b24d509927d2fca506115 (diff)
parent9ffac4d56eed774419fbb628ea89417a6399db58 (diff)
downloadvcpkg-8999734b401bb8bac9fa20ce831b2ad2a9a67add.tar.gz
vcpkg-8999734b401bb8bac9fa20ce831b2ad2a9a67add.zip
Merge branch 'master' into rdkafka-init
Diffstat (limited to 'ports/freeimage')
-rw-r--r--ports/freeimage/portfile.cmake35
-rw-r--r--ports/freeimage/use-typedef-as-already-declared.patch15
2 files changed, 33 insertions, 17 deletions
diff --git a/ports/freeimage/portfile.cmake b/ports/freeimage/portfile.cmake
index f3d9279c3..dc57a5691 100644
--- a/ports/freeimage/portfile.cmake
+++ b/ports/freeimage/portfile.cmake
@@ -2,12 +2,28 @@ include(${CMAKE_TRIPLET_FILE})
include(vcpkg_common_functions)
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/FreeImage)
vcpkg_download_distfile(ARCHIVE
- URLS "https://sourceforge.net/projects/freeimage/files/Source%20Distribution/3.18.0/FreeImage3180.zip/download"
+ URLS "http://downloads.sourceforge.net/freeimage/FreeImage3180.zip"
FILENAME "FreeImage3180.zip"
SHA512 9d9cc7e2d57552c3115e277aeb036e0455204d389026b17a3f513da5be1fd595421655488bb1ec2f76faebed66049119ca55e26e2a6d37024b3fb7ef36ad4818
)
-vcpkg_extract_source_archive(${ARCHIVE})
+vcpkg_extract_source_archive_ex(
+ OUT_SOURCE_PATH SOURCE_PATH
+ ARCHIVE ${ARCHIVE}
+ PATCHES
+ "${CMAKE_CURRENT_LIST_DIR}/disable-plugins-depending-on-internal-third-party-libraries.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-jpeg.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-jxrlib.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-libtiff.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-openjpeg.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-png-zlib.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-rawlib.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-webp.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-external-openexr.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-freeimage-config-include.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/fix-function-overload.patch"
+ "${CMAKE_CURRENT_LIST_DIR}/use-typedef-as-already-declared.patch"
+)
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
file(COPY ${CMAKE_CURRENT_LIST_DIR}/FreeImageConfig-static.h DESTINATION ${SOURCE_PATH})
@@ -25,21 +41,6 @@ file(REMOVE_RECURSE ${SOURCE_PATH}/Source/LibWebP)
file(REMOVE_RECURSE ${SOURCE_PATH}/Source/LibRawLite)
file(REMOVE_RECURSE ${SOURCE_PATH}/Source/OpenEXR)
-vcpkg_apply_patches(
- SOURCE_PATH ${SOURCE_PATH}
- PATCHES "${CMAKE_CURRENT_LIST_DIR}/disable-plugins-depending-on-internal-third-party-libraries.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-jpeg.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-jxrlib.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-libtiff.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-openjpeg.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-png-zlib.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-rawlib.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-webp.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-external-openexr.patch"
- "${CMAKE_CURRENT_LIST_DIR}/use-freeimage-config-include.patch"
- "${CMAKE_CURRENT_LIST_DIR}/fix-function-overload.patch"
-)
-
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
diff --git a/ports/freeimage/use-typedef-as-already-declared.patch b/ports/freeimage/use-typedef-as-already-declared.patch
new file mode 100644
index 000000000..80d367bcb
--- /dev/null
+++ b/ports/freeimage/use-typedef-as-already-declared.patch
@@ -0,0 +1,15 @@
+diff --git a/Source/FreeImage.h b/Source/FreeImage.h
+index 1fd9c2f..59de277 100644
+--- a/Source/FreeImage.h
++++ b/Source/FreeImage.h
+@@ -160,8 +160,8 @@ typedef uint8_t BYTE;
+ typedef uint16_t WORD;
+ typedef uint32_t DWORD;
+ typedef int32_t LONG;
+-typedef int64_t INT64;
+-typedef uint64_t UINT64;
++typedef long long int INT64;
++typedef long long unsigned int UINT64;
+ #else
+ // MS is not C99 ISO compliant
+ typedef long BOOL;