2021-07-24 00:02:46 +08:00
|
|
|
set(GIFLIB_VERSION 5.2.1)
|
2019-03-23 18:07:21 +08:00
|
|
|
|
2021-07-24 00:02:46 +08:00
|
|
|
set(EXTRA_PATCHES "")
|
2020-06-27 06:06:30 +08:00
|
|
|
if (VCPKG_TARGET_IS_WINDOWS)
|
2021-07-24 00:02:46 +08:00
|
|
|
list(APPEND EXTRA_PATCHES fix-compile-error.patch)
|
2019-05-10 02:45:23 +08:00
|
|
|
endif()
|
|
|
|
|
2020-06-27 06:06:30 +08:00
|
|
|
vcpkg_from_sourceforge(
|
2019-03-27 08:31:19 +08:00
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
2020-06-27 06:06:30 +08:00
|
|
|
REPO "giflib"
|
2021-07-24 00:02:46 +08:00
|
|
|
FILENAME "giflib-${GIFLIB_VERSION}.tar.gz"
|
|
|
|
SHA512 4550e53c21cb1191a4581e363fc9d0610da53f7898ca8320f0d3ef6711e76bdda2609c2df15dc94c45e28bff8de441f1227ec2da7ea827cb3c0405af4faa4736
|
2019-03-29 05:46:21 +08:00
|
|
|
PATCHES
|
|
|
|
msvc-guard-unistd-h.patch
|
2021-07-24 00:02:46 +08:00
|
|
|
disable-GifDrawBoxedText8x8-win32.patch # MSVC doesn't have strtok_r
|
|
|
|
${EXTRA_PATCHES}
|
2019-03-27 08:31:19 +08:00
|
|
|
)
|
2019-03-23 18:07:21 +08:00
|
|
|
|
2021-07-24 00:02:46 +08:00
|
|
|
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
2017-04-27 23:00:00 +08:00
|
|
|
|
2021-07-24 00:02:46 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
|
|
OPTIONS
|
|
|
|
"-DGIFLIB_EXPORTS=${CMAKE_CURRENT_LIST_DIR}/exports.def"
|
2017-04-27 23:00:00 +08:00
|
|
|
OPTIONS_DEBUG
|
|
|
|
-DGIFLIB_SKIP_HEADERS=ON
|
|
|
|
)
|
|
|
|
|
2021-07-24 00:02:46 +08:00
|
|
|
vcpkg_cmake_install()
|
2017-04-27 23:00:00 +08:00
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
2021-12-23 11:55:57 +08:00
|
|
|
file(COPY ${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/gif)
|
|
|
|
|
2021-07-24 00:02:46 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|