2017-06-30 05:56:12 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO OpenImageIO/oiio
|
2022-01-05 12:09:28 +08:00
|
|
|
REF ff71703961f7758409fb7e6e689258e2997f7c18 # 2.3.10.1
|
|
|
|
SHA512 f56cb58329a496ca1fe3537fe87d469038ac0e74a555990a4510d2c019d2ad14b556240c0d5087a9a25ac01d9b371b5c77ce5a719e71a85fcd56e9cd099bc31e
|
2017-06-30 05:56:12 +08:00
|
|
|
HEAD_REF master
|
2018-07-03 15:55:31 +08:00
|
|
|
PATCHES
|
2021-09-10 12:05:50 +08:00
|
|
|
fix-dependencies.patch
|
2022-01-05 12:09:28 +08:00
|
|
|
fix-config-cmake.patch
|
2022-03-30 08:21:57 +08:00
|
|
|
fix-openjpeg-linkage.patch
|
2022-05-13 08:06:27 +08:00
|
|
|
fix-ffmpeg-tool.patch
|
2017-06-30 05:56:12 +08:00
|
|
|
)
|
|
|
|
|
2018-05-02 06:55:59 +08:00
|
|
|
file(REMOVE_RECURSE "${SOURCE_PATH}/ext")
|
2019-09-30 04:07:50 +08:00
|
|
|
|
2019-12-26 12:06:42 +08:00
|
|
|
file(REMOVE "${SOURCE_PATH}/src/cmake/modules/FindLibRaw.cmake"
|
|
|
|
"${SOURCE_PATH}/src/cmake/modules/FindOpenCV.cmake"
|
2021-08-10 16:11:41 +08:00
|
|
|
"${SOURCE_PATH}/src/cmake/modules/FindFFmpeg.cmake")
|
2019-09-30 04:07:50 +08:00
|
|
|
|
2018-05-02 06:55:59 +08:00
|
|
|
file(MAKE_DIRECTORY "${SOURCE_PATH}/ext/robin-map/tsl")
|
|
|
|
|
2021-08-14 04:40:07 +08:00
|
|
|
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" LINKSTATIC)
|
2019-12-25 13:42:31 +08:00
|
|
|
|
2019-09-18 00:31:20 +08:00
|
|
|
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
2021-05-21 15:56:25 +08:00
|
|
|
FEATURES
|
|
|
|
libraw USE_LIBRAW
|
2021-08-10 16:11:41 +08:00
|
|
|
opencolorio USE_OPENCOLORIO
|
2021-05-21 15:56:25 +08:00
|
|
|
ffmpeg USE_FFMPEG
|
|
|
|
freetype USE_FREETYPE
|
|
|
|
gif USE_GIF
|
|
|
|
opencv USE_OPENCV
|
|
|
|
openjpeg USE_OPENJPEG
|
|
|
|
webp USE_WEBP
|
|
|
|
pybind11 USE_PYTHON
|
|
|
|
tools OIIO_BUILD_TOOLS
|
2019-09-18 00:31:20 +08:00
|
|
|
)
|
2018-07-03 15:55:31 +08:00
|
|
|
|
2020-01-13 12:39:49 +08:00
|
|
|
vcpkg_find_acquire_program(PYTHON3)
|
|
|
|
get_filename_component(PYTHON3_DIR "${PYTHON3}" DIRECTORY)
|
|
|
|
vcpkg_add_to_path("${PYTHON3_DIR}")
|
|
|
|
|
2021-08-14 04:40:07 +08:00
|
|
|
vcpkg_cmake_configure(
|
2021-12-30 03:22:28 +08:00
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2021-08-14 04:40:07 +08:00
|
|
|
OPTIONS
|
|
|
|
${FEATURE_OPTIONS}
|
2017-06-30 05:56:12 +08:00
|
|
|
-DOIIO_BUILD_TESTS=OFF
|
2019-10-10 17:24:02 +08:00
|
|
|
-DUSE_DCMTK=OFF
|
2017-06-30 05:56:12 +08:00
|
|
|
-DUSE_NUKE=OFF
|
|
|
|
-DUSE_QT=OFF
|
2019-12-26 12:06:42 +08:00
|
|
|
-DUSE_PTEX=OFF
|
2017-06-30 05:56:12 +08:00
|
|
|
-DLINKSTATIC=${LINKSTATIC}
|
2021-01-17 11:39:12 +08:00
|
|
|
-DBUILD_MISSING_FMT=OFF
|
|
|
|
-DBUILD_MISSING_ROBINMAP=OFF
|
2018-05-02 06:55:59 +08:00
|
|
|
-DBUILD_MISSING_DEPS=OFF
|
2021-01-17 11:39:12 +08:00
|
|
|
-DSTOP_ON_WARNING=OFF
|
2018-10-21 03:37:47 +08:00
|
|
|
-DVERBOSE=ON
|
2022-05-13 08:06:27 +08:00
|
|
|
-DBUILD_DOCS=OFF
|
|
|
|
-DINSTALL_DOCS=OFF
|
2017-06-30 05:56:12 +08:00
|
|
|
)
|
|
|
|
|
2021-08-14 04:40:07 +08:00
|
|
|
vcpkg_cmake_install()
|
2017-06-30 05:56:12 +08:00
|
|
|
|
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
2021-08-14 04:40:07 +08:00
|
|
|
vcpkg_cmake_config_fixup(PACKAGE_NAME OpenImageIO CONFIG_PATH lib/cmake/OpenImageIO)
|
2019-12-25 13:53:30 +08:00
|
|
|
|
2021-01-17 11:39:12 +08:00
|
|
|
if("tools" IN_LIST FEATURES)
|
|
|
|
vcpkg_copy_tools(
|
2021-05-21 15:56:25 +08:00
|
|
|
TOOL_NAMES iconvert idiff igrep iinfo maketx oiiotool iv
|
2021-01-17 11:39:12 +08:00
|
|
|
AUTO_CLEAN
|
|
|
|
)
|
2020-01-20 13:40:24 +08:00
|
|
|
endif()
|
|
|
|
|
2017-06-30 05:56:12 +08:00
|
|
|
# Clean
|
2021-08-14 04:40:07 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/doc"
|
|
|
|
"${CURRENT_PACKAGES_DIR}/debug/doc"
|
|
|
|
"${CURRENT_PACKAGES_DIR}/debug/include"
|
|
|
|
"${CURRENT_PACKAGES_DIR}/debug/share")
|
2017-06-30 05:56:12 +08:00
|
|
|
|
2021-12-30 03:22:28 +08:00
|
|
|
vcpkg_fixup_pkgconfig()
|
2019-08-09 08:46:04 +08:00
|
|
|
|
2021-08-14 04:40:07 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/LICENSE.md" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|